:host {
  display: block;
  position: relative;
}
.main-div {
    width: 100%;
    min-height: 100vh;
    padding: 0;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 32px 24px 20px 24px;
    background-color: transparent;
}

.header-left {
    .page-title {
        font-size: 32px;
        font-weight: 700;
        color: #1a1a1a;
        margin: 0 0 6px 0;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    }

    .page-subtitle {
        font-size: 15px;
        color: #666;
        margin: 0;
        font-weight: 400;
    }
}

.header-right {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;      
    margin-left: auto; 

    .view-buttons {
        display: flex;
        gap: 4px;
        padding: 4px;
        background-color: #f5f5f5;
        border-radius: 10px;
    }

    .view-btn {
        border: none;
        background-color: transparent;
        height: 36px;
        width: 36px;
        color: #666;
        border-radius: 8px;
        padding: 0;
        cursor: pointer;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        justify-content: center;

        mat-icon {
            font-size: 20px;
            width: 20px;
            height: 20px;
        }

        &:hover:not(.active) {
            background-color: #e8e8e8;
            color: #333;
        }

        &.active {
            background-color: #16a34a;
            color: #fff;
        }
    }

    .action-btn {
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 8px 10px;
        border-radius: 8px;
        border: 1px solid #e0e0e0;
        font-size: 13px;      
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        white-space: nowrap;
        background-color: #fff;
        color: #333;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;

        mat-icon {
            font-size: 18px;
            width: 18px;
            height: 18px;
        }

        &.ai-screening-btn {
            &:hover {
                background-color: #f9f9f9;
                border-color: #d0d0d0;
            }
        }

        &.export-btn {
            &:hover {
                background-color: #f9f9f9;
                border-color: #d0d0d0;
            }
        }

        &.add-btn {
            background-color: var(--action-primary-default);
            color: white;
            border-color: var(--action-primary-default);

            &:hover {
                background-color: var(--action-primary-default);
                border-color: var(--action-primary-default);
            }
        }
    }
}
.search-action-container {
    background-color: #ffffff;
    border-radius: 16px;
    padding: 20px 24px;
    margin: 0 24px 20px 24px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    display: flex;
    gap: 12px;
    align-items: center;
    border: 1px solid #e8e8e8;
    flex-wrap: nowrap; 
    overflow: hidden;
}

.search-section {
    position: relative;
    flex: 1 1 150px;      
    min-width: 120px;
}

.search-input {
    width: 100%;
    padding: 12px 16px;
    padding-right: 40px;
    border-radius: 10px;
    border: 1px solid #e0e0e0;
    font-size: 15px;
    background-color: #fafafa;
    transition: all 0.2s ease;
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-weight: 400;

    &:focus {
        outline: none;
        border-color: #d0d0d0;
        background-color: #fff;
    }

    &::placeholder {
        color: #999;
    }
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 20px;
    width: 20px;
    height: 20px;
    display: none;
}

.clear-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;

    mat-icon {
        font-size: 18px;
        width: 18px;
        height: 18px;
    }

    &:hover {
        color: #666;
    }
}

.filter-field {
    min-width: 180px;

    ::ng-deep {
        .mat-mdc-form-field-wrapper {
            padding: 0;
            margin: 0;
        }

        .mat-mdc-text-field-wrapper {
            background-color: #fafafa;
            border-radius: 10px;
            padding: 0;
        }

        .mat-mdc-form-field-flex {
            height: 46px;
            padding: 0 16px;
            align-items: center;
        }

        .mat-mdc-form-field-infix {
            padding: 0;
            border: none;
            min-height: auto;
            padding-top: 0;
            padding-bottom: 0;
        }

        .mat-mdc-select {
            font-size: 15px;
            color: #333;
            font-weight: 400;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
        }

        .mat-mdc-select-value {
            color: #333;
        }

        .mat-mdc-select-arrow {
            color: #999;
        }

        .mdc-notched-outline {
            .mdc-notched-outline__leading,
            .mdc-notched-outline__notch,
            .mdc-notched-outline__trailing {
                border-color: #e0e0e0;
                border-width: 1px;
            }
        }

        .mat-mdc-form-field:hover .mdc-notched-outline {
            .mdc-notched-outline__leading,
            .mdc-notched-outline__notch,
            .mdc-notched-outline__trailing {
                border-color: #d0d0d0;
            }
        }

        .mat-focused .mdc-notched-outline {
            .mdc-notched-outline__leading,
            .mdc-notched-outline__notch,
            .mdc-notched-outline__trailing {
                border-color: #d0d0d0 !important;
                border-width: 1px !important;
            }
        }

        .mat-mdc-form-field-subscript-wrapper {
            display: none;
        }
    }
}

