/* Magna OS Design System */
:root {
    /* Primary – Indigo scale */
    --indigo-50: #EEF2FF;
    --indigo-100: #E0E7FF;
    --indigo-200: #C7D2FE;
    --indigo-400: #818CF8;
    --indigo-500: #6366F1;
    --indigo-600: #4F50E5;
    --primary: #4F50E5;
    --primary-dark: #4338CA;
    --primary-light: #EEF2FF;
    --accent: var(--indigo-500);

    /* Success – Green */
    --success: #22C55E;
    --success-dark: #16A34A;

    /* Warning – Amber */
    --warning: #F59E0B;
    --warning-dark: #D97706;

    /* Danger – Red */
    --danger: #EF4444;
    --error: #DC2626;

    /* Neutrals – Gray scale */
    --gray-50: #F8FAFC;
    --gray-100: #F1F5F9;
    --gray-200: #E2E8F0;
    --gray-400: #94A3B8;
    --gray-500: #64748B;
    --gray-700: #334155;
    --gray-900: #0F172A;

    --background: #F8FAFC;
    --card-bg: #FFFFFF;
    --border: #E2E8F0;
    --text-main: #334155;
    --text-muted: #64748B;
    --text-heading: #0F172A;

    /* Spacing (only 4, 8, 12, 16, 24, 32) */
    --space-4: 4px;
    --space-8: 8px;
    --space-12: 12px;
    --space-16: 16px;
    --space-24: 24px;
    --space-32: 32px;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
    --text-h1: 24px;
    --text-h2: 18px;
    --text-body: 14px;
    --text-label: 12px;
    --text-small: 12px;
    --radius: 8px;
    --radius-lg: 12px;
    --radius-full: 9999px;
    --shadow-soft: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-card: 0 4px 12px rgba(0, 0, 0, 0.06);
}

/* Typography hierarchy – Magna OS */
h1, .text-h1 { font-size: var(--text-h1); font-weight: 600; color: var(--gray-900); }
h2, .text-h2 { font-size: var(--text-h2); font-weight: 600; color: var(--gray-900); }
.text-body { font-size: var(--text-body); color: var(--gray-700); }
.text-label { font-size: var(--text-label); font-weight: 500; color: var(--gray-500); }
.text-small { font-size: var(--text-small); color: var(--gray-500); }

/* ============================================
   GLOBAL ANIMATIONS
   ============================================ */

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(var(--space-12));
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.96);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes fadePulse {
    0%, 100% {
        opacity: 0.4;
    }
    50% {
        opacity: 1;
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: var(--font-family);
    font-size: var(--text-body);
    color: var(--text-main);
    background: var(--background);
    height: 100%;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.layout {
    display: flex;
    flex: 1;
    min-height: 0;
    background: var(--background);
}

/* ============================================
   DASHBOARD TABS
   ============================================ */

.dashboard-tabs {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: var(--space-16);
    padding: var(--space-12) var(--space-16);
    background: var(--card-bg);
    border-bottom: 1px solid var(--gray-200);
    flex-shrink: 0;
    z-index: 20;
}

.dashboard-brand-inline {
    display: flex;
    align-items: center;
    gap: var(--space-8);
    flex-shrink: 0;
    margin-right: var(--space-8);
}
.dashboard-brand-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
}
.dashboard-brand-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-900);
}
.dashboard-tabs-spacer {
    width: 108px;
    flex-shrink: 0;
}

.tab-button {
    border: none;
    border-radius: var(--radius-full);
    padding: var(--space-8) var(--space-16);
    background: transparent;
    color: var(--gray-700);
    display: inline-flex;
    align-items: center;
    gap: var(--space-8);
    cursor: pointer;
    font-size: var(--text-body);
    font-weight: 500;
    transition: all 0.2s ease;
    position: relative;
}

.tab-button::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0%;
    height: 2px;
    background: var(--primary);
    transition: all 0.25s ease;
    transform: translateX(-50%);
    border-radius: var(--radius-full);
}

.tab-button.active::after {
    width: 80%;
}

.tab-button i {
    font-size: 1rem;
}

.tab-button span {
    white-space: nowrap;
}

.tab-button:hover {
    color: var(--text-main);
    background: var(--gray-100);
}

.tab-button.active {
    color: var(--primary);
    font-weight: 600;
}

.tab-button.active::after {
    width: 80%;
}

.subtab-button {
    padding: var(--space-8) var(--space-16);
    font-size: var(--text-body);
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    background: var(--card-bg);
    color: var(--gray-500);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: var(--space-8);
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.subtab-button:hover {
    color: var(--text-main);
    background: var(--indigo-50);
    border-color: var(--indigo-200);
}
.subtab-button.active {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary);
    font-weight: 500;
}

.control-panel {
    width: 320px;
    background: var(--card-bg);
    padding: var(--space-16);
    display: flex;
    flex-direction: column;
    gap: var(--space-12);
    border-right: 1px solid var(--gray-200);
    overflow-y: auto;
}

.panel-section {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 14px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    animation: fadeSlideIn 0.4s ease-out;
}

.panel-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(79, 80, 229, 0.12);
}

.section-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--primary-dark);
    letter-spacing: 0.2px;
}

.field-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--text-muted);
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.range-value {
    font-size: 0.85rem;
    color: var(--primary-dark);
    font-weight: 600;
}

input[type="text"], textarea, input[type="number"] {
    width: 100%;
    padding: var(--space-12) var(--space-16);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
    background: var(--card-bg);
    color: var(--text-main);
    font-size: var(--text-body);
    font-size: 0.95rem;
    transition: border 0.2s ease;
    font-family: inherit;
}

input[type="text"]:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.12);
}

input[type="range"] {
    width: 100%;
    accent-color: var(--primary);
    height: 8px;
    border-radius: 5px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.3);
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.3);
}

/* Search controls panel - enhanced slider UI */
.search-controls-panel .section-title {
    margin-bottom: var(--space-4);
}
.search-controls-panel {
    gap: var(--space-8);
    padding: var(--space-12);
}
.search-control-item {
    padding: var(--space-12);
    background: var(--gray-50);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    gap: var(--space-8);
}
.search-control-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.search-control-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
}
.search-control-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--primary);
}
.search-control-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--gray-500);
    margin-top: -4px;
}
.search-control-slider {
    margin: 0;
    padding: 0;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--gray-200);
    border-radius: 9999px;
    outline: none;
    accent-color: var(--primary);
}
.search-control-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    border: 3px solid #fff;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.search-control-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 12px rgba(79, 80, 229, 0.4);
}
.search-control-slider::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 9999px;
    background: var(--gray-200);
}
.search-control-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    border: 3px solid #fff;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.search-control-slider::-moz-range-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 3px 12px rgba(79, 80, 229, 0.4);
}
.search-control-slider::-moz-range-track {
    height: 6px;
    border-radius: 9999px;
    background: var(--gray-200);
}
.search-control-slider:focus {
    outline: none;
}
.search-control-slider:focus-visible::-webkit-slider-thumb {
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.25);
}
.search-control-slider:focus-visible::-moz-range-thumb {
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.25);
}

.panel-actions {
    display: flex;
    gap: 10px;
    justify-content: space-between;
}

.primary-btn, .ghost-btn {
    border: none;
    border-radius: var(--radius-lg);
    padding: var(--space-12) var(--space-16);
    font-size: var(--text-body);
    font-weight: 600;
    transition: background 0.2s, transform 0.15s ease, box-shadow 0.15s ease;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: var(--space-8);
}

.primary-btn {
    background: var(--primary);
    color: #fff;
    box-shadow: var(--shadow-soft);
}

.primary-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.primary-btn:active {
    transform: scale(0.98);
}

.primary-btn:disabled {
    background: var(--gray-400);
    color: var(--gray-100);
    cursor: not-allowed;
    transform: none;
}

.ghost-btn:active {
    transform: scale(0.98);
}

.ghost-btn {
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--indigo-200);
}

.ghost-btn:hover {
    background: var(--indigo-50);
}

.chat-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--background);
    padding: 0;
    gap: 0;
    position: relative;
    min-height: 0;
}

/* ChatGPT-style: chat section fills space, input fixed at bottom */
.search-main-chat-layout {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    position: relative;
}
.search-main-chat-layout .results-container {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}
.search-main-chat-layout .chat-messages-container {
    max-height: none;
}

/* My Candidates section: fill main area and scroll list only */
#myCandidatesMainSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#myCandidatesMainSection .results-container {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}
#myCandidatesMainSection .results-header {
    flex-shrink: 0;
}
#myCandidatesMainSection #myCandidatesContent {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}
#myCandidatesMainSection #myCandidatesPagination {
    flex-shrink: 0;
}

/* Shortlists: sidebar list and main (specific shortlist) scrollable */
#shortlistsSidebarSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#shortlistsSidebarSection .panel-section {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#shortlistsList {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

#shortlistsMainSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#shortlistsMainSection .results-container {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}
#shortlistsMainSection .results-header,
#shortlistsMainSection #shortlistJobUrlContainer {
    flex-shrink: 0;
}
#shortlistCandidates {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Search History: sidebar list and main content scrollable */
#historySidebarSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#historySidebarSection .panel-section {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#historyList {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

#historyMainSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#historyMainSection .results-container {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}
#historyMainSection .results-header {
    flex-shrink: 0;
}
#historyContent {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Interviews (Current-Interviews) */
#interviewsMainSection {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#interviewsMainSection .results-container {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 0;
}
#interviewsMainSection .results-header {
    flex-shrink: 0;
    margin-bottom: 12px;
}
#interviewsMainSection .interviews-subtabs {
    flex-shrink: 0;
    margin-bottom: 12px;
}
#interviewsMainSection .interviews-panel {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.interviews-panel {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.interviews-layout {
    flex: 1;
    min-height: 0;
    min-width: 0;
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 16px;
}
.interviews-list-pane,
.interview-editor-pane {
    min-height: 0;
    min-width: 280px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.interviews-list-header,
.interview-editor-header {
    flex-shrink: 0;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    border-bottom: 1px solid var(--gray-100);
    background: #fff;
    flex-wrap: wrap;
}
.interviews-list-header {
    align-items: center;
}
.interview-editor-header {
    align-items: center;
}
.interviews-header-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 0;
}
.interviews-filters-row {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-bottom: 1px solid var(--gray-100);
    background: #fff;
}
.interviews-filter-buttons {
    display: flex;
    gap: 6px;
}
.interview-filter-btn {
    font-size: 0.8rem;
}
.interview-filter-btn.active {
    background: rgba(79, 80, 229, 0.12);
    color: var(--primary);
    border-color: rgba(79, 80, 229, 0.3);
}
.interview-search-input {
    flex: 1;
    min-width: 0;
    padding: 8px 12px;
    font-size: 0.8rem;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    background: #fff;
    color: var(--text-main);
}
.interview-search-input::placeholder {
    color: var(--gray-400);
}
.interview-search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(79, 80, 229, 0.1);
}
.interviews-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-content: start;
}
/* ----- Interview card (list item) ----- */
.interview-list-item {
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 14px 16px;
    padding-left: 18px;
    background: #fff;
    cursor: pointer;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    min-width: 0;
}
.interview-list-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--primary);
    border-radius: 4px 0 0 4px;
}
.interview-list-item:hover {
    box-shadow: 0 4px 16px rgba(79, 80, 229, 0.1);
    border-color: rgba(79, 80, 229, 0.25);
}
.interview-list-item.active {
    border-color: rgba(79, 80, 229, 0.35);
    box-shadow: 0 4px 16px rgba(79, 80, 229, 0.14);
    background: rgba(79, 80, 229, 0.02);
}

.interview-card-top-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 6px;
}
.interview-card-top-row > div:first-child {
    min-width: 0;
    flex: 1;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--gray-900);
    letter-spacing: -0.01em;
    line-height: 1.3;
    word-break: break-word;
    overflow-wrap: break-word;
}

.interview-card-meta {
    margin-top: 2px;
    font-size: 0.8rem;
    color: var(--gray-500);
    font-weight: 500;
}
.interview-card-datetime {
    margin-top: 4px;
    font-size: 0.8rem;
    color: var(--gray-600);
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    background: var(--gray-50);
    border-radius: 8px;
    width: fit-content;
}

.interview-card-confirmation-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
    padding: 12px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
}
.interview-card-confirmation-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
}
.interview-card-confirmation-label {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 0.8rem;
}
.interview-card-confirmation-value {
    font-weight: 600;
    font-size: 0.78rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.interview-card-confirmation-row.interview-card-available .interview-card-confirmation-value {
    color: #059669;
}
.interview-card-confirmation-row.interview-card-available .interview-card-confirmation-value i {
    color: #059669;
}
.interview-card-confirmation-row.interview-card-not-available .interview-card-confirmation-value {
    color: #dc2626;
}
.interview-card-confirmation-row.interview-card-not-available .interview-card-confirmation-value i {
    color: #dc2626;
}
.interview-card-confirmation-row.interview-card-reschedule .interview-card-confirmation-value {
    color: #d97706;
}
.interview-card-confirmation-row.interview-card-reschedule .interview-card-confirmation-value i {
    color: #d97706;
}
.interview-card-confirmation-row.interview-card-confirmation-pending .interview-card-confirmation-label,
.interview-card-confirmation-row.interview-card-confirmation-pending .interview-card-confirmation-value {
    color: var(--gray-500);
    font-weight: 500;
}
.interview-card-confirmation-value i {
    margin-right: 5px;
    opacity: 0.9;
}

.interview-card-last-notified {
    margin-top: 10px;
    font-size: 0.72rem;
    color: var(--gray-500);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    background: var(--gray-50);
    border-radius: 6px;
    width: fit-content;
}
.interview-card-last-notified i {
    margin-right: 0;
    opacity: 0.8;
}

.interview-card-outcome {
    margin-top: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: rgba(79, 80, 229, 0.08);
    border-radius: 16px;
    width: fit-content;
    border: 1px solid rgba(79, 80, 229, 0.15);
}
.interview-card-outcome.outcome-selected {
    color: #047857;
    background: rgba(5, 150, 105, 0.1);
    border-color: rgba(5, 150, 105, 0.25);
}
.interview-card-outcome.outcome-rejected {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.08);
    border-color: rgba(220, 38, 38, 0.2);
}
.interview-card-outcome.outcome-awaiting-feedback {
    color: #d97706;
    background: rgba(245, 158, 11, 0.08);
    border-color: rgba(245, 158, 11, 0.2);
}

.interview-list-item .interview-card-meta:has(.fa-user-check) {
    margin-top: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: rgba(79, 80, 229, 0.06);
    border-radius: 8px;
    width: fit-content;
    color: var(--primary);
    font-weight: 600;
    font-size: 0.78rem;
    border: 1px solid rgba(79, 80, 229, 0.12);
}
.interview-list-item .interview-card-meta:has(.fa-user-check) i {
    color: var(--primary);
}

.interview-card-actions {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--gray-100);
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.interview-card-actions button {
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.8rem;
}

/* Interview journey timeline */
.interview-journey {
    padding: 10px 14px;
    border-bottom: 1px solid var(--gray-100);
    margin: 0;
}
.interview-section-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0 0 12px 0;
}
.interview-journey-timeline {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 0;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px 0 12px;
    margin: 0;
    -webkit-overflow-scrolling: touch;
}
.interview-journey-node {
    flex: 0 0 auto;
    min-width: 100px;
    max-width: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}
.interview-journey-label-top {
    text-align: center;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--gray-700);
    line-height: 1.3;
    min-height: 32px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 0 4px 6px;
    word-break: break-word;
}
.interview-journey-dot-wrap {
    height: 24px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.interview-journey-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2.5px solid var(--gray-300);
    background: #fff;
    z-index: 2;
    flex-shrink: 0;
    position: relative;
    transition: transform 0.15s ease;
}
.interview-journey-dot.ij-milestone {
    width: 18px;
    height: 18px;
    border-width: 3px;
}
.interview-journey-label-bottom {
    text-align: center;
    font-size: 0.68rem;
    color: var(--gray-400);
    padding: 4px 2px 0;
}
/* Dot colors */
.interview-journey-dot.ij-created { border-color: var(--primary); background: rgba(79, 80, 229, 0.15); }
.interview-journey-dot.ij-notify { border-color: var(--primary); background: rgba(79, 80, 229, 0.1); }
.interview-journey-dot.ij-available { border-color: var(--success); background: rgba(22, 163, 74, 0.15); }
.interview-journey-dot.ij-not-available { border-color: var(--danger); background: rgba(220, 38, 38, 0.1); }
.interview-journey-dot.ij-reschedule { border-color: var(--warning); background: rgba(245, 158, 11, 0.15); }
.interview-journey-dot.ij-attended { border-color: var(--success); background: rgba(22, 163, 74, 0.25); }
.interview-journey-dot.ij-not-attended { border-color: var(--danger); background: rgba(220, 38, 38, 0.2); }
.interview-journey-dot.ij-round-scheduled { border-color: var(--success); background: rgba(22, 163, 74, 0.15); }
.interview-journey-dot.ij-round-selected { border-color: var(--success); background: var(--success); }
.interview-journey-dot.ij-round-rescheduled { border-color: var(--warning); background: rgba(245, 158, 11, 0.2); }
.interview-journey-dot.ij-round-rejected { border-color: var(--danger); background: rgba(220, 38, 38, 0.25); }

.interview-confirmation-status {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    margin: 0;
    background: #fff;
    border-bottom: 1px solid var(--gray-100);
}
.interview-confirmation-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}
.interview-confirmation-label {
    font-weight: 600;
    color: var(--gray-700);
}
.interview-confirmation-value {
    font-weight: 500;
    color: var(--gray-600);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
/* Status badge (Attended / Scheduled / Pending / Rejected) */
.interview-card-status-badge {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    flex-shrink: 0;
    white-space: nowrap;
    padding: 4px 10px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.interview-card-status-badge.status-attended {
    color: #047857;
    background: rgba(5, 150, 105, 0.12);
    border: 1px solid rgba(5, 150, 105, 0.25);
}
.interview-card-status-badge.status-not-attended {
    color: #b91c1c;
    background: rgba(185, 28, 28, 0.08);
    border: 1px solid rgba(185, 28, 28, 0.2);
}
.interview-card-status-badge.status-scheduled {
    color: var(--primary);
    background: rgba(79, 80, 229, 0.08);
    border: 1px solid rgba(79, 80, 229, 0.2);
}
.interview-card-status-badge.status-rescheduled {
    color: #d97706;
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.2);
}
.interview-card-status-badge.status-pending {
    color: #d97706;
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.2);
}
.interview-card-status-badge.status-rejected {
    color: #dc2626;
    background: rgba(220, 38, 38, 0.08);
    border: 1px solid rgba(220, 38, 38, 0.2);
}
.interview-card-status-badge.status-dropped {
    color: var(--gray-500);
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
}
.interview-editor-pane {
    padding: 0;
}
.interview-editor-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}
.interview-editor-form {
    padding: 16px;
}
.interview-editor-empty {
    flex: 1;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 20px;
    color: var(--text-muted);
    text-align: center;
    font-size: 0.9rem;
    line-height: 1.5;
}
.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
@media (max-width: 1100px) {
    .interviews-layout {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .interviews-list-pane {
        min-height: 280px;
    }
    .interview-editor-pane {
        min-height: 320px;
    }
}

.search-bar-container {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--background);
    padding: 20px 28px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 12px rgba(80, 48, 165, 0.08);
}
.search-bar-container.search-bar-bottom {
    top: auto;
    bottom: 0;
    border-bottom: none;
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 12px rgba(80, 48, 165, 0.06);
    flex-shrink: 0;
}

