/* DATA-SERVER - assets/style.css */

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #64748b;
    --secondary-hover: #475569;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-color: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --border-radius: 0.75rem;
    --border-radius-sm: 0.5rem;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: linear-gradient(135deg, var(--bg-color) 0%, #e2e8f0 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 3rem;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

header p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

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

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

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

.btn-secondary:hover {
    background: var(--secondary-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Slider */
.slider-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

.slider {
    display: flex;
    transition: transform 0.3s ease;
}

.slide {
    min-width: 100%;
    display: flex;
    justify-content: center;
    padding: 1rem;
}

.form-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow);
    max-width: 400px;
    width: 100%;
}

.form-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--border-radius-sm);
    margin-bottom: 1rem;
}

.form-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.form-card p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

/* Slider Navigation */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow);
}

.slider-nav:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.slider-nav.prev {
    left: 1rem;
}

.slider-nav.next {
    right: 1rem;
}

/* Wizard */
.wizard-progress {
    background: var(--border-color);
    height: 8px;
    border-radius: 4px;
    margin-bottom: 2rem;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--success-color));
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

#wizard-content {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    min-height: 300px;
}

.wizard-step {
    display: none;
}

.wizard-step.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.wizard-step h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.wizard-step p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* Form Elements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 500;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group .radio-group,
.form-group .checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group .radio-option,
.form-group .checkbox-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: background 0.2s ease;
}

.form-group .radio-option:hover,
.form-group .checkbox-option:hover {
    background: var(--bg-color);
}

.form-group input[type="radio"],
.form-group input[type="checkbox"] {
    width: auto;
    margin: 0;
}

/* Wizard Controls */
.wizard-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

/* Summary */
.summary-section {
    background: var(--bg-color);
    border-radius: var(--border-radius-sm);
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.summary-section h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.summary-section p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.summary-value {
    font-weight: 500;
    color: var(--text-color);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    text-align: center;
    box-shadow: var(--shadow-lg);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.modal-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--success-color);
    margin-bottom: 1rem;
}

.modal-content p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* QR Code */
#qrcode {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0;
}

#qrcode canvas {
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
}

.qr-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1rem;
}

/* Loading */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--border-color);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

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

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .slider-nav {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .wizard-controls {
        flex-direction: column;
    }
    
    .qr-actions {
        flex-direction: column;
    }
    
    .modal-content {
        padding: 1.5rem;
    }
}

/* Utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.hidden { display: none; }
.visible { display: block; }

/* FÜGE zu assets/style.css hinzu - Visuelles Feedback OHNE Validierungsfehler: */

/* Subtile visuelle Rückmeldung für ausgefüllte Felder */
.wizard-step.field-filled .form-group input,
.wizard-step.field-filled .form-group textarea,
.wizard-step.field-filled .form-group select {
    border-color: var(--success-color);
    box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.1);
}

.wizard-step.field-filled .radio-option:has(input:checked),
.wizard-step.field-filled .checkbox-option:has(input:checked) {
    border-color: var(--success-color);
    background: rgba(16, 185, 129, 0.05);
}

/* Kein rotes Styling für leere Felder - nur neutral */
.wizard-step.field-empty .form-group input,
.wizard-step.field-empty .form-group textarea,
.wizard-step.field-empty .form-group select {
    border-color: var(--border-color);
}

/* Smooth Transition für bessere UX */
.form-group input,
.form-group textarea,
.form-group select,
.radio-option,
.checkbox-option {
    transition: all 0.3s ease;
}

/* Fokus-Style für bessere Accessibility */
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    outline: none;
}

/* Sanftes Highlight bei Hover für Checkboxes/Radios */
.radio-option:hover,
.checkbox-option:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Progress-Animation für bessere UX */
.progress-bar {
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Smooth Fade für Wizard-Steps */
.wizard-step {
    animation: stepFadeIn 0.4s ease-out;
}

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

/* Button-States für bessere UX */
.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Loading-State für Submit */
.btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    transform: none !important;
}

.btn .loading {
    margin-right: 0.5rem;
}

/* Required Field Indicator (subtil) */
.wizard-step h3::after {
    content: "";
    /* Kein * mehr - wird nur in der Validierung erwähnt */
}

/* FÜGE zu assets/style.css hinzu - Multi-Field Layout Styles: */

/* Multi-Field Container */
.fields-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 1.5rem;
}

/* Responsive Grid für größere Screens */
@media (min-width: 768px) {
    .fields-container {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 2rem;
    }
    
    /* Spezielle Layouts für bestimmte Feldtypen */
    .fields-container .form-group:has(textarea) {
        grid-column: 1 / -1; /* Textarea nimmt volle Breite */
    }
    
    .fields-container .form-group:has(fieldset) {
        grid-column: 1 / -1; /* Radio/Checkbox Gruppen volle Breite */
    }
}