// ===== GRID VIEW =====
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 20px;
    padding: 0 24px 24px 24px;
}

.applicant-card {
    background-color: #ffffff;
    border-radius: 12px;
    border: 1px solid #e8e8e8;
    padding: 24px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);

    &:hover {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        transform: translateY(-1px);
    }
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.applicant-info {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    flex: 1;
    min-width: 0;
}

.avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #dbeafe 0%, #eff6ff 100%);
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    flex-shrink: 0;
    text-transform: uppercase;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.applicant-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    padding-top: 2px;
}

.applicant-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    line-height: 1.4;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.applicant-id {
    font-size: 13px;
    color: #999;
    font-weight: 400;
}

.source-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    flex-shrink: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;

    &.badge-portal {
        background-color: #2563eb;
        color: #ffffff;
    }

    &.badge-agency {
        background-color: #2563eb;
        color: #ffffff;
    }

    &.badge-referral {
        background-color: #2563eb;
        color: #ffffff;
    }

    &.badge-default {
        background-color: #2563eb;
        color: #ffffff;
    }
}

.card-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.info-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-value {
    font-size: 15px;
    color: #1a1a1a;
    font-weight: 500;
    margin-bottom: 8px;
}

.contact-section {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0;
    font-size: 14px;
    color: #666;

    mat-icon {
        font-size: 18px;
        width: 18px;
        height: 18px;
        color: #999;
        display: none;
    }

    .contact-text {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}

.stats-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding-top: 0;
    border-top: none;
    margin-top: 8px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stat-label {
    font-size: 14px;
    color: #999;
    font-weight: 400;
}

.stat-value {
    font-size: 14px;
    color: #1a1a1a;
    font-weight: 500;
    text-align: right;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding-top: 16px;
    margin-top: 16px;
    border-top: 1px solid #f0f0f0;
}

.ai-score-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ai-label {
    font-size: 12px;
    color: #aaa;
    font-weight: 400;
}

.ai-score {
    font-size: 32px;
    font-weight: 700;
    line-height: 1;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: #2563eb;

    &.score-high {
        color: #2563eb;
    }

    &.score-medium {
        color: #2563eb;
    }

    &.score-low {
        color: #2563eb;
    }
}

.card-footer .view-btn {
    padding: 8px 24px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    background-color: #ffffff;
    color: #333;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;

    &:hover {
        background-color: #f9f9f9;
        border-color: #d0d0d0;
    }
}

// ===== LIST VIEW =====
.list-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 24px 24px 24px;
}

.applicant-row {
    background-color: #ffffff;
    border-radius: 12px;
    border: 1px solid #e8e8e8;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);

    &:hover {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
        transform: translateY(-1px);
    }
}

.row-left {
    display: flex;
    gap: 14px;
    align-items: center;
    flex: 1;
    min-width: 0;
}

.info-top {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 6px;
}

.info-middle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #666;
    margin-bottom: 6px;
}

.separator {
    color: #d0d0d0;
    font-size: 14px;
}

.position {
    font-weight: 400;
    color: #333;
}

.experience,
.ctc {
    font-weight: 400;
    color: #666;
}

.contact-info {
    display: flex;
    gap: 20px;
    align-items: center;
}

.contact-text {
    color: #666;
    font-size: 14px;
}

.row-right {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;

    .view-btn {
        padding: 8px 24px;
        border-radius: 8px;
        border: 1px solid #e0e0e0;
        background-color: #ffffff;
        color: #333;
        font-size: 14px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;

        &:hover {
            background-color: #f9f9f9;
            border-color: #d0d0d0;
        }
    }
}

// ===== TABLE VIEW =====
.table-container {
    background-color: #ffffff;
    border-radius: 12px;
    border: 1px solid #e8e8e8;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    margin: 0 24px 24px 24px;
}

.table-header {
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
    
    .table-title {
        font-size: 18px;
        font-weight: 600;
        color: #1a1a1a;
        margin: 0;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    }
}