/* Sent animation: query text flies from input into chat */
.sent-bubble-fly {
    position: absolute;
    left: 28px;
    right: 28px;
    bottom: 88px;
    z-index: 50;
    pointer-events: none;
    opacity: 0;
    transform: translateY(12px) scale(0.96);
    transition: opacity 0.25s ease-out, transform 0.5s cubic-bezier(0.34, 1.2, 0.64, 1);
}
.sent-bubble-fly-active {
    opacity: 1;
    transform: translateY(-100px) scale(1);
}
.sent-bubble-fly-inner {
    max-width: 85%;
    margin-left: auto;
    padding: 12px 16px;
    border-radius: 14px;
    font-size: 0.9rem;
    line-height: 1.5;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    box-shadow: 0 2px 12px rgba(79, 80, 229, 0.35);
}
/* Send button "sent" state */
.send-button.send-btn-sent {
    background: var(--success, #22c55e);
    color: #fff;
    transform: scale(1.05);
}
.send-button.send-btn-sent i {
    animation: sendCheckPop 0.35s ease-out;
}
@keyframes sendCheckPop {
    0% { transform: scale(0.8); opacity: 0.6; }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

.chat-input-wrapper {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--card-bg);
    padding: 10px 12px;
    transition: box-shadow 0.25s ease;
    border-radius: 16px;
}

.chat-input-wrapper:focus-within {
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.2);
}

.chat-input {
    flex: 1;
    background: transparent;
    border: none;
    resize: none;
    color: var(--text-main);
    font-size: 1rem;
    min-height: 28px;
    max-height: 140px;
    outline: none;
    font-family: inherit;
}

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

.send-button {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    border: none;
    border-radius: 14px;
    padding: 12px 18px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 600;
    box-shadow: 0 12px 24px rgba(79, 80, 229, 0.25);
    transition: all 0.2s ease;
}

.send-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(79, 80, 229, 0.35);
}

.send-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.web-search-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
    font-size: 0.9rem;
    color: var(--text-muted);
}
.web-search-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
}
.web-search-toggle .toggle-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.web-search-toggle:hover .toggle-label {
    color: var(--text-main);
}

.attach-jd-label {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}
.attach-jd-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    font-size: 0.85rem;
    color: var(--primary);
    background: rgba(79, 80, 229, 0.1);
    border: 1px solid rgba(79, 80, 229, 0.3);
    border-radius: 10px;
    transition: background 0.2s, color 0.2s;
}
.attach-jd-btn:hover {
    background: rgba(79, 80, 229, 0.18);
    color: var(--primary-dark);
}
.attach-jd-filename {
    font-size: 0.8rem;
    color: var(--text-muted);
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chat-messages-container {
    margin-bottom: 20px;
    overflow-y: visible;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid var(--border);
}
.chat-messages-list {
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.chat-messages-list .message {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    gap: 0;
}
.chat-messages-list .message.user-message {
    align-items: flex-end;
}
.chat-messages-list .message-bubble-row {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    max-width: 85%;
}
.chat-messages-list .message.user-message .message-bubble-row {
    flex-direction: row-reverse;
}
.chat-messages-list .message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.chat-messages-list .message.user-message .message-avatar {
    background: var(--primary);
    color: #fff;
}
.chat-messages-list .message-content {
    flex: 1;
    min-width: 0;
    padding: 12px 16px;
    border-radius: 14px;
    font-size: 0.9rem;
    line-height: 1.55;
    word-wrap: break-word;
    white-space: pre-wrap;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.chat-messages-list .message.user-message .message-content {
    align-items: flex-end;
}
.chat-messages-list .message-body {
    width: 100%;
}
.chat-messages-list .message-meta-time {
    font-size: 10px;
    line-height: 1.2;
    color: var(--gray-500);
    opacity: 0.9;
    margin-top: 2px;
    margin-bottom: 0;
}
.chat-messages-list .message.user-message .message-meta-time {
    align-self: flex-end;
    margin-right: 46px;
}
.chat-messages-list .message.assistant .message-meta-time {
    align-self: flex-start;
    margin-left: 46px;
}
.chat-messages-list .message.assistant .message-content {
    background: rgba(79, 80, 229, 0.08);
    color: var(--text-main);
    border: 1px solid rgba(79, 80, 229, 0.12);
    border-bottom-left-radius: 4px;
}
.chat-messages-list .message.user-message .message-content {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    border: none;
    border-bottom-right-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Profiles attached to NEW_SEARCH assistant messages (Intent → UI contract) */
.chat-messages-list .message-profiles {
    margin-top: 14px;
    margin-left: 46px; /* align with text after avatar */
    width: calc(100% - 46px);
    clear: both;
}
.chat-messages-list .message.user-message .message-profiles {
    margin-left: 0;
    margin-right: 0;
}
.message-profiles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
}
.message-profiles-grid .candidate-card {
    margin: 0;
}

.results-container {
    flex: 1;
    overflow-y: auto;
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    animation: fadeSlideIn 0.4s ease-out;
}

.results-content {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(79, 80, 229, 0.12) 0%, rgba(255, 255, 255, 0.65) 100%);
    padding: 20px;
    border-radius: 20px;
    border: 1px solid rgba(79, 80, 229, 0.15);
    margin-bottom: 18px;
}

.chat-header h2 {
    font-size: 1.4rem;
    color: var(--primary-dark);
    margin-bottom: 8px;
}

.chat-header p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

#exportCsvBtn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    font-size: 0.9rem;
    white-space: nowrap;
}

.welcome-section {
    margin-top: 20px;
    animation: fadeSlideIn 0.6s ease-out;
}

.message {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    box-shadow: 0 6px 12px rgba(79, 80, 229, 0.25);
    flex-shrink: 0;
}

.message-content {
    background: rgba(79, 80, 229, 0.08);
    padding: 16px;
    border-radius: 16px;
    border-top-left-radius: 6px;
    color: var(--text-main);
    line-height: 1.6;
    flex: 1;
    box-shadow: 0 18px 36px rgba(79, 80, 229, 0.08);
}

.suggestion-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.suggestion-chip {
    background: rgba(79, 80, 229, 0.15);
    color: var(--primary-dark);
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.85rem;
    transition: transform 0.2s ease;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.suggestion-chip:hover {
    transform: translateY(-2px);
    background: rgba(79, 80, 229, 0.25);
}

.candidate-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.candidate-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    padding: var(--space-16);
    display: flex;
    flex-direction: column;
    gap: var(--space-12);
    box-shadow: var(--shadow-card);
    transition: border 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    position: relative;
    animation: fadeSlideIn 0.4s ease-out;
    min-height: 0;
    overflow: hidden;
}

/* Premium badge: diagonal gold ribbon over card corner (symmetric on all cards) */
.candidate-card .candidate-card-premium-badge,
.candidate-card .premium-badge.candidate-card-premium-badge {
    position: absolute;
    top: 18px;
    right: -32px;
    width: 110px;
    padding: 6px 10px;
    background: linear-gradient(135deg, #FBBF24 0%, #F59E0B 50%, #D97706 100%);
    color: #1a1a1a;
    font-size: var(--text-label);
    font-weight: 700;
    text-align: center;
    transform: rotate(45deg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
    z-index: 10;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    letter-spacing: 0.03em;
    border: 1px solid rgba(255, 220, 100, 0.5);
}
.candidate-card .candidate-card-premium-badge i,
.candidate-card .premium-badge.candidate-card-premium-badge i {
    color: #1a1a1a;
    font-size: 0.7rem;
}

/* Top row: avatar + name */
.candidate-card-top {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
}
.candidate-card-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(145deg, #e2e8f0 0%, #cbd5e1 100%);
    color: var(--text-main);
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    letter-spacing: 0.02em;
}
.candidate-card-head {
    flex: 1;
    min-width: 0;
}
.candidate-card-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 4px 0;
    line-height: 1.25;
}
.candidate-card-match-pill {
    display: inline-block;
    padding: var(--space-4) var(--space-12);
    border-radius: var(--radius-full);
    background: var(--indigo-50);
    color: var(--primary);
    font-size: var(--text-label);
    font-weight: 600;
}
.candidate-card-pill-shortlist {
    background: rgba(34, 197, 94, 0.12);
    color: var(--success-dark);
}
.candidate-card-contact-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 16px;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.candidate-card-contact-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.candidate-card-contact-item i {
    color: var(--primary);
    opacity: 0.9;
    font-size: 0.8rem;
}
.candidate-card-summary {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
}
.candidate-card-skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.candidate-card-skill-tag {
    padding: var(--space-4) var(--space-12);
    border-radius: var(--radius-full);
    background: var(--gray-100);
    color: var(--text-main);
    font-size: var(--text-label);
    font-weight: 500;
}
.candidate-card-resume {
    font-size: 0.82rem;
}
.candidate-card-resume-link {
    color: var(--primary);
    text-decoration: none;
}
.candidate-card-resume-link:hover {
    text-decoration: underline;
}
/* Icon-only action bar */
.candidate-card-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-8);
    margin-top: var(--space-8);
    padding-top: var(--space-12);
    border-top: 1px solid var(--gray-200);
}
.candidate-card-action-btn {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--indigo-200);
    background: var(--card-bg);
    color: var(--primary);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.candidate-card-action-btn:hover {
    background: var(--indigo-50);
    border-color: var(--indigo-400);
}
.candidate-card-action-btn-remove:hover {
    background: rgba(239, 68, 68, 0.08);
    border-color: var(--danger);
    color: var(--error);
}
.candidate-card-more-wrap {
    position: relative;
}
.candidate-card-more-menu {
    position: absolute;
    bottom: 100%;
    left: 0;
    margin-bottom: var(--space-8);
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-card);
    padding: 6px;
    display: none;
    flex-direction: column;
    min-width: 180px;
    z-index: 15;
}
.candidate-card-more-menu.open {
    display: flex;
}