/* Form Group Enhancements */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
    line-height: 1.4;
}

.form-group label .required-mark {
    color: var(--danger-color);
    font-weight: bold;
    margin-left: 0.25rem;
}

/* Enhanced Input Styles */
.form-group input,
.form-group textarea,
.form-group select {
    padding: 0.875rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    transition: all 0.2s ease;
    background: white;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    transform: translateY(-1px);
}

.form-group input:invalid:not(:focus),
.form-group textarea:invalid:not(:focus),
.form-group select:invalid:not(:focus) {
    border-color: var(--danger-color);
    box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.1);
}

.form-group input:valid:not(:focus),
.form-group textarea:valid:not(:focus),
.form-group select:valid:not(:focus) {
    border-color: var(--success-color);
}

/* Textarea specific */
.form-group textarea {
    resize: vertical;
    min-height: 100px;
    line-height: 1.5;
}

/* Select specific */
.form-group select {
    cursor: pointer;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1rem;
    padding-right: 2.5rem;
}

/* Fieldset Enhancements */
fieldset {
    border: none;
    padding: 0;
    margin: 0;
    min-width: 0;
}

fieldset legend {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    padding: 0;
    line-height: 1.4;
}

fieldset legend .required-mark {
    color: var(--danger-color);
    font-weight: bold;
    margin-left: 0.25rem;
}

/* Radio and Checkbox Groups */
.radio-group,
.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.75rem;
    margin-top: 0.5rem;
}

@media (max-width: 768px) {
    .radio-group,
    .checkbox-group {
        grid-template-columns: 1fr;
    }
}

/* Radio and Checkbox Options */
.radio-option,
.checkbox-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    position: relative;
    min-height: 3.5rem;
}

.radio-option:hover,
.checkbox-option:hover {
    background: var(--bg-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.radio-option:has(input:checked),
.checkbox-option:has(input:checked) {
    background: rgba(37, 99, 235, 0.05);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.1);
}

.radio-option:has(input:checked)::before,
.checkbox-option:has(input:checked)::before {
    content: "✓";
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 1.25rem;
    height: 1.25rem;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
}

.radio-option input,
.checkbox-option input {
    width: 1.25rem;
    height: 1.25rem;
    margin: 0;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.radio-option label,
.checkbox-option label {
    cursor: pointer;
    font-weight: 500;
    color: var(--text-color);
    flex: 1;
    margin: 0;
    line-height: 1.4;
}

/* Summary Enhancements */
.summary-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.summary-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.summary-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.summary-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.summary-item strong {
    font-size: 0.9rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.summary-value {
    font-size: 1rem;
    color: var(--text-color);
    font-weight: 500;
    line-height: 1.4;
    word-wrap: break-word;
}

/* Progress Bar Enhancements */
.wizard-progress {
    background: var(--border-color);
    height: 10px;
    border-radius: 5px;
    margin-bottom: 2rem;
    overflow: hidden;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--success-color));
    border-radius: 5px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    width: 0%;
    position: relative;
    overflow: hidden;
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.2) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0.2) 75%,
        transparent 75%,
        transparent
    );
    background-size: 1rem 1rem;
    animation: progressAnimation 1s linear infinite;
}

@keyframes progressAnimation {
    0% { background-position: 0 0; }
    100% { background-position: 1rem 0; }
}

/* Wizard Controls Enhancements */
.wizard-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.wizard-controls .btn {
    min-width: 120px;
    position: relative;
}

/* Accessibility Improvements */
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus,
.radio-option:focus-within,
.checkbox-option:focus-within {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .radio-option,
    .checkbox-option {
        border-width: 3px;
    }
    
    .radio-option:has(input:checked),
    .checkbox-option:has(input:checked) {
        background: var(--primary-color);
        color: white;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    :root {
        --card-bg: #1f2937;
        --text-color: #f9fafb;
        --text-muted: #9ca3af;
        --border-color: #374151;
        --bg-color: #111827;
    }
    
    .form-group input,
    .form-group textarea,
    .form-group select,
    .radio-option,
    .checkbox-option {
        background: var(--card-bg);
        color: var(--text-color);
        border-color: var(--border-color);
    }
}

/* Animation für Step-Wechsel */
.wizard-step {
    animation: slideInFade 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Mobile Optimierungen */
@media (max-width: 768px) {
    .fields-container {
        gap: 1.5rem;
    }
    
    .radio-option,
    .checkbox-option {
        padding: 0.875rem;
        min-height: 3rem;
    }
    
    .summary-section {
        padding: 1rem;
    }
    
    .wizard-controls {
        flex-direction: column-reverse;
        gap: 0.75rem;
    }
    
    .wizard-controls .btn {
        width: 100%;
        justify-content: center;
    }
}
/* FÜGE zu VIEW-SERVER assets/view-style.css hinzu: */

/* Bearbeitbare Ansicht */
.view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
}

.view-controls {
    display: flex;
    gap: 0.5rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

/* Data Display Verbesserungen */
.data-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.data-section h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
    font-weight: 600;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}

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

.data-item {
    padding: 0.75rem;
    background: var(--bg-color);
    border-radius: var(--border-radius-sm);
    transition: all 0.3s ease;
}

.data-item:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.data-item.updated {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--success-color);
    animation: highlightUpdate 2s ease;
}