.applicant-table {
    width: 100%;
    border-collapse: collapse;

    thead {
        background-color: #fafafa;
    }

    th {
        font-size: 11px;
        font-weight: 600;
        color: #666;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        padding: 14px 20px;
        text-align: left;
        border-bottom: 1px solid #e8e8e8;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    }

    td {
        padding: 16px 20px;
        border-bottom: 1px solid #f5f5f5;
        font-size: 14px;
        vertical-align: middle;
    }

    tbody tr {
        transition: background-color 0.2s ease;

        &:hover {
            background-color: #fafafa;
        }

        &:last-child td {
            border-bottom: none;
        }
    }
}

.id-cell {
    color: black;
    font-weight: 500;
    font-size: 13px;
}

.applicant-cell {
    display: flex;
    align-items: center;
    gap: 12px;

    .applicant-details {
        display: flex;
        flex-direction: column;
        gap: 2px;

        .applicant-name {
            font-size: 14px;
            font-weight: 600;
            color: #1a1a1a;
            margin: 0;
        }

        .applicant-email {
            font-size: 13px;
            color: #666;
        }
    }
}

.position-cell {
    color: #333;
    font-weight: 400;
}

.stat-cell {
    color: #1a1a1a;
    font-weight: 500;
}

.applicant-table .view-btn {
    padding: 6px 20px;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
    background-color: #ffffff;
    color: #333;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;

    &:hover {
        background-color: #f9f9f9;
        border-color: #d0d0d0;
    }
}

// ===== EMPTY STATE =====
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 100px 20px;
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    margin: 0 24px 24px 24px;
    border: 1px solid #e8e8e8;

    .empty-icon {
        font-size: 72px;
        width: 72px;
        height: 72px;
        color: #d0d0d0;
        margin-bottom: 20px;
    }

    h3 {
        font-size: 20px;
        font-weight: 600;
        color: #1a1a1a;
        margin: 0 0 10px 0;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    }

    p {
        font-size: 15px;
        color: #666;
        margin: 0;
    }
}

// ===== DROPDOWN PANEL STYLING =====
::ng-deep {
    .mat-mdc-select-panel {
        background-color: #ffffff;
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        border: 1px solid #e0e0e0;
        margin-top: 4px;
        padding: 8px 0;
        max-height: 300px;

        .mat-mdc-option {
            font-size: 15px;
            min-height: 48px;
            padding: 0 20px;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
            position: relative;

            .mdc-list-item__primary-text {
                color: #1a1a1a;
                font-weight: 400;
            }

            &:hover {
                background-color: #f5f5f5;
            }

            &.mat-mdc-option-active {
                background-color: transparent;
            }

            &.mdc-list-item--selected {
                background-color: transparent;

                .mdc-list-item__primary-text {
                    color: #1a1a1a;
                    font-weight: 400;
                }

                &::after {
                    content: '✓';
                    position: absolute;
                    right: 20px;
                    top: 50%;
                    transform: translateY(-50%);
                    color: #999;
                    font-size: 18px;
                    font-weight: 500;
                }

                &:hover::after {
                    color: #666;
                }
            }

            .mat-mdc-option-pseudo-checkbox {
                display: none;
            }
        }
    }
}

// ===== RESPONSIVE =====
@media (max-width: 1200px) {
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .header-right {
        width: 100%;
        flex-wrap: wrap;
        flex-shrink: 0;
    }

    .search-action-container {
        flex-wrap: nowrap;
    }

    .grid-container {
        grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    }
}