/* When dropdown is open, card stacks above neighbors and doesn't clip the menu */
.candidate-card:has(.candidate-card-more-menu.open) {
    z-index: 50;
    overflow: visible;
}

.candidate-card-more-menu button {
    padding: 8px 12px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--text-main);
    font-size: 0.88rem;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}
.candidate-card-more-menu button:hover {
    background: var(--indigo-50);
}

.candidate-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    border-color: var(--indigo-200);
}

.candidate-card:active {
    transform: scale(0.98);
}

.candidate-card.dragging {
    opacity: 0.7;
    transform: rotate(2deg) scale(1.02);
}

/* Best Match Card - Gold Outline with Animation */
.candidate-card.best-match {
    border: 2px solid var(--warning);
    box-shadow: var(--shadow-card), 0 0 0 1px rgba(245, 158, 11, 0.2);
    position: relative;
    overflow: visible;
}

.candidate-card.best-match:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(245, 158, 11, 0.25);
}

/* Best Match Banner */
.best-match-banner {
    position: absolute;
    top: -12px;
    right: 20px;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #1a1a1a;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.5);
    z-index: 10;
    animation: bannerPulse 2s ease-in-out infinite;
    letter-spacing: 0.5px;
}

.best-match-banner i {
    font-size: 0.9rem;
    animation: starSpin 3s linear infinite;
}

@keyframes bannerPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 12px rgba(255, 215, 0, 0.5);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 6px 16px rgba(255, 215, 0, 0.7);
    }
}

@keyframes starSpin {
    0% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(90deg) scale(1.2);
    }
    50% {
        transform: rotate(180deg);
    }
    75% {
        transform: rotate(270deg) scale(1.2);
    }
    100% {
        transform: rotate(360deg);
    }
}

.candidate-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.candidate-header h4 {
    font-size: 1.1rem;
    color: var(--text-main);
    font-weight: 700;
    margin: 0;
}

.match-score {
    padding: 6px 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--success) 0%, #1FC28C 100%);
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
}

.candidate-card .info-item {
    margin-bottom: 6px;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.4;
}

.candidate-card .info-item strong {
    color: var(--text-main);
    margin-right: 5px;
}

/* Symmetric action row: equal-width buttons */
.candidate-card-actions {
    display: flex;
    gap: 10px;
    margin-top: 4px;
    flex-wrap: wrap;
}

.candidate-card-actions > * {
    flex: 1;
    min-width: 0;
}

.candidate-card-actions-stack {
    flex-direction: column;
    gap: 8px;
}

.candidate-card-actions-stack > * {
    width: 100%;
    flex: none;
}

/* Shortlist candidate card: bookmark icon (no WhatsApp on card) */
.shortlist-candidate-card {
    position: relative;
}
.shortlist-card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    color: var(--primary);
    font-size: 1rem;
    opacity: 0.9;
}
.shortlist-card-badge i {
    font-size: 1.1rem;
}

.reach-out-btn {
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(37, 211, 102, 0.5);
    background: linear-gradient(135deg, rgba(37, 211, 102, 0.12) 0%, rgba(34, 180, 88, 0.08) 100%);
    color: #1a7a3a;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.reach-out-btn:hover {
    background: linear-gradient(135deg, #25D366 0%, #1da851 100%);
    color: #fff;
    border-color: #25D366;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.35);
}

.schedule-interview-btn {
    padding: 10px 14px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 4px 14px rgba(79, 80, 229, 0.3);
}

.schedule-interview-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(79, 80, 229, 0.4);
}

.remove-from-shortlist-btn {
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.88rem;
    font-weight: 500;
}

.view-details-btn {
    width: 100%;
    padding: 12px 20px;
    margin-top: 8px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 16px rgba(79, 80, 229, 0.25);
}

.candidate-card-actions .view-details-btn {
    margin-top: 0;
    padding: 10px 14px;
    font-size: 0.88rem;
}

.view-details-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(79, 80, 229, 0.35);
}

/* Full Screen Modal */
.fullscreen-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 10000;
    overflow: hidden;
}

.fullscreen-modal[style*="display: flex"] {
    display: flex !important;
}

.fullscreen-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
}

.fullscreen-modal-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    animation: scaleIn 0.35s ease-out;
    background: #ffffff;
}

@keyframes slideInFromRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.fullscreen-modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    border: none;
    background: var(--primary-light);
    color: var(--primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.2s;
    z-index: 10001;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.fullscreen-modal-close:hover {
    background: var(--primary);
    color: #fff;
    transform: rotate(90deg) scale(1.1);
}

.fullscreen-updated-timestamp {
    /* Scroll with content instead of staying fixed */
    position: relative;
    z-index: 1;
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.fullscreen-updated-timestamp i {
    font-size: 0.75rem;
    opacity: 0.9;
}

.fullscreen-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 40px;
    padding-top: 80px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    background: #ffffff;
}

.fullscreen-modal-body::-webkit-scrollbar {
    width: 10px;
}

.fullscreen-modal-body::-webkit-scrollbar-track {
    background: var(--primary-light);
    border-radius: 10px;
}

.fullscreen-modal-body::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

.fullscreen-modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Full Screen Modal Content Styles */
.fullscreen-candidate-header {
    display: flex;
    align-items: center;
    gap: 24px;
    padding-bottom: 32px;
    border-bottom: 2px solid var(--border);
    margin-bottom: 32px;
}

.fullscreen-candidate-avatar {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    object-fit: cover;
    border: 4px solid var(--primary-light);
    box-shadow: 0 12px 24px rgba(79, 80, 229, 0.2);
}

.fullscreen-candidate-info h2 {
    font-size: 2rem;
    color: var(--primary-dark);
    margin-bottom: 8px;
    font-weight: 700;
}

.fullscreen-candidate-info .candidate-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.fullscreen-candidate-info .candidate-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    font-size: 0.95rem;
    color: var(--text-muted);
}

.fullscreen-section {
    margin-bottom: 40px;
}

.fullscreen-section-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border);
}

.fullscreen-section-content {
    background: var(--primary-light);
    border-radius: 16px;
    padding: 24px;
    border-left: 4px solid var(--primary);
}

.fullscreen-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}

.fullscreen-contact-item {
    background: white;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.fullscreen-contact-item strong {
    display: block;
    color: var(--primary-dark);
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.fullscreen-contact-item span {
    color: var(--text-main);
    font-size: 1rem;
}

.fullscreen-skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.fullscreen-skill-pill {
    background: var(--success);
    color: white;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 0.95rem;
    font-weight: 600;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 12px rgba(16, 163, 127, 0.25);
    transition: all 0.3s ease;
}

.fullscreen-skill-pill:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(16, 163, 127, 0.4);
    background: #0d8a6b;
}

.fullscreen-experience-item {
    background: white;
    padding: 24px;
    border-radius: 16px;
    margin-bottom: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.1);
    transition: all 0.2s ease;
}

.fullscreen-experience-item:hover {
    transform: translateX(8px);
    box-shadow: 0 8px 20px rgba(79, 80, 229, 0.15);
    border-left: 4px solid var(--primary);
}

.fullscreen-exp-title {
    font-weight: 700;
    color: var(--primary-dark);
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.fullscreen-exp-company {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 12px;
    font-weight: 600;
}

.fullscreen-exp-duration {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 16px;
}

.fullscreen-exp-desc {
    color: var(--text-main);
    line-height: 1.8;
    font-size: 1rem;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.fullscreen-education-item {
    background: white;
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.1);
    transition: all 0.2s ease;
}

.fullscreen-education-item:hover {
    transform: translateX(8px);
    box-shadow: 0 8px 20px rgba(79, 80, 229, 0.15);
    border-left: 4px solid var(--danger);
}

.fullscreen-edu-degree {
    font-weight: 700;
    color: var(--text-main);
    font-size: 1.1rem;
    margin-bottom: 6px;
}

.fullscreen-edu-institution {
    color: var(--text-muted);
    font-size: 1rem;
}

.fullscreen-summary-text {
    color: var(--text-main);
    line-height: 1.8;
    font-size: 1.05rem;
    padding: 20px;
    background: white;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.fullscreen-websites {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.fullscreen-website-link {
    background: white;
    padding: 12px 18px;
    border-radius: 12px;
    border: 1px solid var(--border);
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.fullscreen-website-link:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.3);
}

.loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--primary-dark);
    z-index: 200;
    background: rgba(255, 255, 255, 0.98);
    padding: 24px 48px;
    border-radius: 20px;
    box-shadow: 0 12px 40px rgba(80, 48, 165, 0.25);
    border: 1px solid rgba(79, 80, 229, 0.2);
    font-weight: 600;
    font-size: 1rem;
}

.loading-spinner {
    width: 32px;
    height: 32px;
    border: 4px solid rgba(79, 80, 229, 0.25);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading span {
    animation: fadePulse 1.4s infinite;
}

.no-results {
    text-align: center;
    color: var(--text-muted);
    padding: 40px;
    font-size: 1rem;
}

/* ============================================
   UPLOAD RESUME STYLES
   ============================================ */

.upload-area {
    margin-bottom: 12px;
}

.upload-dropzone {
    border: 2px dashed var(--border);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    background: var(--card-bg);
    transition: all 0.3s ease;
    cursor: pointer;
    min-height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.upload-dropzone.upload-disabled {
    pointer-events: none;
    opacity: 0.7;
}

.upload-dropzone:hover {
    border-color: var(--primary);
    background: var(--primary-light);
}

.upload-dropzone.drag-over {
    border-color: var(--primary);
    background: var(--primary-light);
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.2);
}

.upload-dropzone i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 8px;
}