@keyframes highlightUpdate {
    0% { background: rgba(16, 185, 129, 0.3); }
    100% { background: rgba(16, 185, 129, 0.1); }
}

/* Edit Mode Styles */
.data-edit {
    animation: slideIn 0.3s ease;
}

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

.edit-section {
    background: var(--card-bg);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.edit-section::before {
    content: "✏️";
    position: absolute;
    top: -10px;
    right: 15px;
    background: var(--primary-color);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

.edit-section h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.edit-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.editable-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.editable-field label {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
}

.editable-field input,
.editable-field textarea,
.editable-field select {
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    transition: all 0.2s ease;
    background: white;
}

.editable-field input:focus,
.editable-field textarea:focus,
.editable-field select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.editable-field textarea {
    resize: vertical;
    min-height: 100px;
}

/* Radio/Checkbox in Edit Mode */
.editable-field .radio-option,
.editable-field .checkbox-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    margin: 0.25rem 0;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: background 0.2s ease;
}

.editable-field .radio-option:hover,
.editable-field .checkbox-option:hover {
    background: var(--bg-color);
}

.editable-field input[type="radio"],
.editable-field input[type="checkbox"] {
    width: auto;
    height: auto;
    margin: 0;
}

/* Edit Controls */
.edit-controls {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border-color);
}

.delete-option {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: var(--border-radius-sm);
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-weight: 500;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 1.25rem;
    height: 1.25rem;
    accent-color: var(--primary-color);
}

.checkmark {
    position: relative;
}

.delete-info {
    margin-top: 0.5rem;
    margin-left: 2rem;
}

.delete-info small {
    color: #92400e;
    font-style: italic;
}

.action-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1rem;
}

.btn-success {
    background: var(--success-color);
    color: white;
    position: relative;
    overflow: hidden;
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: var(--shadow);
}

.btn-success.has-changes {
    animation: pulse 2s infinite;
}

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

/* Success Message */
.success-message {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 2px solid var(--success-color);
    border-radius: var(--border-radius);
    animation: successSlideIn 0.5s ease;
}

@keyframes successSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.success-message .success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: var(--success-color);
}

.success-message h3 {
    color: var(--success-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

/* Export Controls */
.export-controls {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    padding: 1rem;
    margin-top: 1rem;
}

.export-controls h4 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
    color: var(--text-color);
}

.export-controls .btn {
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .view-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .view-controls {
        width: 100%;
        justify-content: center;
    }
    
    .data-grid {
        grid-template-columns: 1fr;
    }
    
    .edit-fields {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .action-buttons .btn {
        width: 100%;
    }
    
    .success-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .success-actions .btn {
        width: 100%;
        max-width: 250px;
    }
}

/* Print Styles für bearbeitete Version */
@media print {
    .view-controls,
    .edit-controls,
    .action-buttons,
    .export-controls {
        display: none !important;
    }
    
    .data-edit {
        background: white !important;
    }
    
    .edit-section {
        border: 1px solid #ccc !important;
        page-break-inside: avoid;
    }
    
    .editable-field input,
    .editable-field textarea,
    .editable-field select {
        border: none !important;
        background: transparent !important;
        padding: 0 !important;
        font-weight: bold;
    }
    
    .success-message {
        background: white !important;
        border: 1px solid #ccc !important;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .edit-section {
        background: #1f2937;
        border-color: #3b82f6;
    }
    
    .editable-field input,
    .editable-field textarea,
    .editable-field select {
        background: #374151;
        color: #f9fafb;
        border-color: #4b5563;
    }
    
    .delete-option {
        background: #451a03;
        border-color: #92400e;
    }
    
    .delete-info small {
        color: #fbbf24;
    }
}

/* Focus Indicators für Accessibility */
.checkbox-label:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: var(--border-radius-sm);
}

/* Loading States */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    position: relative;
}

.btn:disabled::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: buttonSpin 1s linear infinite;
}

@keyframes buttonSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}