@media (max-width: 768px) {
    .search-section {
        flex: 1 1 100%;
    }

    .filter-field {
        flex: 1 1 calc(50% - 6px);
    }

    .applicant-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .row-right {
        width: 100%;
        justify-content: space-between;
    }

    .grid-container {
        grid-template-columns: 1fr;
    }

    .applicant-table {
        font-size: 13px;

        th, td {
            padding: 12px 16px;
        }
    }
}
.modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 1000;
    display: flex; align-items: center; justify-content: center;
}
.modal-container {
    background: #fff; border-radius: 16px;
    width: 90%; max-width: 900px;
    max-height: 90vh; overflow-y: auto;
    padding: 24px;
}
.modal-header {
    display: flex; justify-content: space-between; align-items: flex-start;
    margin-bottom: 20px;
    h2 { margin: 0; font-size: 22px; font-weight: 700; }
    p { margin: 4px 0 0; color: #666; }
}
.close-btn { background: none; border: none; cursor: pointer; }
.source-tabs {
    display: flex; gap: 4px; background: #f5f5f5;
    border-radius: 12px; padding: 6px; margin-bottom: 24px;
}
.tab-btn {
    flex: 1; padding: 10px; border: none; border-radius: 8px;
    background: transparent; cursor: pointer; font-size: 14px; color: #666;
    &.active { background: #fff; font-weight: 600; color: #1a1a1a; box-shadow: 0 1px 4px rgba(0,0,0,0.1); }
}
.source-panel {
    border: 1px solid #e8e8e8; border-radius: 12px; padding: 24px;
    h3 { margin: 0 0 6px; } p { color: #666; margin: 0 0 16px; }
}
.webhook-box {
    background: #f5f5f5; border-radius: 8px; padding: 14px;
    font-family: monospace; font-size: 13px; margin-bottom: 12px;
}
.helper-text { color: #666; font-size: 13px; }
.agency-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.agency-card {
    border: 1px dashed #e0e0e0; border-radius: 10px; padding: 20px;
    p { color: #666; font-size: 13px; margin: 8px 0 0; }
}
.modal-container {
    .modal-add-btn {
        display: flex;
        align-items: center;
        gap: 6px;
        padding: 10px 20px;
        background-color: #2563eb;
        color: #ffffff;
        border: none;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
        mat-icon {
            font-size: 18px;
            width: 18px;
            height: 18px;
        }
        &:hover {
            background-color: #1d4ed8;
        }
    }
}
.fullscreen-form {
  position: fixed;
  top: 60px; 
  left: 0;
  width: 100vw;
  height: 100vh;
  background: white;
  z-index: 9999;
  overflow-y: auto;
}
.applicant-form-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;        // sits above header? lower to 900 if header z-index is higher
  display: flex;
  align-items: center;
  justify-content: center;
}

.applicant-form-modal {
  background: #fff;
  border-radius: 8px;
  width: 80%;
  max-width: 1000px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);

  .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid #e0e0e0;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 1;
  }

  .modal-body {
    padding: 16px;
  }
}
// ===== DETAIL VIEW =====
.detail-container {
  padding: 0 24px 24px 24px;
}

.detail-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0 20px 0;

  .detail-topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
  }

  .back-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    padding: 6px 10px;
    border-radius: 6px;
    &:hover { background: #f0f0f0; }
  }

  .detail-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #dbeafe 0%, #eff6ff 100%);
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
  }

  .detail-title-info {
    h2 { margin: 0; font-size: 20px; font-weight: 700; color: #1a1a1a; }
    span { font-size: 13px; color: #999; }
  }

  .edit-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 14px;
    cursor: pointer;
    color: #333;
    &:hover { background: #f9f9f9; }
  }
}

.detail-body {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items: start;
}

.detail-left {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.detail-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dcard {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  padding: 20px 24px;

  .dcard-title {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 16px 0;
  }
}

.dcard-grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.dcard-grid2-plain {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}

.dcard-grid3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px 24px;
  margin-bottom: 8px;
}

.dfield {
  display: flex;
  align-items: flex-start;
  gap: 10px;

  .dfield-icon {
    font-size: 18px;
    width: 18px;
    height: 18px;
    color: #999;
    margin-top: 14px;
  }
}

.dlbl {
  display: block;
  font-size: 12px;
  color: #999;
  margin-bottom: 2px;
}

.dval {
  display: block;
  font-size: 14px;
  color: #1a1a1a;
  font-weight: 500;
}

.dsection-title {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 16px 0;
}

.dsub-title {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 12px 0;
}

.ddivider {
  border: none;
  border-top: 1px solid #f0f0f0;
  margin: 16px 0;
}

.ddoc-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  margin-bottom: 10px;
  font-size: 14px;
  color: #333;

  mat-icon { color: #999; font-size: 20px; }

  span { flex: 1; }

  .ddoc-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 13px;
    cursor: pointer;
    color: #333;
    mat-icon { font-size: 16px; width: 16px; height: 16px; }
    &:hover { background: #f9f9f9; }
  }
}

.dempty {
  font-size: 14px;
  color: #999;
  margin: 8px 0 0 0;
}

.detail-tabs {
  display: flex;
  background: #f5f5f5;
  border-radius: 8px;
  padding: 4px;
  gap: 2px;

  button {
    flex: 1;
    padding: 8px 12px;
    border: none;
    background: transparent;
    border-radius: 6px;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;

    &.active {
      background: #fff;
      color: #1a1a1a;
      font-weight: 600;
      box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    }
    &:hover:not(.active) { background: #ebebeb; }
  }
}

.daction-primary {
  width: 100%;
  padding: 12px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  margin-bottom: 10px;
  &:hover { background: #1d4ed8; }
}

.daction-secondary {
  width: 100%;
  padding: 12px;
  background: #fff;
  color: #1a1a1a;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  margin-bottom: 10px;
  &:hover { background: #f9f9f9; }
}

.dai-score {
  font-size: 48px;
  font-weight: 700;
  color: #2563eb;
  text-align: center;
  padding: 16px 0 4px 0;
}

.dai-label {
  font-size: 13px;
  color: #999;
  text-align: center;
  margin-bottom: 8px;
}
.dskills-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.dskill-tag {
  padding: 4px 12px;
  background: #eff6ff;
  color: #2563eb;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
}
// ===== BULK UPLOAD OVERLAY =====
.bulk-upload-overlay {
  position: absolute;
  top: 0;  // change from 60px to 0
  left: 0;
  width: 100%;
  min-height: 100%;
  background: #f8f9fa;
  z-index: 500;
  overflow-y: auto;
}

.bulk-topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px 16px 24px;
  background: #fff;
  border-bottom: 1px solid #e8e8e8;

  .bulk-title-block {
    h2 { margin: 0; font-size: 22px; font-weight: 700; color: #1a1a1a; }
    p  { margin: 2px 0 0; font-size: 13px; color: #666; }
  }
}

.bulk-step-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 2px solid #e8e8e8;
  background: #fff;
}

.bulk-step-tab {
  padding: 14px;
  border: none;
  background: transparent;
  font-size: 14px;
  color: #666;
  cursor: pointer;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all 0.2s;

  &.active {
    color: #2563eb;
    border-bottom-color: #2563eb;
    font-weight: 600;
  }

  &:hover:not(.active) { background: #f5f5f5; }
}

.bulk-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bulk-section {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  padding: 20px 24px;
}

.bulk-section-title {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0 0 16px 0;
}

.bulk-dropzone {
  border: 2px dashed #d0d0d0;
  border-radius: 10px;
  padding: 48px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: border-color 0.2s;

  &:hover { border-color: #2563eb; }

  .bulk-drop-icon {
    font-size: 40px;
    width: 40px;
    height: 40px;
    color: #999;
    margin-bottom: 8px;
  }

  .bulk-drop-main { font-size: 15px; font-weight: 600; color: #1a1a1a; margin: 0; }
  .bulk-drop-sub  { font-size: 13px; color: #999; margin: 0; }
}

.bulk-browse-btn {
  margin-top: 8px;
  padding: 10px 28px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  &:hover { background: #1d4ed8; }
}

.bulk-source-section { }

.bulk-source-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
}

.bulk-field {
  display: flex;
  flex-direction: column;
  gap: 6px;

  label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
  }
}

.bulk-select,
.bulk-input {
  padding: 10px 12px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 14px;
  color: #333;
  background: #fafafa;
  outline: none;

  &:focus { border-color: #2563eb; background: #fff; }
}

.bulk-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.bulk-start-btn {
  padding: 14px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  &:hover { background: #1d4ed8; }
}

.bulk-cancel-btn {
  padding: 14px;
  background: #fff;
  color: #333;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  &:hover { background: #f5f5f5; }
}

.bulk-features-box {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 10px;
  padding: 16px 20px;

  .bulk-features-title {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 700;
    color: #d97706;
    margin: 0 0 10px 0;
  }

  ul {
    margin: 0;
    padding-left: 20px;
    li {
      font-size: 13px;
      color: #92400e;
      margin-bottom: 4px;
    }
  }
}
.custom-select-wrapper {
  position: relative;
  min-width: 110px;       // CHANGE from 160px
  flex-shrink: 1; 

  &::after {
    content: '▾';
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    pointer-events: none;
    font-size: 14px;
  }
}

.custom-select {
  width: 100%;
   padding: 10px 24px 10px 10px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 13px; 
  font-weight: 500;
  color: #333;
  background: #fff;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  outline: none;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  &:hover { border-color: #d0d0d0; background: #fafafa; }
  &:focus { border-color: #2563eb; }
}