.upload-dropzone p {
    color: var(--text-main);
    font-size: 0.9rem;
    margin: 0;
}

.upload-link {
    color: var(--primary);
    text-decoration: underline;
    cursor: pointer;
    font-weight: 600;
}

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

.upload-dropzone small {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.new-interview-dropzone {
    border: 2px dashed var(--gray-200);
    border-radius: var(--radius);
    padding: var(--space-24);
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    background: var(--gray-50);
}
.new-interview-dropzone:hover {
    border-color: var(--primary);
    background: var(--gray-100);
}
.new-interview-dropzone.drag-over {
    border-color: var(--primary);
    background: var(--gray-100);
}

.upload-progress {
    margin-top: 12px;
    padding: 16px;
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.progress-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.progress-status {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
}

.progress-percentage {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-dark);
    background: var(--primary-light);
    padding: 4px 10px;
    border-radius: 6px;
    min-width: 50px;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 12px;
    background: var(--border);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 6px;
    transition: width 0.4s ease;
    width: 0%;
    box-shadow: 0 2px 4px rgba(79, 80, 229, 0.3);
}

.progress-details {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-top: 4px;
}

/* ============================================
   UPLOAD LOGS
   ============================================ */

.upload-job-status-panel {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}
.upload-job-status-panel h5 {
    font-size: 0.9rem;
    color: var(--text-main);
    margin: 0 0 10px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.upload-job-status-panel h5 i {
    color: var(--primary);
}
.upload-job-status-content {
    font-size: 0.85rem;
}
.upload-job-status-empty {
    color: var(--text-muted);
    margin: 0;
    font-size: 0.85rem;
}
/* Remaining-work progress UI */
.upload-job-status-active {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.upload-job-status-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
}
.upload-job-status-bar-wrap {
    width: 100%;
}
.upload-job-status-segmented-bar {
    display: flex;
    width: 100%;
    height: 8px;
    border-radius: 9999px;
    overflow: hidden;
    background: var(--gray-200);
}
.upload-job-seg {
    height: 100%;
    min-width: 2px;
    transition: width 0.25s ease;
}
.upload-job-seg.processing-seg {
    background: var(--primary);
}
.upload-job-seg.pending-seg {
    background: var(--gray-300);
}
.upload-job-status-counts {
    font-size: 12px;
    color: var(--gray-600);
}

/* Complete state */
.upload-job-status-complete {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 0;
}
.upload-job-complete-icon {
    font-size: 2rem;
    color: var(--success);
}
.upload-job-complete-icon i {
    color: inherit;
}
.upload-job-complete-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-800);
}
.upload-job-complete-desc {
    font-size: 12px;
    color: var(--gray-600);
}

.upload-logs-container {
    margin-top: 16px;
    border-top: 1px solid var(--border);
    padding-top: 12px;
}

.upload-logs-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.upload-logs-header h5 {
    font-size: 0.9rem;
    color: var(--text-main);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.clear-logs-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
    font-size: 0.8rem;
}

.clear-logs-btn:hover {
    background: rgba(239, 71, 111, 0.1);
    color: var(--danger);
}

.upload-logs {
    max-height: 200px;
    overflow-y: auto;
    background: #1e1e1e;
    border-radius: 6px;
    padding: 12px;
    font-family: 'Courier New', monospace;
    font-size: 0.75rem;
    line-height: 1.6;
}

.log-entry {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 6px;
    padding: 4px 0;
    word-wrap: break-word;
}

.log-entry:last-child {
    margin-bottom: 0;
}

.log-time {
    color: #888;
    font-size: 0.7rem;
    white-space: nowrap;
    flex-shrink: 0;
}

.log-entry i {
    flex-shrink: 0;
    width: 14px;
    text-align: center;
}

.log-message {
    flex: 1;
    word-break: break-word;
}

.log-entry.log-info {
    color: #d4d4d4;
}

.log-entry.log-info i {
    color: #4ec9b0;
}

.log-entry.log-success {
    color: #89d185;
}

.log-entry.log-success i {
    color: #89d185;
}

.log-entry.log-error {
    color: #f48771;
}

.log-entry.log-error i {
    color: #f48771;
}

.log-entry.log-warning {
    color: #dcdcaa;
}

.log-entry.log-warning i {
    color: #dcdcaa;
}

/* Scrollbar styling for logs */
.upload-logs::-webkit-scrollbar {
    width: 6px;
}

.upload-logs::-webkit-scrollbar-track {
    background: #2d2d2d;
    border-radius: 3px;
}

.upload-logs::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 3px;
}

.upload-logs::-webkit-scrollbar-thumb:hover {
    background: #777;
}

.upload-results {
    margin-top: 16px;
    padding: 16px;
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border);
    max-height: 400px;
    overflow-y: auto;
}

.upload-results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.upload-results-header h4 {
    color: var(--primary-dark);
    font-size: 1rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.close-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background: rgba(239, 71, 111, 0.1);
    color: var(--danger);
}

.upload-summary {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.summary-item {
    flex: 1;
    min-width: 80px;
    padding: 12px;
    background: var(--primary-light);
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-main);
}

.summary-item.success {
    background: rgba(16, 163, 127, 0.1);
    color: var(--success);
}

.summary-item.error {
    background: rgba(239, 71, 111, 0.1);
    color: var(--danger);
}

.summary-item i {
    font-size: 1.2rem;
}

.upload-success-list,
.upload-error-list {
    margin-bottom: 16px;
}

.upload-success-list h5,
.upload-error-list h5 {
    color: var(--text-main);
    font-size: 0.9rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.upload-file-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.upload-file-item {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--card-bg);
}

.upload-file-item.success {
    border-left: 3px solid var(--success);
}

.upload-file-item.error {
    border-left: 3px solid var(--danger);
}

.file-info {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.file-info i {
    color: var(--primary);
}

.file-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-left: 24px;
}

.file-error {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--danger);
    font-size: 0.85rem;
    margin-left: 24px;
}

#processUploadBtn:disabled,
#processUrlsBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================
   UPLOAD METHOD TABS
   ============================================ */

.upload-method-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--border);
}

.upload-method-tab {
    flex: 1;
    padding: 12px 16px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: -2px;
}

.upload-method-tab:hover {
    color: var(--primary);
    background: var(--primary-light);
}

.upload-method-tab.active {
    color: var(--primary-dark);
    border-bottom-color: var(--primary);
    background: var(--primary-light);
}

.upload-method-tab i {
    font-size: 1rem;
}

.upload-method-content {
    /* Content sections for each method */
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ============================================
   UPLOAD MAIN PAGE LAYOUT
   ============================================ */

.upload-main-content {
    max-width: 900px;
    margin: 0 auto;
}

.upload-controls-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

/* Upload job-in-progress notification banner */
.upload-job-banner {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(37, 99, 235, 0.08));
    border: 1px solid rgba(59, 130, 246, 0.35);
    border-radius: 12px;
    padding: 14px 20px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--text);
}
.upload-job-banner i {
    color: var(--primary);
    font-size: 1.25rem;
    flex-shrink: 0;
}

.upload-control-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
}

.upload-control-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.upload-control-header i {
    font-size: 1.5rem;
    color: var(--primary);
}

.upload-control-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-main);
}

/* ============================================
   ANIMATION CONTAINER
   ============================================ */

.upload-animation-container {
    margin-top: 40px;
    padding: 40px;
    background: linear-gradient(135deg, var(--primary-light) 0%, rgba(255, 255, 255, 0.8) 100%);
    border-radius: 16px;
    border: 2px solid var(--border);
}

.animation-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

.character-container {
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    box-shadow: 0 8px 24px rgba(79, 80, 229, 0.15);
    overflow: hidden;
}

.character-sprite {
    width: 100%;
    height: 100%;
    object-fit: contain;
    animation: characterBounce 2s ease-in-out infinite;
}

@keyframes characterBounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Character animations for different stages */
.character-sprite.upload-stage {
    animation: characterRun 1s steps(8) infinite;
}

@keyframes characterRun {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-100%);
    }
}

.character-sprite.parsing-stage {
    animation: characterHammer 0.8s steps(6) infinite;
}

@keyframes characterHammer {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-5px) rotate(-5deg);
    }
}

.character-sprite.embedding-stage {
    animation: characterCut 1s steps(8) infinite;
}

@keyframes characterCut {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.character-sprite.done-stage {
    animation: characterJump 0.6s ease-in-out infinite;
}

@keyframes characterJump {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-20px) scale(1.1);
    }
}

/* Progress Container */
.progress-container {
    width: 100%;
    max-width: 600px;
}

.progress-bar-wrapper {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.1);
}

.progress-bar-bg {
    width: 100%;
    height: 24px;
    background: var(--border);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    margin-bottom: 12px;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    transition: width 0.3s ease;
    position: relative;
    overflow: hidden;
}

.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.3) 50%,
        transparent 100%
    );
    animation: progressShine 2s infinite;
}

@keyframes progressShine {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.progress-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: var(--text-main);
}

.progress-text span:first-child {
    font-weight: 600;
    color: var(--primary-dark);
}

.progress-text span:last-child {
    color: var(--text-muted);
    font-weight: 500;
}

/* ============================================
   URL INPUT AREA
   ============================================ */

.url-input-area {
    margin-bottom: 12px;
}

