/* ========== KUNDEN 2.0 STYLES ========== */

/* Stats Grid */
.k2-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.k2-stat-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    border: 1px solid #f0f0f0;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.k2-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.k2-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.k2-stat-info {
    min-width: 0;
}

.k2-stat-number {
    font-size: 22px;
    font-weight: 700;
    color: var(--color-gray-800);
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.k2-stat-label {
    font-size: 12px;
    color: var(--color-gray-500);
    margin-top: 2px;
    font-weight: 500;
}

/* Toolbar */
.k2-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.k2-search-wrapper {
    position: relative;
    flex: 1;
    min-width: 200px;
    max-width: 400px;
}

.k2-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    opacity: 0.4;
}

.k2-search {
    width: 100%;
    padding: 10px 36px 10px 38px;
    border: 2px solid #e8e8e8;
    border-radius: 10px;
    font-size: 14px;
    background: white;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.k2-search:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.12);
}

.k2-search-clear {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    cursor: pointer;
    color: var(--color-gray-400);
    line-height: 1;
    padding: 2px 4px;
}

.k2-search-clear:hover {
    color: var(--color-danger);
}

.k2-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.k2-filter-select {
    padding: 10px 14px;
    border: 2px solid #e8e8e8;
    border-radius: 10px;
    font-size: 13px;
    background: white;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}

.k2-filter-select:focus {
    border-color: var(--color-primary);
}

/* Buttons */
.k2-btn {
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.k2-btn-primary {
    background: var(--color-primary);
    color: white;
}

.k2-btn-primary:hover {
    background: var(--color-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

.k2-btn-outline {
    background: transparent;
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.k2-btn-outline:hover {
    background: var(--color-primary-light);
}

/* Content Layout */
.k2-content {
    display: flex;
    gap: 0;
    align-items: flex-start;
    transition: gap 0.3s ease;
}

.k2-content.k2-detail-open {
    gap: 20px;
}

/* Table */
.k2-table-wrapper {
    flex: 1;
    min-width: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    border: 1px solid #f0f0f0;
    overflow: hidden;
}

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

.k2-table thead {
    background: #fafbfc;
    border-bottom: 2px solid #eef0f2;
}

.k2-table th {
    padding: 12px 16px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--color-gray-500);
    text-align: left;
    user-select: none;
    white-space: nowrap;
}

.k2-th-sortable {
    cursor: pointer;
    transition: color 0.15s;
}

.k2-th-sortable:hover {
    color: var(--color-primary);
}

.k2-th-right { text-align: right !important; }
.k2-th-center { text-align: center !important; }

.k2-sort-icon {
    font-size: 10px;
    opacity: 0.3;
    margin-left: 4px;
}

.k2-sort-active {
    opacity: 1;
    color: var(--color-primary);
}

.k2-table tbody tr {
    border-bottom: 1px solid #f5f5f5;
    transition: background 0.1s;
    cursor: pointer;
}

.k2-table tbody tr:hover {
    background: #f8fafc;
}

.k2-table tbody tr:last-child {
    border-bottom: none;
}

.k2-row-selected {
    background: var(--color-primary-light) !important;
    border-left: 3px solid var(--color-primary);
}

.k2-table td {
    padding: 14px 16px;
    font-size: 13px;
    color: var(--color-gray-700);
    vertical-align: middle;
}

.k2-td-right { text-align: right; }
.k2-td-center { text-align: center; }

.k2-cell-name {
    display: flex;
    align-items: center;
    gap: 12px;
}

.k2-row-logo {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: contain;
    border: 1px solid #eee;
    flex-shrink: 0;
}

.k2-row-avatar {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 15px;
    flex-shrink: 0;
}

.k2-name {
    font-weight: 600;
    color: var(--color-gray-800);
    font-size: 14px;
}

.k2-sub {
    font-size: 12px;
    color: var(--color-gray-500);
    margin-top: 2px;
}

.k2-contact-cell {
    max-width: 200px;
}

.k2-active-badge {
    color: var(--color-success) !important;
    font-weight: 600;
}

.k2-order-count {
    font-weight: 700;
    font-size: 16px;
    color: var(--color-gray-800);
}

.k2-revenue {
    font-weight: 600;
    color: var(--color-gray-700);
}

/* Badges */
.k2-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2px;
}

.k2-badge-purple {
    background: #f3e8ff;
    color: #7c3aed;
}

.k2-badge-gray {
    background: #f3f4f6;
    color: #6b7280;
}

/* Action Buttons in Rows */
.k2-actions {
    display: flex;
    gap: 6px;
    justify-content: center;
}

.k2-action-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    background: #f3f4f6;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.k2-action-btn:hover {
    background: var(--color-primary-light);
    color: var(--color-primary);
}

.k2-action-danger:hover {
    background: var(--color-danger-light) !important;
    color: var(--color-danger) !important;
}

.k2-table-footer {
    padding: 10px 16px;
    font-size: 12px;
    color: var(--color-gray-500);
    border-top: 1px solid #f0f0f0;
    background: #fafbfc;
}

.k2-empty {
    text-align: center;
    padding: 40px 20px !important;
    color: var(--color-gray-400);
    font-size: 14px;
}

/* ===== DETAIL PANEL ===== */
.k2-detail-panel {
    width: 420px;
    flex-shrink: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid #f0f0f0;
    overflow: hidden;
    max-height: calc(100vh - 160px);
    overflow-y: auto;
    position: sticky;
    top: 100px;
    animation: k2SlideIn 0.25s ease;
}

@keyframes k2SlideIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

.k2-detail-header {
    background: linear-gradient(135deg, var(--color-secondary), var(--color-secondary-dark));
    color: white;
    padding: 20px;
}

.k2-detail-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.k2-detail-title-row > div {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.k2-detail-logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: contain;
    background: white;
    padding: 3px;
}

.k2-detail-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
}

