﻿/* CRM System CSS */
:root {
    --primary: #4F46E5;
    --primary-dark: #4338CA;
    --secondary: #6B7280;
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --info: #3B82F6;
    --bg-main: #F9FAFB;
    --bg-white: #FFFFFF;
    --text-primary: #111827;
    --text-secondary: #6B7280;
    --border: #E5E7EB;
    --shadow: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.1);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif; background: var(--bg-main); color: var(--text-primary); line-height: 1.6; min-height: 100vh; display: flex; flex-direction: column; }
.navbar { background: var(--bg-white); border-bottom: 2px solid var(--border); box-shadow: var(--shadow); position: sticky; top: 0; z-index: 1000; }
.navbar .container { max-width: 1400px; margin: 0 auto; padding: 0 2rem; display: flex; justify-content: space-between; align-items: center; min-height: 70px; }
.nav-brand h1 { font-size: 1.5rem; font-weight: 700; color: var(--primary); }
.nav-menu { display: flex; list-style: none; gap: 0.5rem; }
.nav-menu a { padding: 0.625rem 1.25rem; color: var(--text-secondary); text-decoration: none; font-weight: 500; border-radius: 0.5rem; transition: all 0.2s; }
.nav-menu a:hover { background: #F3F4F6; color: var(--primary); }
.main-content { flex: 1; padding: 2.5rem 0; }
.container { max-width: 1400px; margin: 0 auto; padding: 0 2rem; }
.page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; }
.page-header h2 { font-size: 1.875rem; font-weight: 700; }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.625rem 1.25rem; font-size: 0.9375rem; font-weight: 600; text-decoration: none; border: none; border-radius: 0.5rem; cursor: pointer; transition: all 0.2s; }
.btn-primary { background: var(--primary); color: white; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.btn-secondary { background: white; color: var(--text-primary); border: 1px solid var(--border); }
.btn-secondary:hover { background: #F9FAFB; }
.btn-icon { background: transparent; border: none; font-size: 1.25rem; cursor: pointer; color: var(--text-secondary); transition: all 0.2s; }
.btn-icon:hover { color: var(--primary); transform: scale(1.1); }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; margin-bottom: 2.5rem; }
.stat-card { background: white; padding: 1.5rem; border-radius: 0.75rem; border: 1px solid var(--border); box-shadow: var(--shadow); display: flex; align-items: center; gap: 1rem; transition: all 0.3s; }
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.stat-icon { font-size: 2.5rem; }
.stat-info { flex: 1; }
.stat-info h3 { font-size: 2rem; font-weight: 700; line-height: 1; margin-bottom: 0.375rem; }
.stat-info p { font-size: 0.875rem; color: var(--text-secondary); }
.stat-card:nth-child(1) { border-left: 4px solid var(--primary); }
.stat-card:nth-child(2) { border-left: 4px solid var(--warning); }
.stat-card:nth-child(3) { border-left: 4px solid var(--info); }
.stat-card:nth-child(4) { border-left: 4px solid #8B5CF6; }
.stat-card:nth-child(5) { border-left: 4px solid var(--success); }
.dashboard-actions { display: flex; gap: 1rem; margin-bottom: 2.5rem; flex-wrap: wrap; }
.recent-section { background: white; padding: 1.5rem; border-radius: 0.75rem; border: 1px solid var(--border); box-shadow: var(--shadow); margin-bottom: 1.5rem; }
.recent-section h3 { font-size: 1.125rem; font-weight: 600; margin-bottom: 1rem; padding-bottom: 0.75rem; border-bottom: 1px solid var(--border); }
.appointment-item, .callback-item { padding: 1rem 0; border-bottom: 1px solid var(--border); display: flex; gap: 1rem; }
.appointment-item:last-child, .callback-item:last-child { border-bottom: none; padding-bottom: 0; }
.appointment-date, .callback-date { font-size: 0.875rem; color: #9CA3AF; font-weight: 500; min-width: 160px; }
.appointment-customer, .callback-customer { flex: 1; }
.appointment-customer strong, .callback-customer strong { font-weight: 600; }
.no-data { text-align: center; padding: 2rem; color: #9CA3AF; font-style: italic; }
.search-filter { display: flex; gap: 1rem; margin-bottom: 1.5rem; flex-wrap: wrap; }
.search-box, .filter-box { display: flex; gap: 0.75rem; align-items: center; }
.filter-box label { font-weight: 600; font-size: 0.875rem; }
.table-responsive { background: white; border-radius: 0.75rem; border: 1px solid var(--border); box-shadow: var(--shadow); overflow: hidden; }
.customers-table { width: 100%; border-collapse: collapse; }
.customers-table thead { background: linear-gradient(to bottom, #F9FAFB, #F3F4F6); }
.customers-table th { padding: 1rem 1.25rem; text-align: left; font-weight: 600; font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.05em; border-bottom: 2px solid #D1D5DB; }
.customers-table td { padding: 1rem 1.25rem; border-bottom: 1px solid var(--border); font-size: 0.9375rem; }
.customers-table tbody tr:hover { background: #F9FAFB; }
.customers-table tbody tr:last-child td { border-bottom: none; }
.customers-table td.loading, .customers-table td.no-data { text-align: center; padding: 3rem; color: #9CA3AF; font-style: italic; }
.customers-table td.actions { display: flex; gap: 0.5rem; }
.status-badge { display: inline-flex; padding: 0.375rem 0.75rem; font-size: 0.8125rem; font-weight: 600; border-radius: 999px; }
.status-offen { background: #FEF3C7; color: #92400E; }
.status-auftrag_erteilt { background: #DBEAFE; color: #1E40AF; }
.status-in_bearbeitung { background: #E9D5FF; color: #6B21A8; }
.status-erledigt { background: #D1FAE5; color: #065F46; }
.customer-form { background: white; border-radius: 0.75rem; border: 1px solid var(--border); box-shadow: var(--shadow); padding: 2rem; }
.form-section { margin-bottom: 2rem; padding-bottom: 2rem; border-bottom: 1px solid var(--border); }
.form-section:last-of-type { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.form-section h3 { font-size: 1.125rem; font-weight: 600; margin-bottom: 1.5rem; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.form-group { display: flex; flex-direction: column; }
.form-group-2 { grid-column: span 2; }
.form-group label { font-weight: 600; margin-bottom: 0.5rem; font-size: 0.875rem; }
.required { color: var(--danger); margin-left: 0.25rem; }
.form-input, .form-select, .form-textarea { padding: 0.75rem; border: 1px solid #D1D5DB; border-radius: 0.5rem; font-size: 0.9375rem; background: white; transition: all 0.2s; font-family: inherit; }
.form-input:focus, .form-select:focus, .form-textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1); }
.form-textarea { resize: vertical; min-height: 100px; }
.form-actions { display: flex; gap: 1rem; margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--border); flex-wrap: wrap; }
.message-box { padding: 1rem 1.25rem; border-radius: 0.5rem; margin-bottom: 1.5rem; font-weight: 500; border-left: 4px solid; }
.message-success { background: #D1FAE5; color: #065F46; border-color: var(--success); }
.message-error { background: #FEE2E2; color: #991B1B; border-color: var(--danger); }
.footer { background: white; border-top: 1px solid var(--border); padding: 2rem 0; margin-top: auto; text-align: center; color: var(--text-secondary); font-size: 0.875rem; }
#loadingMessage { text-align: center; padding: 3rem; color: #9CA3AF; }
@media (max-width: 1024px) { .form-group-2 { grid-column: span 1; } }
@media (max-width: 768px) { .navbar .container { flex-direction: column; padding: 1rem; gap: 1rem; } .nav-menu { flex-direction: column; width: 100%; gap: 0.25rem; } .nav-menu a { text-align: center; } .page-header { flex-direction: column; align-items: flex-start; gap: 1rem; } .stats-grid { grid-template-columns: 1fr; } .search-filter { flex-direction: column; } .form-grid { grid-template-columns: 1fr; } .dashboard-actions { flex-direction: column; } .dashboard-actions .btn { width: 100%; } .customers-table { font-size: 0.8125rem; } .customers-table th, .customers-table td { padding: 0.75rem 0.5rem; } }
@media (max-width: 480px) { .container { padding: 0 1rem; } .main-content { padding: 1.5rem 0; } .customer-form { padding: 1.25rem; } .stat-card { padding: 1.25rem; } .stat-icon { font-size: 2rem; } .stat-info h3 { font-size: 1.5rem; } }