.url-input-textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text-main);
    font-size: 0.9rem;
    font-family: inherit;
    resize: vertical;
    min-height: 120px;
    transition: all 0.2s ease;
}

.url-input-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.1);
}

.url-input-textarea::placeholder {
    color: var(--text-muted);
}

@media (max-width: 1100px) {
    .layout {
        flex-direction: column;
    }
    .control-panel {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border);
        flex-direction: row;
        flex-wrap: wrap;
        gap: 16px;
    }
    .panel-section {
        flex: 1 1 300px;
    }
}

@media (max-width: 768px) {
    .candidate-grid {
        grid-template-columns: 1fr;
    }
    .fullscreen-modal-body {
        padding: 20px;
        padding-top: 60px;
    }
    .fullscreen-candidate-header {
        flex-direction: column;
        text-align: center;
    }
}

/* ============================================
   SHORTLISTS & HISTORY STYLES
   ============================================ */

.add-to-shortlist-btn {
    background: var(--primary-light);
    color: var(--primary-dark);
    border: 1px solid var(--border);
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.add-to-shortlist-btn:hover {
    background: var(--primary);
    color: #fff;
    transform: translateY(-1px);
}

.shortlist-item,
.history-item {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.shortlist-item:hover,
.history-item:hover {
    border-color: var(--primary);
    background: var(--primary-light);
    transform: translateX(4px);
}

.shortlist-item strong,
.history-item strong {
    color: var(--text-main);
    display: block;
    margin-bottom: 4px;
}

.shortlist-item .ghost-btn,
.history-item .ghost-btn {
    opacity: 0.6;
}

.shortlist-item:hover .ghost-btn,
.history-item:hover .ghost-btn {
    opacity: 1;
}

/* ============================================
   SIDEBAR PROFILE & TOKEN CARD
   ============================================ */

/* Sidebar item (New Chat) - similar to sidebar nav items */
.sidebar-item {
    display: flex;
    align-items: center;
    gap: var(--space-8);
    padding: var(--space-12) var(--space-16);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
    background: #fff;
    color: var(--gray-700);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    text-align: left;
    width: 100%;
}
.sidebar-item:hover {
    background: var(--gray-50);
    border-color: var(--gray-300);
    color: var(--primary);
}
.sidebar-item i {
    font-size: 1rem;
    opacity: 0.9;
}
.sidebar-new-chat {
    margin-bottom: var(--space-4);
}

/* Profile header: [ Avatar ] [ Name + Role ] ... [ Logout ] */
.sidebar-profile-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    margin-bottom: 4px;
    border-bottom: 1px solid var(--gray-200);
}
.sidebar-profile-avatar {
    flex-shrink: 0;
}
.sidebar-profile-header .avatar-circle {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, #6366F1 100%);
    border-radius: 50%;
    color: #fff;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.25);
}
.sidebar-profile-name-role {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.sidebar-profile-name {
    font-size: 17px;
    font-weight: 600;
    color: var(--gray-900);
    line-height: 1.3;
    word-break: break-word;
}
.sidebar-profile-role {
    font-size: 13px;
    color: var(--gray-500);
    font-weight: 500;
}
.sidebar-logout-btn {
    flex-shrink: 0;
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid #E5E7EB;
    color: var(--gray-600);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.sidebar-logout-btn:hover {
    background: #FEF2F2;
    color: #DC2626;
    border-color: #FECACA;
}

/* Token card */
.sidebar-token-card {
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 14px;
    padding: 12px 14px;
    margin-bottom: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}
.sidebar-token-card-title {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-700);
}
.sidebar-token-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.sidebar-token-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #D97706;
    font-size: 1.25rem;
}
.sidebar-token-number {
    font-size: 20px;
    font-weight: 700;
    color: var(--gray-900);
    flex: 1;
}
.sidebar-token-topup-btn {
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    cursor: pointer;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}
.sidebar-token-topup-btn:hover {
    background: rgba(79, 80, 229, 0.08);
    color: var(--primary-dark);
}
.sidebar-token-progress-wrap {
    width: 100%;
}
.sidebar-token-progress-track {
    height: 5px;
    background: var(--gray-200);
    border-radius: 9999px;
    overflow: hidden;
}
.sidebar-token-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary) 0%, #6366F1 100%);
    border-radius: 9999px;
    transition: width 0.25s ease;
}

/* Logout confirm button in modal */
.sidebar-logout-confirm-btn {
    background: #DC2626 !important;
    border-color: #DC2626 !important;
}
.sidebar-logout-confirm-btn:hover {
    background: #B91C1C !important;
    border-color: #B91C1C !important;
}

/* Pool card (same layout as token card) */
.sidebar-pool-card {
    background: #fff;
    border: 1px solid var(--gray-200);
    border-radius: 14px;
    padding: 12px 14px;
    margin-bottom: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
.sidebar-pool-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-color: var(--gray-300);
}
.sidebar-pool-card-title {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-700);
}
.sidebar-pool-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}
.sidebar-pool-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.25rem;
}
.sidebar-pool-number {
    font-size: 20px;
    font-weight: 700;
    color: var(--gray-900);
    flex: 1;
}
.sidebar-pool-view-btn {
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    cursor: pointer;
    font-weight: 500;
    transition: background 0.2s ease, color 0.2s ease;
}
.sidebar-pool-view-btn:hover {
    background: rgba(79, 80, 229, 0.08);
    color: var(--primary-dark);
}
.sidebar-pool-sublabel {
    margin: 0;
    font-size: 12px;
    color: var(--gray-500);
    line-height: 1.4;
}
#searchSidebarSection {
    margin-top: 0;
}

/* Legacy avatar circle (used in sidebar profile) */
.avatar-circle {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, 
        #6C3EFF 0%, 
        #8B5CF6 50%,
        #A78BFA 100%);
    border-radius: 14px;
    color: #ffffff;
    font-size: 1.4rem;
    box-shadow: 
        0 4px 12px rgba(79, 80, 229, 0.35),
        0 2px 4px rgba(79, 80, 229, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}
.avatar-circle::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, 
        transparent 30%, 
        rgba(255, 255, 255, 0.1) 50%, 
        transparent 70%);
    animation: shine 3s infinite;
}
@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.stat-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: linear-gradient(135deg, 
        rgba(79, 80, 229, 0.08) 0%, 
        rgba(79, 80, 229, 0.04) 100%);
    border-radius: 12px;
    border: 1px solid rgba(79, 80, 229, 0.15);
    transition: all 0.2s ease;
}

.stat-badge:hover {
    background: linear-gradient(135deg, 
        rgba(79, 80, 229, 0.12) 0%, 
        rgba(79, 80, 229, 0.06) 100%);
    border-color: rgba(79, 80, 229, 0.25);
    transform: translateX(2px);
}

.stat-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, 
        #6C3EFF 0%, 
        #8B5CF6 100%);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1.1rem;
    box-shadow: 
        0 2px 8px rgba(79, 80, 229, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0;
}

.stat-badge-pool {
    align-items: flex-start;
}

.stat-badge-pool .stat-icon {
    margin-top: 3px;
}

.stat-badge-pool .stat-content {
    gap: 1px;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    line-height: 1.2;
    margin: 0;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, 
        var(--primary-dark) 0%, 
        var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    line-height: 1.3;
    letter-spacing: 0.01em;
    margin: 0;
}

.stat-sublabel {
    font-size: 0.65rem;
    font-weight: 400;
    color: var(--text-muted);
    opacity: 0.85;
    line-height: 1.35;
    margin: 0;
    letter-spacing: 0.02em;
}

/* ============================================
   PREMIUM CANDIDATE STYLES
   ============================================ */

.locked-candidate {
    position: relative;
    opacity: 0.95;
}

.premium-banner {
    background: linear-gradient(135deg, #FFC857 0%, #FFB020 100%);
    color: #2D2353;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(255, 200, 87, 0.3);
}

.premium-banner i {
    font-size: 0.8rem;
}

/* Premium Badge - Always visible for admin candidates */
.premium-badge {
    background: linear-gradient(135deg, #FBBF24 0%, #F59E0B 100%);
    color: #1a1a1a;
    padding: var(--space-4) var(--space-12);
    border-radius: var(--radius-full);
    font-size: var(--text-label);
    font-weight: 600;
    text-align: center;
    margin-bottom: var(--space-8);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    box-shadow: var(--shadow-soft);
    position: relative;
    z-index: 5;
}

.premium-badge i {
    font-size: 0.75rem;
    color: #1a1a1a;
}

.info-item.blurred {
    filter: blur(4px);
    user-select: none;
    pointer-events: none;
    position: relative;
}

/* Horizontal Candidate Card for My Candidates Page */
.horizontal-candidate-card {
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid rgba(79, 80, 229, 0.15);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.25s ease;
    animation: fadeSlideIn 0.4s ease-out;
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.08);
    margin-bottom: 12px;
    cursor: pointer;
}

.horizontal-candidate-card:hover {
    transform: translateX(4px);
    box-shadow: 0 6px 16px rgba(79, 80, 229, 0.12);
    border-color: var(--primary);
}

.horizontal-candidate-card .candidate-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    flex-shrink: 0;
}

.horizontal-candidate-card .candidate-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.horizontal-candidate-card .candidate-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-main);
    min-width: 150px;
}

.horizontal-candidate-card .candidate-detail {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--text-muted);
    min-width: 120px;
}

.horizontal-candidate-card .candidate-detail i {
    color: var(--primary);
    font-size: 0.85rem;
    width: 16px;
}

.horizontal-candidate-card .candidate-detail strong {
    color: var(--text-main);
    margin-right: 4px;
}

.horizontal-candidate-card .candidate-pool-actions {
    flex-shrink: 0;
    margin-left: auto;
}