.k2-close-btn {
    background: rgba(255,255,255,0.15);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
    flex-shrink: 0;
}

.k2-close-btn:hover {
    background: rgba(255,255,255,0.25);
}

.k2-detail-body {
    padding: 20px;
}

.k2-detail-section {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f0f0f0;
}

.k2-detail-section:last-of-type {
    border-bottom: none;
}

.k2-section-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--color-gray-700);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.k2-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.k2-detail-field {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.k2-field-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: var(--color-gray-400);
}

.k2-field-value {
    font-size: 13px;
    color: var(--color-gray-700);
    word-break: break-word;
}

.k2-field-value a {
    color: var(--color-primary);
    text-decoration: none;
}

.k2-field-value a:hover {
    text-decoration: underline;
}

/* Rates */
.k2-rates-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.k2-rate-chip {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.k2-rate-qual {
    font-size: 11px;
    font-weight: 600;
    color: var(--color-gray-500);
}

.k2-rate-value {
    font-size: 14px;
    font-weight: 700;
    color: #16a34a;
}

/* Tags */
.k2-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.k2-tag {
    background: #eff6ff;
    color: #2563eb;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

/* Contacts in detail */
.k2-detail-contact {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 0;
    border-bottom: 1px solid #f8f8f8;
    flex-wrap: wrap;
}

.k2-detail-contact:last-child {
    border-bottom: none;
}

.k2-contact-role {
    background: #e0e7ff;
    color: #4338ca;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.k2-contact-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-gray-700);
}

.k2-contact-email {
    font-size: 12px;
    color: var(--color-gray-500);
}

/* Mini Stats */
.k2-mini-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.k2-mini-stat {
    background: #fafbfc;
    border-radius: 10px;
    padding: 12px;
    text-align: center;
    border: 1px solid #f0f0f0;
}

.k2-mini-stat-num {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-gray-800);
}

.k2-mini-stat-label {
    font-size: 11px;
    color: var(--color-gray-500);
    margin-top: 2px;
}

/* Order List in Detail */
.k2-order-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.k2-order-item {
    background: #fafbfc;
    border-radius: 8px;
    padding: 10px 12px;
    border: 1px solid #f0f0f0;
    transition: background 0.1s;
}

.k2-order-item:hover {
    background: #f0f4ff;
}

.k2-order-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.k2-order-nr {
    font-weight: 700;
    font-size: 13px;
    color: var(--color-gray-800);
}

.k2-order-status {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Status Colors */
.k2-status-anfrage { background: #fef3c7; color: #92400e; }
.k2-status-offen { background: #e0e7ff; color: #3730a3; }
.k2-status-zugewiesen { background: #dbeafe; color: #1e40af; }
.k2-status-warte_bestaetigung { background: #fde68a; color: #78350f; }
.k2-status-bestaetigt { background: #d1fae5; color: #065f46; }
.k2-status-auev_unterschrift { background: #ede9fe; color: #5b21b6; }
.k2-status-aktiv { background: #dcfce7; color: #166534; }
.k2-status-abgeschlossen { background: #f0fdf4; color: #14532d; }
.k2-status-storniert { background: #fee2e2; color: #991b1b; }
.k2-status-abgelehnt { background: #fecaca; color: #7f1d1d; }

.k2-order-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--color-gray-500);
}

.k2-order-emp {
    font-size: 12px;
    color: var(--color-gray-600);
    margin-top: 2px;
}

/* Invoice List in Detail */
.k2-invoice-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.k2-invoice-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: #fafbfc;
    border-radius: 8px;
    border: 1px solid #f0f0f0;
    gap: 10px;
}

.k2-invoice-nr {
    font-weight: 600;
    font-size: 13px;
    color: var(--color-gray-700);
}

.k2-invoice-amount {
    font-weight: 700;
    font-size: 13px;
    color: var(--color-gray-800);
    flex-shrink: 0;
}

.k2-invoice-status {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 20px;
    flex-shrink: 0;
}

.k2-invstatus-entwurf { background: #f3f4f6; color: #6b7280; }
.k2-invstatus-offen { background: #dbeafe; color: #1e40af; }
.k2-invstatus-versendet { background: #e0e7ff; color: #4338ca; }
.k2-invstatus-bezahlt { background: #dcfce7; color: #166534; }
.k2-invstatus-ueberfaellig { background: #fee2e2; color: #991b1b; }
.k2-invstatus-storniert { background: #fecaca; color: #7f1d1d; }

.k2-more {
    text-align: center;
    padding: 8px;
    font-size: 12px;
    color: var(--color-gray-400);
}

.k2-empty-detail {
    text-align: center;
    padding: 16px;
    color: var(--color-gray-400);
    font-size: 13px;
    background: #fafbfc;
    border-radius: 8px;
}

.k2-detail-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.k2-detail-actions .k2-btn {
    flex: 1;
    text-align: center;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .k2-detail-panel {
        width: 360px;
    }
}

@media (max-width: 960px) {
    .k2-content {
        flex-direction: column;
    }

    .k2-detail-panel {
        width: 100%;
        position: static;
        max-height: none;
    }

    .k2-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .k2-stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .k2-stat-card {
        padding: 14px;
    }

    .k2-stat-number {
        font-size: 18px;
    }

    .k2-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .k2-search-wrapper {
        max-width: none;
    }

    .k2-toolbar-actions {
        margin-left: 0;
    }

    .k2-table th:nth-child(3),
    .k2-table td:nth-child(3),
    .k2-table th:nth-child(6),
    .k2-table td:nth-child(6) {
        display: none;
    }

    .k2-detail-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .k2-stats-grid {
        grid-template-columns: 1fr;
    }

    .k2-table th:nth-child(4),
    .k2-table td:nth-child(4) {
        display: none;
    }
}

/* Scrollbar fuer Detail Panel */
.k2-detail-panel::-webkit-scrollbar {
    width: 6px;
}

.k2-detail-panel::-webkit-scrollbar-track {
    background: transparent;
}

.k2-detail-panel::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

.k2-detail-panel::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}


/* ==============================================================
   CUSTOMER MODAL 2.0 (cm2-)
   ============================================================== */

.cm2-modal {
    max-width: 960px !important;
    max-height: 92vh !important;
    overflow: hidden !important;
    border-radius: 16px !important;
    padding: 0 !important;
    display: flex;
    flex-direction: column;
    animation: cm2FadeIn 0.2s ease;
}

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

/* Header */
.cm2-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px;
    background: linear-gradient(135deg, #1e293b, #0f172a);
    color: white;
    flex-shrink: 0;
}

.cm2-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.cm2-header-icon {
    font-size: 28px;
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cm2-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    color: white;
}

.cm2-subtitle {
    font-size: 12px;
    opacity: 0.6;
    margin-top: 2px;
}

.cm2-close {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    font-size: 22px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.cm2-close:hover {
    background: rgba(255,255,255,0.2);
}

/* Tabs */
.cm2-tabs {
    display: flex;
    gap: 0;
    background: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
    padding: 0 20px;
    overflow-x: auto;
    flex-shrink: 0;
}

.cm2-tab {
    padding: 12px 18px;
    border: none;
    background: none;
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.15s;
    white-space: nowrap;
}

.cm2-tab:hover {
    color: #334155;
    background: #f1f5f9;
}

.cm2-tab.active {
    color: var(--color-primary);
    border-bottom-color: var(--color-primary);
    background: white;
}

/* Body */
.cm2-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px;
}

.cm2-tab-pane {
    display: none;
}

.cm2-tab-pane.active {
    display: block;
    animation: cm2PaneFade 0.2s ease;
}

@keyframes cm2PaneFade {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Section labels */
.cm2-section-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #94a3b8;
    margin-bottom: 14px;
}

.cm2-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.cm2-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 20px 0;
}

/* Grids */
.cm2-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.cm2-grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

/* Fields */
.cm2-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.cm2-label {
    font-size: 12px;
    font-weight: 600;
    color: #475569;
}

.cm2-req {
    color: #ef4444;
}

.cm2-hint {
    font-size: 12px;
    color: #94a3b8;
}

.cm2-input {
    padding: 10px 14px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 14px;
    color: #1e293b;
    background: white;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
    width: 100%;
}

.cm2-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.cm2-input::placeholder {
    color: #cbd5e1;
}

.cm2-select {
    padding: 10px 14px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 14px;
    color: #1e293b;
    background: white;
    cursor: pointer;
    outline: none;
    width: 100%;
    transition: border-color 0.15s;
}

.cm2-select:focus {
    border-color: var(--color-primary);
}

.cm2-checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.cm2-checkbox {
    width: 18px;
    height: 18px;
    accent-color: var(--color-primary);
}

/* Input with suffix */
.cm2-input-suffix {
    position: relative;
    display: flex;
    align-items: center;
}

.cm2-input-suffix .cm2-input {
    padding-right: 50px;
}

.cm2-suffix {
    position: absolute;
    right: 14px;
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    pointer-events: none;
}

/* Upload Cards */
.cm2-upload-card {
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    transition: border-color 0.2s, background 0.2s;
}

.cm2-upload-card:hover {
    border-color: var(--color-primary);
    background: #f8fafc;
}

.cm2-upload-icon {
    font-size: 32px;
    margin-bottom: 10px;
}

.cm2-upload-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}

.cm2-upload-desc {
    font-size: 12px;
    color: #94a3b8;
    margin-bottom: 14px;
}

.cm2-file-input {
    display: none;
}

.cm2-upload-btn {
    display: inline-block;
    padding: 8px 20px;
    background: #f1f5f9;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.15s;
}

.cm2-upload-btn:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.cm2-upload-preview {
    margin-top: 12px;
    min-height: 40px;
}

.cm2-upload-preview img {
    max-width: 200px;
    max-height: 120px;
    border-radius: 8px;
    border: 2px solid #e2e8f0;
}

/* List area */
.cm2-list-area {
    min-height: 60px;
}

.cm2-btn-add {
    padding: 8px 16px;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

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

/* Pill Tabs (for Qualifications) */
.cm2-pill-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 20px;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 10px;
    width: fit-content;
}

.cm2-pill {
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.15s;
}

.cm2-pill.active {
    background: white;
    color: var(--color-primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.cm2-pill:hover:not(.active) {
    color: #334155;
}

/* Shift Cards */
.cm2-shift-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
}

.cm2-shift-label {
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 10px;
}

.cm2-time-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cm2-time-sep {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
}

.cm2-time {
    text-align: center;
}

/* Price Cards */
.cm2-price-card {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    padding: 14px;
}

.cm2-price-qual {
    font-size: 12px;
    font-weight: 700;
    color: #16a34a;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Callout */
.cm2-callout {
    display: flex;
    gap: 14px;
    padding: 16px;
    border-radius: 10px;
    align-items: flex-start;
}

.cm2-callout-warning {
    background: #fffbeb;
    border: 1px solid #fde68a;
}

.cm2-callout-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.cm2-callout-title {
    font-size: 14px;
    font-weight: 700;
    color: #92400e;
}

/* Surcharge Grid */
.cm2-surcharge-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.cm2-surcharge-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cm2-surcharge-head {
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Footer */
.cm2-footer {
    display: flex;
    gap: 10px;
    padding: 16px 28px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    justify-content: flex-end;
    flex-shrink: 0;
}

.cm2-btn-save {
    padding: 12px 32px;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s;
}

.cm2-btn-save:hover {
    background: var(--color-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.cm2-btn-cancel {
    padding: 12px 24px;
    background: white;
    color: #64748b;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.cm2-btn-cancel:hover {
    background: #f1f5f9;
    color: #334155;
}

/* Modal Responsive */
@media (max-width: 768px) {
    .cm2-modal {
        max-width: 100% !important;
        max-height: 100vh !important;
        border-radius: 0 !important;
    }

    .cm2-tabs {
        padding: 0 12px;
    }

    .cm2-tab {
        padding: 10px 12px;
        font-size: 12px;
    }

    .cm2-body {
        padding: 16px;
    }

    .cm2-grid-2, .cm2-grid-3 {
        grid-template-columns: 1fr;
    }

    .cm2-surcharge-grid {
        grid-template-columns: 1fr;
    }

    .cm2-pill-tabs {
        flex-wrap: wrap;
    }

    .cm2-header {
        padding: 16px;
    }

    .cm2-footer {
        padding: 12px 16px;
    }
}

/* Scrollbar for modal body */
.cm2-body::-webkit-scrollbar {
    width: 6px;
}

.cm2-body::-webkit-scrollbar-track {
    background: transparent;
}

.cm2-body::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

.cm2-body::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}