.horizontal-candidate-card .candidate-pool-actions .schedule-interview-btn {
    white-space: nowrap;
}

.horizontal-candidate-card .premium-badge {
    margin-left: 8px;
    flex-shrink: 0;
}

.info-item.blurred::after {
    content: '🔒';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    filter: none;
    font-size: 1rem;
}

.locked-candidate-message {
    border: 1px solid rgba(79, 80, 229, 0.2);
}

.unlock-candidate-btn {
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(79, 80, 229, 0.3);
}

.unlock-candidate-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.4);
}

.unlock-candidate-btn:active {
    transform: translateY(0);
}

/* ============================================
   TOGGLE SWITCH
   ============================================ */

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch input:checked + .toggle-slider {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 1px var(--primary);
}

.toggle-switch:hover .toggle-slider {
    box-shadow: 0 0 8px rgba(79, 80, 229, 0.3);
}

/* ============================================
   MODAL STYLES (for WhatsApp Outreach)
   ============================================ */

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    backdrop-filter: blur(6px);
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--card-bg);
    margin: auto;
    padding: 0;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: scaleIn 0.35s ease-out;
    animation: modalSlideIn 0.3s ease-out;
    max-width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, rgba(79, 80, 229, 0.05) 0%, rgba(79, 80, 229, 0.02) 100%);
}

.message-preview-section {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: var(--space-12);
    margin-bottom: var(--space-16);
}
.message-preview-title {
    margin: 0 0 var(--space-8) 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    display: flex;
    align-items: center;
    gap: var(--space-8);
}
.message-preview-title i {
    color: var(--primary);
}
.message-preview-content {
    font-size: 13px;
    line-height: 1.6;
    color: var(--gray-700);
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 180px;
    overflow-y: auto;
}
.message-preview-content .placeholder {
    color: var(--gray-400);
    font-style: italic;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-header h3 i {
    color: #25D366;
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.form-group {
    margin-bottom: 16px;
}

.form-input {
    width: 100%;
    padding: var(--space-12) var(--space-16);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    font-size: var(--text-body);
    font-family: var(--font-family);
    background: var(--card-bg);
    color: var(--text-main);
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.12);
}

.form-input::placeholder {
    color: var(--gray-400);
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-main);
}

/* ============================================
   CUSTOM MODAL SYSTEM (Alert, Confirm, Prompt)
   ============================================ */

.custom-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease-out;
}

.custom-modal-overlay.show {
    display: flex;
}

.custom-modal-dialog {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 480px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    animation: scaleIn 0.25s ease-out;
    transform-origin: center;
}

.custom-modal-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 12px;
}

.custom-modal-header i {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    flex-shrink: 0;
}

.custom-modal-header.info i {
    background: linear-gradient(135deg, var(--primary-light) 0%, rgba(79, 80, 229, 0.1) 100%);
    color: var(--primary);
}

.custom-modal-header.success i {
    background: linear-gradient(135deg, rgba(16, 163, 127, 0.1) 0%, rgba(16, 163, 127, 0.05) 100%);
    color: var(--success);
}

.custom-modal-header.warning i {
    background: linear-gradient(135deg, rgba(255, 200, 87, 0.2) 0%, rgba(255, 200, 87, 0.1) 100%);
    color: #D97706;
}

.custom-modal-header.error i {
    background: linear-gradient(135deg, rgba(239, 71, 111, 0.1) 0%, rgba(239, 71, 111, 0.05) 100%);
    color: var(--danger);
}

.custom-modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-main);
    flex: 1;
}

.custom-modal-body {
    padding: 24px;
    color: var(--text-main);
    line-height: 1.6;
    font-size: 0.95rem;
}

.custom-modal-body p {
    margin: 0 0 16px 0;
}

.custom-modal-body p:last-child {
    margin-bottom: 0;
}

.custom-modal-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-main);
    background: var(--card-bg);
    transition: all 0.2s;
    margin-top: 12px;
}

.custom-modal-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.1);
}

.custom-modal-actions {
    padding: 16px 24px 24px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    border-top: 1px solid var(--border);
}

.custom-modal-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.custom-modal-btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.3);
}

.custom-modal-btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(79, 80, 229, 0.4);
}

.custom-modal-btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-main);
    border: 1px solid var(--border);
}

.custom-modal-btn-secondary:hover {
    background: var(--border);
}

.custom-modal-btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #D91E4A 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(239, 71, 111, 0.3);
}

.custom-modal-btn-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(239, 71, 111, 0.4);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Horizontal Candidate Card for My Candidates Page */
.horizontal-candidate-card {
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid rgba(79, 80, 229, 0.15);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.25s ease;
    animation: fadeSlideIn 0.4s ease-out;
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.08);
    margin-bottom: 12px;
    cursor: pointer;
}

.horizontal-candidate-card:hover {
    transform: translateX(4px);
    box-shadow: 0 6px 16px rgba(79, 80, 229, 0.12);
    border-color: var(--primary);
}

.horizontal-candidate-card .candidate-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    flex-shrink: 0;
}

.horizontal-candidate-card .candidate-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.horizontal-candidate-card .candidate-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-main);
    min-width: 150px;
}

.horizontal-candidate-card .candidate-detail {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--text-muted);
    min-width: 120px;
}

.horizontal-candidate-card .candidate-detail i {
    color: var(--primary);
    font-size: 0.85rem;
    width: 16px;
}

.horizontal-candidate-card .candidate-detail strong {
    color: var(--text-main);
    margin-right: 4px;
}

.horizontal-candidate-card .premium-badge {
    margin-left: auto;
    flex-shrink: 0;
}

/* Make stat badge clickable */
.stat-badge {
    transition: all 0.2s ease;
    position: relative;
}

.stat-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 80, 229, 0.15);
}

/* Recharge Button */
.recharge-btn {
    background: linear-gradient(135deg, #10a37f 0%, #0a8a6a 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    white-space: nowrap;
}

.recharge-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 163, 127, 0.3);
    opacity: 0.9;
}

.recharge-btn i {
    font-size: 0.85rem;
}

/* Credit Package Cards */
.credit-package-card {
    background: var(--card-bg);
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.credit-package-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(79, 80, 229, 0.2);
}

.credit-package-card.selected {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(79, 80, 229, 0.1) 0%, rgba(79, 80, 229, 0.05) 100%);
}

.credit-package-card .package-name {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 500;
}

.credit-package-card .package-credits {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 4px;
}

.credit-package-card .package-credits-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.credit-package-card .package-price {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 4px;
}

.credit-package-card .package-price-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.credit-package-card .package-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #FFC857 0%, #FFB020 100%);
    color: #2D2353;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 700;
}

/* ============================================
   WEB SEARCH ROBOT POPUP (bottom-right)
   ============================================ */

.web-search-popup-icon {
    position: fixed;
    bottom: 106px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    box-shadow: 0 4px 20px rgba(79, 80, 229, 0.45);
    cursor: pointer;
    z-index: 9998;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.web-search-popup-icon:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(79, 80, 229, 0.55);
}

.web-search-popup-icon .web-search-popup-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background: var(--accent);
    color: var(--text-main);
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.web-search-popup-icon .web-search-popup-searching-label {
    position: absolute;
    left: 50%;
    bottom: 100%;
    transform: translateX(-50%) translateY(-10px);
    white-space: nowrap;
    font-size: 0.8rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.95);
    background: rgba(0, 0, 0, 0.35);
    padding: 6px 12px;
    border-radius: 20px;
    pointer-events: none;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.web-search-popup-icon.web-search-popup-icon--searching .web-search-popup-badge {
    display: none;
}

.web-search-robot-panel {
    position: fixed;
    bottom: 90px;
    right: 24px;
    width: 400px;
    max-width: calc(100vw - 48px);
    max-height: 70vh;
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    overflow: hidden;
    animation: webSearchPanelIn 0.25s ease-out;
}

@keyframes webSearchPanelIn {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.web-search-robot-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: linear-gradient(135deg, var(--primary-light) 0%, rgba(79, 80, 229, 0.12) 100%);
    border-bottom: 1px solid var(--border);
}

.web-search-robot-panel-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 1rem;
}

.web-search-robot-panel-title i {
    font-size: 1.2rem;
    color: var(--primary);
}

.web-search-robot-panel-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    transition: color 0.2s, background 0.2s;
}

.web-search-robot-panel-close:hover {
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.06);
}

.web-search-robot-panel-body {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
    min-height: 120px;
}

.web-search-robot-summary {
    font-size: 0.9rem;
    color: var(--text-main);
    line-height: 1.5;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.web-search-robot-profiles {
    margin-bottom: 16px;
}

.web-search-robot-profiles h4,
.web-search-robot-links h4 {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.web-search-robot-profile-item {
    padding: 10px 12px;
    background: rgba(79, 80, 229, 0.06);
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.web-search-robot-profile-item .profile-name {
    font-weight: 600;
    color: var(--primary-dark);
}

.web-search-robot-profile-item .profile-role {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.web-search-robot-profile-item .profile-source {
    font-size: 0.8rem;
    margin-top: 4px;
}

.web-search-robot-profile-item a {
    color: var(--primary);
    text-decoration: none;
}

.web-search-robot-profile-item a:hover {
    text-decoration: underline;
}

.web-search-robot-links {
    margin-top: 12px;
}

.web-search-robot-link-item {
    display: block;
    padding: 8px 0;
    font-size: 0.9rem;
    color: var(--primary);
    text-decoration: none;
    word-break: break-all;
    border-bottom: 1px solid var(--border);
}

.web-search-robot-link-item:last-child {
    border-bottom: none;
}

.web-search-robot-link-item:hover {
    text-decoration: underline;
}

.web-search-robot-link-item .link-type {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-left: 6px;
}

.web-search-robot-loading,
.web-search-robot-error {
    text-align: center;
    padding: 16px;
    color: var(--text-muted);
}

.web-search-robot-error {
    color: var(--danger);
}

/* ============================================
   MY CHATS — Premium chat layout
   ============================================ */

.chat-layout-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #F5F6F8;
}

#candidateChatSection {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #F5F6F8;
}

.candidate-chat-container {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.candidate-chat-layout {
    flex: 1;
    min-height: 0;
    min-width: 0;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 0;
    background: #F5F6F8;
}

/* ——— Left panel: Chat list (280–340px) ——— */
.candidate-chat-list-pane {
    width: 300px;
    min-width: 300px;
    min-height: 0;
    overflow: hidden;
    background: #FFFFFF;
    display: flex;
    flex-direction: column;
    box-shadow: 1px 0 0 rgba(0, 0, 0, 0.06);
}

.candidate-chat-list-header {
    padding: 16px 12px 12px;
    border-bottom: 1px solid #E9ECEF;
    flex-shrink: 0;
}

.chat-sidebar-title {
    margin: 0 0 12px 0;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--gray-900);
}

.chat-search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.chat-search-input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #E9ECEF;
    border-radius: 10px;
    font-size: 14px;
    background: #F5F6F8;
    color: var(--text-main);
    transition: border-color 0.15s ease, background 0.15s ease;
}

.chat-search-input:focus {
    outline: none;
    border-color: var(--primary);
    background: #fff;
}

.chat-search-filter-btn {
    width: 40px;
    height: 40px;
    border: 1px solid #E9ECEF;
    border-radius: 10px;
    background: #fff;
    color: var(--gray-500);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease, background 0.15s ease;
}

.chat-search-filter-btn:hover {
    background: #F5F6F8;
    color: var(--primary);
}

.chat-filters-row {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.chat-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 8px;
    border: 1px solid #E9ECEF;
    border-radius: 999px;
    font-size: 12px;
    color: var(--gray-600);
    background: #fff;
}

.chat-filter-chip input {
    margin: 0;
}

.chat-filter-query {
    flex: 1;
    min-width: 160px;
    padding: 7px 10px;
    border: 1px solid #E9ECEF;
    border-radius: 8px;
    font-size: 12px;
    background: #fff;
    color: var(--text-main);
}

.chat-filter-query:focus {
    outline: none;
    border-color: var(--primary);
}

.candidate-chat-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 8px 0;
}

.candidate-chat-list-empty {
    padding: 20px 16px;
    text-align: center;
    font-size: 14px;
    color: var(--gray-500);
}

/* Chat list item: [Avatar] [Name + Status] [Time] / [Preview] */
.candidate-chat-list-item {
    display: grid;
    grid-template-columns: 48px 1fr;
    grid-template-rows: auto auto;
    gap: 2px 12px;
    padding: 12px 16px;
    margin: 0 8px 4px;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.15s ease;
    position: relative;
    align-items: center;
}

.candidate-chat-list-item:hover {
    background: #F5F6F8;
}

.candidate-chat-list-item.active {
    background: #E8ECFF;
    box-shadow: none;
}

.candidate-chat-list-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    min-height: 24px;
    background: var(--primary);
    border-radius: 0 3px 3px 0;
}

.chat-list-item-avatar {
    grid-row: 1 / -1;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #E9ECEF;
    color: var(--gray-700);
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.candidate-chat-list-item.active .chat-list-item-avatar {
    background: var(--indigo-100);
    color: var(--primary);
}

.candidate-chat-list-title {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-900);
}

.candidate-chat-list-item .chat-list-item-time {
    font-size: 11px;
    color: var(--gray-500);
    flex-shrink: 0;
}

.candidate-chat-list-item.unread .candidate-chat-list-title {
    font-weight: 700;
}

.candidate-chat-list-snippet {
    font-size: 13px;
    color: var(--gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.candidate-chat-list-item.unread .candidate-chat-list-snippet {
    color: var(--gray-700);
}

.chat-list-unread-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 7px;
    border-radius: 999px;
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

/* ——— Right panel: Active chat ——— */
.candidate-chat-main-pane {
    min-height: 0;
    min-width: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: #FFFFFF;
    border-radius: 12px 0 0 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.candidate-chat-main-header {
    padding: 12px 20px;
    border-bottom: 1px solid #E9ECEF;
    background: #fff;
    flex-shrink: 0;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.candidate-chat-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-header-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #E9ECEF;
    color: var(--gray-600);
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-header-info {
    flex: 1;
    min-width: 0;
}

.chat-header-name {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
}

.chat-header-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--gray-500);
    margin-top: 2px;
}

.chat-header-contact-details {
    margin-top: 2px;
    font-size: 12px;
    color: var(--gray-600);
    line-height: 1.3;
    word-break: break-word;
}

.chat-online-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22C55E;
    flex-shrink: 0;
}

.candidate-chat-timeline {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 200px;
    background: #F5F6F8;
}

.candidate-chat-empty,
.candidate-chat-loading,
.candidate-chat-error {
    color: var(--text-muted);
    text-align: center;
    padding: 20px;
    margin: 0;
}

.candidate-chat-msg {
    max-width: 85%;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.candidate-chat-msg-inbound {
    align-self: flex-start;
    align-items: flex-start;
}

.candidate-chat-msg-outbound {
    align-self: flex-end;
    align-items: flex-end;
}

.candidate-chat-bubble {
    padding: 10px 14px;
    border-radius: 12px;
    word-break: break-word;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 85%;
}
.candidate-chat-msg .candidate-chat-time {
    font-size: 10px;
    line-height: 1.2;
    color: var(--gray-500);
    opacity: 0.9;
    margin-top: 2px;
    margin-bottom: 0;
}
.candidate-chat-msg-inbound .candidate-chat-time {
    margin-left: 0;
    text-align: left;
}
.candidate-chat-msg-system .candidate-chat-time {
    text-align: center;
}
.candidate-chat-msg-outbound .candidate-chat-time {
    margin-right: 0;
    text-align: right;
}

/* Date divider (centered pill) */
.chat-date-divider {
    align-self: center;
    padding: 6px 14px;
    border-radius: 9999px;
    background: rgba(0, 0, 0, 0.06);
    font-size: 12px;
    color: var(--gray-600);
    margin: 8px 0;
}

.candidate-chat-msg-inbound .candidate-chat-bubble {
    background: #E9ECEF;
    color: var(--gray-900);
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.candidate-chat-msg-outbound .candidate-chat-bubble {
    align-items: flex-end;
    background: linear-gradient(135deg, #4F46E5 0%, #6366F1 100%);
    color: #fff;
    border: none;
    border-bottom-right-radius: 4px;
    box-shadow: 0 1px 3px rgba(79, 70, 229, 0.25);
}


.candidate-chat-text {
    font-size: 14px;
    line-height: 1.45;
}

.candidate-chat-media-link {
    display: inline-block;
    margin-top: 6px;
    font-size: 0.85rem;
    color: var(--primary);
}


.candidate-chat-msg-system {
    align-self: center;
    text-align: center;
}

.candidate-chat-system-content {
    font-size: 0.85rem;
    color: var(--text-muted);
    padding: 8px 12px;
    background: rgba(79, 80, 229, 0.08);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.candidate-chat-system-text {
    width: 100%;
}

.candidate-chat-send {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px 20px 20px;
    border-top: 1px solid #E9ECEF;
    background: #fff;
    flex-shrink: 0;
    box-shadow: 0 -1px 3px rgba(0, 0, 0, 0.04);
}

.chat-input-row {
    display: flex;
    align-items: flex-end;
    gap: 10px;
}

.chat-input-actions-wrap {
    position: relative;
    margin-bottom: 0;
}

.chat-input-action-btn {
    height: 44px;
    padding: 0 14px;
    border: 1px solid #E9ECEF;
    border-radius: 12px;
    background: #fff;
    color: var(--gray-600);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.chat-input-action-btn:hover {
    background: #F5F6F8;
    border-color: var(--indigo-200);
    color: var(--primary);
}

.chat-input-field {
    flex: 1;
    min-height: 44px;
    padding: 12px 16px;
    border: 1px solid #E9ECEF;
    border-radius: 12px;
    font-size: 14px;
    font-family: var(--font-family);
    resize: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.chat-input-field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 80, 229, 0.12);
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #4F46E5 0%, #6366F1 100%);
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.chat-send-btn:hover {
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.4);
}

.candidate-chat-send .form-input {
    flex: 1;
    min-height: 44px;
    resize: none;
}

.candidate-chat-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    position: relative;
}

.candidate-chat-action-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.candidate-chat-action-menu {
    position: absolute;
    bottom: 110%;
    left: 0;
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid rgba(79, 80, 229, 0.18);
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.16);
    padding: 6px;
    display: none;
    flex-direction: column;
    min-width: 220px;
    z-index: 20;
}

.candidate-chat-action-menu button {
    width: 100%;
    justify-content: flex-start;
    font-size: 0.85rem;
}

@media (max-width: 900px) {
    .candidate-chat-layout {
        grid-template-columns: 1fr;
    }
    .candidate-chat-list-pane {
        width: 100%;
        min-width: 0;
        max-height: 40vh;
    }
}

.candidate-whatsapp-chat-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid rgba(37, 211, 102, 0.5);
    background: linear-gradient(135deg, rgba(37, 211, 102, 0.12) 0%, rgba(34, 180, 88, 0.08) 100%);
    color: #1a7a3a;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.candidate-whatsapp-chat-btn:hover {
    background: linear-gradient(135deg, rgba(37, 211, 102, 0.2) 0%, rgba(34, 180, 88, 0.15) 100%);
    border-color: rgba(37, 211, 102, 0.7);
}
