/* Allgemeine Stile */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 30px;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Überschrift */
h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 30px;
    font-size: 2.5rem;
    font-weight: 300;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Aktionen */
.actions {
    text-align: center;
    margin-bottom: 30px;
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.actions .btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Filterformular */
.filter-form {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.form {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: flex-end;
}

.form-group {
    flex: 1;
    min-width: 200px;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    color: #495057;
    font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    background-color: #fff;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #667eea;
    outline: none;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    display: inline-block;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #5a6268 0%, #495057 100%);
}

/* Tabellen-Container */
.table-container {
    overflow-x: auto;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

/* Tabelle */
.table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
}

.table th {
    padding: 18px 15px;
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    font-weight: 600;
    text-align: left;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table td {
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.table tr:hover {
    background-color: #f8f9fa;
    transition: background-color 0.2s ease;
}

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

/* Quantity Badge */
.quantity-badge {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-weight: 600;
    font-size: 14px;
}

/* Buttons in der Tabelle */
.btn-small {
    padding: 8px 16px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-small:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(40, 167, 69, 0.3);
}

/* No Data */
.no-data {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    padding: 40px;
}

/* Footer Statistics */
.footer-stats {
    text-align: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    color: #6c757d;
    font-weight: 500;
}

/* Formular für Asset hinzufügen */
.form.add-asset {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: #f8f9fa;
    padding: 30px;
    border-radius: 12px;
    border: 1px solid #e9ecef;
}

.form.add-asset .form-group {
    flex: none;
    min-width: auto;
}

/* Nachrichten */
.message {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    font-weight: 500;
    border-left: 4px solid;
}

.message.success {
    background-color: #d1edff;
    color: #0c5460;
    border-left-color: #17a2b8;
}

.message.error {
    background-color: #f8d7da;
    color: #721c24;
    border-left-color: #dc3545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        width: 95%;
        margin: 15px auto;
        padding: 20px;
    }

    h1 {
        font-size: 2rem;
        margin-bottom: 20px;
    }

    .actions {
        flex-direction: column;
        align-items: center;
    }

    .actions .btn {
        width: 100%;
        max-width: 300px;
    }

    .form {
        flex-direction: column;
    }

    .form-group {
        min-width: 100%;
    }

    .table th,
    .table td {
        padding: 10px 8px;
        font-size: 14px;
    }

    .table-container {
        overflow-x: scroll;
    }

    .table {
        min-width: 600px;
    }
}

@media (max-width: 480px) {
    .container {
        width: 98%;
        padding: 15px;
    }

    h1 {
        font-size: 1.8rem;
    }

    .table th,
    .table td {
        padding: 8px 6px;
        font-size: 12px;
    }

    .btn-small {
        padding: 6px 12px;
        font-size: 12px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 10px;
        font-size: 14px;
    }
}

/* Zusätzliche Utility-Klassen */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mb-20 {
    margin-bottom: 20px;
}

.mt-20 {
    margin-top: 20px;
}

/* Links */
a {
    color: #667eea;
    text-decoration: none;
}

a:hover {
    color: #5a6bf0;
    text-decoration: underline;
}

/* Validierung */
input:invalid,
select:invalid {
    border-color: #dc3545;
}

input:valid,
select:valid {
    border-color: #28a745;
}

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

.table tr {
    animation: fadeIn 0.3s ease-in-out;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Print Styles */
@media print {
    body {
        background: white;
    }
    
    .container {
        box-shadow: none;
        max-width: 100%;
        margin: 0;
        padding: 0;
    }
    
    .actions,
    .filter-form {
        display: none;
    }
    
    .table th {
        background: #f8f9fa !important;
        color: #333 !important;
    }
}

/* Suchfunktion Styling */
.search-container {
    margin-bottom: 25px;
}

.search-form {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    border: 1px solid #e9ecef;
}

.search-input-container {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 300px;
    padding: 15px 20px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 16px;
    background-color: #f8f9fa;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.06);
}

.search-input:focus {
    border-color: #667eea;
    background-color: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1), inset 0 2px 4px rgba(0,0,0,0.06);
}

.search-btn {
    padding: 15px 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.search-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.clear-search-btn {
    padding: 15px 20px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 25px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.clear-search-btn:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

/* Suchergebnisse Info */
.search-results-info {
    background: #e7f3ff;
    border: 1px solid #b3d9ff;
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 20px;
    color: #004085;
}

.search-results-info p {
    margin: 5px 0;
    font-weight: 500;
}

/* Highlight für Suchbegriffe */
mark {
    background: linear-gradient(120deg, #a8edea 0%, #fed6e3 100%);
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 600;
}

/* Responsive Design für Suche */
@media (max-width: 768px) {
    .search-input-container {
        flex-direction: column;
    }
    
    .search-input {
        min-width: 100%;
        margin-bottom: 10px;
    }
    
    .search-btn,
    .clear-search-btn {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .search-form {
        padding: 15px;
    }
    
    .search-input {
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .search-btn,
    .clear-search-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* Animation für Suchergebnisse */
@keyframes highlightFade {
    0% {
        background-color: #fff3cd;
    }
    100% {
        background-color: transparent;
    }
}

.table tr:hover {
    animation: highlightFade 0.5s ease-in-out;
}

/* Login-Styling */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-btn {
    padding: 15px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
}

.login-info {
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.login-info h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 16px;
}

.login-info p {
    margin: 8px 0;
    color: #6c757d;
    font-size: 14px;
}

/* User Header */
.user-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    border-left: 4px solid #667eea;
}

.user-info .welcome-text {
    color: #2c3e50;
    font-size: 16px;
}

.btn-logout {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    padding: 8px 16px;
    font-size: 14px;
}

.btn-logout:hover {
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
}

/* Responsive Design für Login */
@media (max-width: 480px) {
    .login-box {
        padding: 30px 20px;
        margin: 10px;
    }
    
    .user-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

/* Asset-Info-Box */
.asset-info-box {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    border-left: 4px solid #667eea;
}

.asset-info-box h3 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 18px;
}

.asset-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.detail-item label {
    font-weight: 600;
    color: #6c757d;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-item span {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 500;
}

/* Quantity Badge Large */
.quantity-badge-large {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 18px;
    display: inline-block;
}

/* Quantity Controls */
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.btn-quantity {
    width: 40px;
    height: 40px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.btn-quantity:hover {
    background: #667eea;
    color: white;
    transform: scale(1.1);
}

.quantity-controls input {
    width: 80px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    padding: 10px;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
}

/* Danger Button */
.btn-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
    transform: translateY(-1px);
}

/* Action Buttons in Table */
.action-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.btn-checkout {
    background: linear-gradient(135deg, #fd7e14 0%, #e85d04 100%);
    white-space: nowrap;
}

.btn-checkout:hover {
    background: linear-gradient(135deg, #e85d04 0%, #d00000 100%);
}

/* Responsive Design für neue Elemente */
@media (max-width: 768px) {
    .asset-details {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .action-buttons .btn {
        text-align: center;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .form-actions .btn {
        width: 100%;
    }
    
    .quantity-controls {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .asset-info-box {
        padding: 15px;
    }
    
    .btn-quantity {
        width: 35px;
        height: 35px;
        font-size: 18px;
    }
    
    .quantity-controls input {
        width: 60px;
        font-size: 16px;
    }
}

/* Animation für erfolgreiche Ausbuchung */
@keyframes checkmarkAnimation {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.message.success::before {
    content: "✓ ";
    animation: checkmarkAnimation 0.5s ease-in-out;
}

/* Statistiken Container */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.stat-box h3 {
    margin: 0 0 10px 0;
    font-size: 14px;
    font-weight: 500;
    opacity: 0.9;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    display: block;
}

/* Transaktionstyp Badges */
.transaction-type {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.type-in {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.type-out {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
}

.type-transfer {
    background: linear-gradient(135deg, #007bff 0%, #6f42c1 100%);
    color: white;
}

/* Standort-Informationen */
.location-info {
    font-size: 13px;
    line-height: 1.4;
}

.location-from {
    color: #dc3545;
    font-weight: 500;
}

.location-to {
    color: #28a745;
    font-weight: 500;
}

.transfer-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.transfer-arrow {
    text-align: center;
    font-size: 12px;
}

/* Benutzer Badge */
.user-badge {
    background: #f8f9fa;
    color: #495057;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    border: 1px solid #dee2e6;
}

/* Datum/Zeit Spalte */
.datetime {
    font-size: 13px;
    color: #6c757d;
    white-space: nowrap;
}

/* Responsive Design für Historie */
@media (max-width: 768px) {
    .stats-container {
        grid-template-columns: 1fr;
    }
    
    .transfer-info {
        font-size: 11px;
    }
    
    .location-info {
        font-size: 11px;
    }
    
    .table th:nth-child(5),
    .table td:nth-child(5) {
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .table {
        font-size: 12px;
    }
    
    .transaction-type {
        padding: 4px 8px;
        font-size: 10px;
    }
    
    .user-badge {
        padding: 2px 6px;
        font-size: 10px;
    }
    
    .datetime {
        font-size: 11px;
    }
}

/* Hilfe-Box für Buchungsarten */
.help-box {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin-top: 30px;
    border-left: 4px solid #17a2b8;
}

.help-box h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 16px;
}

.help-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.help-item {
    padding: 10px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    font-size: 14px;
}

.help-item strong {
    color: #495057;
}

/* Schnellzugriff Buttons */
.quick-actions {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    border-left: 4px solid #ffc107;
}

.quick-actions h3 {
    color: #856404;
    margin-bottom: 15px;
    font-size: 16px;
}

.quick-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.quick-buttons .btn {
    font-size: 13px;
    padding: 8px 12px;
}

/* Letzte Transaktionen */
.recent-transactions {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    border-left: 4px solid #6c757d;
}

.recent-transactions h3 {
    color: #495057;
    margin-bottom: 15px;
    font-size: 16px;
}

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

.transaction-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 8px 12px;
    background: white;
    border-radius: 6px;
    border: 1px solid #dee2e6;
    font-size: 13px;
}

.transaction-type-small {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    min-width: 80px;
    text-align: center;
}

.transaction-type-small.type-in {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.transaction-type-small.type-out {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
}

.transaction-type-small.type-transfer {
    background: linear-gradient(135deg, #007bff 0%, #6f42c1 100%);
    color: white;
}

.transaction-quantity {
    font-weight: bold;
    color: #495057;
    min-width: 30px;
}

.transaction-user {
    color: #6c757d;
    flex: 1;
}

.transaction-date {
    color: #adb5bd;
    font-size: 12px;
    white-space: nowrap;
}

/* Asset Info Box erweitern */
.asset-info-box .asset-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

/* Custom Notes Textarea */
#custom_notes {
    margin-top: 10px;
    min-height: 80px;
}

/* Transaktionstyp Select mit Icons */
#transactionType option {
    padding: 10px;
}

/* Form Actions erweitern */
.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
}

.form-actions .btn {
    min-width: 150px;
}

/* Success Message mit Buttons */
.message.success .btn {
    margin: 0 5px;
    padding: 5px 10px;
    font-size: 12px;
}

/* Quantity Controls erweitern */
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
}

.quantity-controls input {
    width: 100px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
}

/* User Badge in Asset Info */
.asset-details .user-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 600;
}

/* Responsive Design für neue Elemente */
@media (max-width: 768px) {
    .help-items {
        gap: 8px;
    }
    
    .help-item {
        padding: 8px;
        font-size: 13px;
    }
    
    .quick-buttons {
        flex-direction: column;
    }
    
    .quick-buttons .btn {
        width: 100%;
    }
    
    .transaction-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 10px;
    }
    
    .transaction-type-small {
        min-width: auto;
    }
    
    .asset-details {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .form-actions .btn {
        width: 100%;
        min-width: auto;
    }
    
    .quantity-controls {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .help-box,
    .quick-actions,
    .recent-transactions {
        padding: 15px;
    }
    
    .help-box h3,
    .quick-actions h3,
    .recent-transactions h3 {
        font-size: 14px;
    }
    
    .transaction-item {
        font-size: 12px;
    }
    
    .transaction-type-small {
        font-size: 10px;
        padding: 3px 6px;
    }
    
    .quantity-controls input {
        width: 80px;
        font-size: 16px;
    }
    
    .btn-quantity {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
}

/* Animation für erfolgreiche Aktionen */
@keyframes successPulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        transform: scale(1.02);
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

.message.success {
    animation: successPulse 1s ease-in-out;
}

/* Loading State für Buttons */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn.loading::after {
    content: "...";
    animation: loading 1s infinite;
}

@keyframes loading {
    0%, 33% { content: "."; }
    34%, 66% { content: ".."; }
    67%, 100% { content: "..."; }
}

/* Admin-Header */
.admin-header {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 10px;
}

.admin-info {
    display: flex;
    align-items: center;
}

.admin-actions {
    display: flex;
    gap: 10px;
}

/* Admin Notice */
.admin-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-notice .admin-badge {
    background: #ffc107;
    color: #212529;
}

/* Admin Stats */
.admin-stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.admin-stat-box {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.3s ease;
}

.admin-stat-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.stat-icon {
    font-size: 3rem;
    opacity: 0.8;
}

.stat-info h3 {
    margin: 0 0 5px 0;
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
}

.stat-info .stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
}

/* Admin Cards */
.admin-functions {
    margin-bottom: 40px;
}

.admin-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 25px;
}

.admin-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    transition: transform 0.3s ease;
}

.admin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.admin-card .card-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.admin-card h3 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.admin-card p {
    color: #6c757d;
    margin-bottom: 25px;
    line-height: 1.6;
}

/* Admin Sections */
.admin-section {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
}

.admin-section h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 10px;
}

/* Usage Badge */
.usage-badge {
    background: #e9ecef;
    color: #495057;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

/* 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: white;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.modal-content h3 {
    margin-bottom: 20px;
    color: #2c3e50;
}

/* Recent Activities */
.recent-admin-activities {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
}

.recent-admin-activities h3 {
    color: #495057;
    margin-bottom: 20px;
}

.activities-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    background: white;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}

.activity-type {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.activity-type.type-in {
    background: rgba(40, 167, 69, 0.1);
}

.activity-type.type-out {
    background: rgba(220, 53, 69, 0.1);
}

.activity-type.type-transfer {
    background: rgba(0, 123, 255, 0.1);
}

.activity-details {
    flex: 1;
    font-size: 14px;
    line-height: 1.4;
}

.activity-details small {
    display: block;
    color: #6c757d;
    margin-top: 4px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .admin-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .admin-stats-container {
        grid-template-columns: 1fr;
    }
    
    .admin-cards {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 20px;
        padding: 20px;
    }
    
    .activity-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

/* Admin Button */
.btn-admin {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
}

.btn-admin:hover {
    background: linear-gradient(135deg, #c82333 0%, #e85d04 100%);
}

/* Disabled Button */
.btn-disabled {
    background: #6c757d !important;
    cursor: not-allowed !important;
    opacity: 0.5;
}

.btn-disabled:hover {
    background: #6c757d !important;
    transform: none !important;
}

/* Footer Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    color: #6c757d;
    font-weight: 500;
}

.stat-value {
    color: #2c3e50;
    font-weight: 700;
    font-size: 1.1rem;
}

/* Quick Tips */
.quick-tips {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border: 1px solid #bbdefb;
    border-radius: 12px;
    padding: 25px;
    margin-top: 30px;
}

.quick-tips h3 {
    color: #1565c0;
    margin-bottom: 20px;
    text-align: center;
}

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

.tip-item {
    background: rgba(255, 255, 255, 0.7);
    padding: 15px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.5;
}

.tip-item strong {
    color: #1565c0;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .tips-grid {
        grid-template-columns: 1fr;
    }
    
    .user-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .user-actions {
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }
    
    .user-actions .btn {
        width: 100%;
    }
}

/* =============================================================
   ADMIN-BEREICH CSS-ERWEITERUNGEN
   ============================================================= */

/* Admin-Header */
.admin-header {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

.admin-badge {
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 10px;
}

.admin-info {
    display: flex;
    align-items: center;
}

.admin-actions {
    display: flex;
    gap: 10px;
}

/* Admin Notice */
.admin-notice {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.admin-notice .admin-badge {
    background: #ffc107;
    color: #212529;
}

/* Admin Stats */
.admin-stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.admin-stat-box {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.admin-stat-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.stat-icon {
    font-size: 3rem;
    opacity: 0.8;
}

.stat-info h3 {
    margin: 0 0 5px 0;
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-info .stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
}

/* Admin Cards */
.admin-functions {
    margin-bottom: 40px;
}

.admin-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 25px;
}

.admin-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.admin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #007bff;
}

.admin-card .card-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.admin-card h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.admin-card p {
    color: #6c757d;
    margin-bottom: 25px;
    line-height: 1.6;
}

/* Admin Sections */
.admin-section {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.admin-section h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 10px;
    font-size: 1.3rem;
}

/* Usage Badge */
.usage-badge {
    background: linear-gradient(135deg, #e9ecef 0%, #f8f9fa 100%);
    color: #495057;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    border: 1px solid #dee2e6;
}

/* Role Badges */
.role-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.admin-role {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    color: white;
}

.user-role {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    color: white;
}

/* 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;
    backdrop-filter: blur(3px);
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    transform: scale(0.9);
    animation: modalOpen 0.3s ease forwards;
}

@keyframes modalOpen {
    to {
        transform: scale(1);
    }
}

.modal-content h3 {
    margin-bottom: 20px;
    color: #2c3e50;
    text-align: center;
}

/* Recent Activities */
.recent-admin-activities {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.recent-admin-activities h3 {
    color: #495057;
    margin-bottom: 20px;
}

.activities-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    background: white;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    transition: all 0.2s ease;
}

.activity-item:hover {
    background: #f1f3f4;
    border-color: #007bff;
}

.activity-type {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0,0,0,0.05);
}

.activity-type.type-in {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.activity-type.type-out {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.activity-type.type-transfer {
    background: rgba(0, 123, 255, 0.1);
    color: #007bff;
}

.activity-details {
    flex: 1;
    font-size: 14px;
    line-height: 1.4;
}

.activity-details strong {
    color: #2c3e50;
}

.activity-details small {
    display: block;
    color: #6c757d;
    margin-top: 4px;
}

/* Enhanced Action Buttons */
.action-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    align-items: center;
}

.action-buttons .btn-small {
    padding: 4px 8px;
    font-size: 11px;
    border-radius: 4px;
    white-space: nowrap;
}

/* Enhanced Table Styling */
.table th {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    font-size: 13px;
    font-weight: 600;
}

.table tbody tr:hover {
    background: rgba(0, 123, 255, 0.05);
    transform: scale(1.01);
    transition: all 0.2s ease;
}

/* Responsive Design für Admin-Bereich */
@media (max-width: 768px) {
    .admin-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .admin-actions {
        width: 100%;
        justify-content: center;
    }
    
    .admin-stats-container {
        grid-template-columns: 1fr;
    }
    
    .admin-cards {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        margin: 20px;
        padding: 20px;
    }
    
    .activity-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .action-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .action-buttons .btn-small {
        width: 100%;
        text-align: center;
    }
    
    .admin-notice {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .admin-section {
        padding: 15px;
    }
    
    .admin-stat-box {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .stat-icon {
        font-size: 2.5rem;
    }
    
    .admin-card {
        padding: 20px;
    }
    
    .modal-content {
        padding: 15px;
    }
    
    .table {
        font-size: 12px;
    }
    
    .table th,
    .table td {
        padding: 8px 4px;
    }
}

/* Loading States */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s ease-in-out infinite;
}

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

/* Success/Error Animations */
.message.success {
    animation: slideInSuccess 0.5s ease;
}

.message.error {
    animation: slideInError 0.5s ease;
}

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

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

/* Hover Effects */
.admin-card:hover .card-icon {
    animation: bounce 0.5s ease;
}

@keyframes bounce {
    0%, 20%, 60%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    80% {
        transform: translateY(-5px);
    }
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
    .admin-section {
        background: #2c3e50;
        color: #ecf0f1;
        border-color: #34495e;
    }
    
    .modal-content {
        background: #2c3e50;
        color: #ecf0f1;
    }
    
    .table th {
        background: #34495e;
    }
    
    .table tbody tr:hover {
        background: rgba(52, 73, 94, 0.1);
    }
}

/* =============================================================
   VERBESSERTE ADMIN-VERWALTUNGSSEITEN CSS
   ============================================================= */

/* Admin Sections - Verbesserte Darstellung */
.admin-section {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid #e3e6f0;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    position: relative;
    overflow: hidden;
}

.admin-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

.admin-section h2 {
    color: #2c3e50;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e9ecef;
    font-size: 1.4rem;
    font-weight: 600;
    position: relative;
}

.admin-section h2::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

/* Formulare in Admin-Bereichen */
.admin-section .form {
    background: white;
    padding: 25px;
    border-radius: 12px;
    border: 1px solid #e3e6f0;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.admin-section .form-group {
    margin-bottom: 20px;
    position: relative;
}

.admin-section .form-group label {
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    display: block;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-section .form-group input,
.admin-section .form-group select,
.admin-section .form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    background-color: #ffffff;
    box-sizing: border-box;
}

.admin-section .form-group input:focus,
.admin-section .form-group select:focus,
.admin-section .form-group textarea:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
    background-color: #ffffff;
}

/* Verbesserte Tabellen für Admin */
.admin-section .table-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border: 1px solid #e3e6f0;
}

.admin-section .table {
    margin-bottom: 0;
    border: none;
}

.admin-section .table th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    padding: 15px 12px;
    border: none;
    position: relative;
}

.admin-section .table th::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
}

.admin-section .table td {
    padding: 15px 12px;
    border-bottom: 1px solid #f1f3f4;
    vertical-align: middle;
    font-size: 14px;
    border-left: none;
    border-right: none;
}

.admin-section .table tbody tr {
    transition: all 0.2s ease;
}

.admin-section .table tbody tr:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.admin-section .table tbody tr:last-child td {
    border-bottom: none;
}

/* Verbesserte Buttons */
.admin-section .btn {
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 8px;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.admin-section .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.admin-section .btn-small {
    padding: 6px 12px;
    font-size: 11px;
    border-radius: 6px;
    font-weight: 600;
}

/* Spezielle Button-Farben */
.admin-section .btn-danger {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
}

.admin-section .btn-danger:hover {
    background: linear-gradient(135deg, #c0392b 0%, #a93226 100%);
}

.admin-section .btn-disabled {
    background: #95a5a6 !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

.admin-section .btn-disabled:hover {
    transform: none !important;
    box-shadow: none !important;
}

/* Verbesserte Badges */
.usage-badge {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
    white-space: nowrap;
}

.role-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.admin-role {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
}

.user-role {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: white;
}

/* Verbesserte Action Buttons */
.action-buttons {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
}

.action-buttons .btn-small {
    min-width: 80px;
    justify-content: center;
    text-align: center;
}

/* Verbesserte Modals */
.modal {
    backdrop-filter: blur(5px);
    animation: fadeInModal 0.3s ease;
}

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

.modal-content {
    background: white;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid #e3e6f0;
    position: relative;
    overflow: hidden;
}

.modal-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
}

.modal-content h3 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f1f3f4;
    text-align: center;
    font-size: 1.3rem;
}

.modal-content .form-group {
    margin-bottom: 20px;
}

.modal-content .form-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #f1f3f4;
}

/* No Data Message */
.admin-section .no-data {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    padding: 40px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 8px;
    margin: 20px 0;
}

.admin-section .no-data::before {
    content: '📋';
    display: block;
    font-size: 3rem;
    margin-bottom: 15px;
    opacity: 0.5;
}

/* Quantity Badge */
.admin-section .quantity-badge {
    background: linear-gradient(135deg, #27ae60 0%, #229954 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Responsive Verbesserungen */
@media (max-width: 768px) {
    .admin-section {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .admin-section .form {
        padding: 20px;
    }
    
    .admin-section .table-container {
        overflow-x: auto;
    }
    
    .admin-section .table {
        min-width: 600px;
        font-size: 13px;
    }
    
    .admin-section .table th,
    .admin-section .table td {
        padding: 10px 8px;
    }
    
    .action-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .action-buttons .btn-small {
        width: 100%;
        min-width: auto;
    }
    
    .modal-content {
        margin: 20px;
        padding: 20px;
    }
    
    .modal-content .form-actions {
        flex-direction: column;
    }
    
    .modal-content .form-actions .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .admin-section {
        padding: 15px;
    }
    
    .admin-section h2 {
        font-size: 1.2rem;
    }
    
    .admin-section .form {
        padding: 15px;
    }
    
    .admin-section .table {
        min-width: 500px;
        font-size: 12px;
    }
    
    .admin-section .btn {
        padding: 10px 16px;
        font-size: 12px;
    }
    
    .admin-section .btn-small {
        padding: 4px 8px;
        font-size: 10px;
    }
    
    .usage-badge,
    .role-badge,
    .quantity-badge {
        font-size: 10px;
        padding: 4px 8px;
    }
}

/* Smooth Scrolling für Tabellen */
.admin-section .table-container {
    scrollbar-width: thin;
    scrollbar-color: #667eea #f1f3f4;
}

.admin-section .table-container::-webkit-scrollbar {
    height: 8px;
}

.admin-section .table-container::-webkit-scrollbar-track {
    background: #f1f3f4;
    border-radius: 4px;
}

.admin-section .table-container::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 4px;
}

.admin-section .table-container::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(90deg, #5a6fd8 0%, #6a4190 100%);
}

/* Loading Animation für Buttons */
.admin-section .btn.loading {
    position: relative;
    color: transparent !important;
}

.admin-section .btn.loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: buttonSpin 1s linear infinite;
}

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

/* Hover-Effekte für Formularfelder */
.admin-section .form-group input:hover,
.admin-section .form-group select:hover,
.admin-section .form-group textarea:hover {
    border-color: #a8b3d9;
}

/* Fokus-Styling für bessere Accessibility */
.admin-section .btn:focus,
.admin-section .form-group input:focus,
.admin-section .form-group select:focus,
.admin-section .form-group textarea:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Success/Error States für Formularfelder */
.admin-section .form-group.success input,
.admin-section .form-group.success select {
    border-color: #27ae60;
    background-color: rgba(39, 174, 96, 0.05);
}

.admin-section .form-group.error input,
.admin-section .form-group.error select {
    border-color: #e74c3c;
    background-color: rgba(231, 76, 60, 0.05);
}

/* Improved spacing and typography */
.admin-section p,
.admin-section li {
    line-height: 1.6;
    color: #374151;
}

.admin-section strong {
    color: #2c3e50;
    font-weight: 600;
}

/* Card-like appearance for individual items */
.admin-section .table tbody tr {
    border-radius: 8px;
    margin-bottom: 4px;
}

/* Enhanced visual hierarchy */
.admin-section .table th:first-child {
    border-radius: 0;
}

.admin-section .table th:last-child {
    border-radius: 0;
}

/* Better visual feedback */
.admin-section .btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Export-Sektion */
.export-section {
    background: linear-gradient(135deg, #e8f5e8 0%, #f0f8ff 100%);
    border: 1px solid #c3e6c3;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    border-left: 4px solid #28a745;
}

.export-section h3 {
    color: #155724;
    margin-bottom: 20px;
    font-size: 1.2rem;
    text-align: center;
}

.export-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 15px;
}

.btn-export {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(40, 167, 69, 0.3);
}

.btn-export:hover {
    background: linear-gradient(135deg, #218838 0%, #1e7e34 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.4);
    text-decoration: none;
    color: white;
}

.export-info {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid #ffc107;
    border-radius: 6px;
    padding: 10px;
    margin-top: 15px;
    text-align: center;
    color: #856404;
    font-size: 13px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .export-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-export {
        width: 100%;
        max-width: 300px;
        text-align: center;
    }
}

/* Loading Animation für Export */
.btn-export.loading {
    position: relative;
    color: transparent !important;
}

.btn-export.loading::after {
    content: "📥";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 16px;
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.2); }
}

/* Export Cards */
.export-card {
    border-left: 4px solid #28a745;
}

.export-card.special {
    border-left: 4px solid #ffc107;
    background: linear-gradient(135deg, #fff9e6 0%, #f8f9fa 100%);
}

.btn-export-special {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%);
    color: #212529;
    font-weight: 700;
}

.btn-export-special:hover {
    background: linear-gradient(135deg, #e0a800 0%, #dc6502 100%);
    color: #212529;
}

/* Card Stats */
.card-stats {
    margin: 10px 0;
    padding: 8px;
    background: rgba(0,0,0,0.05);
    border-radius: 4px;
}

.card-stats small {
    color: #6c757d;
    font-size: 12px;
}

/* System Info */
.system-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.system-info-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.system-info-card h4 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f1f3f4;
}

.info-item:last-child {
    border-bottom: none;
}

.info-item.warning .info-value {
    color: #dc3545;
    font-weight: 600;
}

.info-item.success .info-value {
    color: #28a745;
    font-weight: 600;
}

/* Quick Actions */
.quick-actions-admin {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-top: 30px;
}

.quick-action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.btn-quick {
    background: linear-gradient(135deg, #6f42c1 0%, #e83e8c 100%);
    color: white;
    padding: 8px 16px;
    font-size: 13px;
}

.btn-quick:hover {
    background: linear-gradient(135deg, #5a2a9a 0%, #c02560 100%);
}

/* Enhanced stat boxes */
.admin-stat-box.warning {
    border-left: 4px solid #ffc107;
    background: linear-gradient(135deg, #fff9e6 0%, #ffffff 100%);
}

.admin-stat-box.success {
    border-left: 4px solid #28a745;
    background: linear-gradient(135deg, #e8f5e8 0%, #ffffff 100%);
}

.admin-stat-box.info {
    border-left: 4px solid #17a2b8;
    background: linear-gradient(135deg, #e6f7ff 0%, #ffffff 100%);
}

.admin-stat-box.primary {
    border-left: 4px solid #007bff;
    background: linear-gradient(135deg, #e3f2fd 0%, #ffffff 100%);
}

/* =============================================================
   FOOTER & CREDITS SYSTEM
   ============================================================= */

/* MAIN FOOTER */
.app-footer {
    background: linear-gradient(135deg, var(--gray-900) 0%, var(--gray-800) 100%);
    color: var(--white);
    padding: var(--space-8) var(--space-6) var(--space-6);
    margin-top: var(--space-16);
    border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
    box-shadow: var(--shadow-xl);
    position: relative;
    overflow: hidden;
}

.app-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent), var(--success));
    background-size: 400% 100%;
    animation: gradientShift 8s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-8);
    align-items: center;
}

/* CREDITS SECTION */
.credits-section {
    text-align: center;
    padding: var(--space-6);
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.credits-title {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--white);
    margin-bottom: var(--space-4);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.credits-team {
    display: flex;
    justify-content: center;
    gap: var(--space-8);
    flex-wrap: wrap;
    margin-bottom: var(--space-4);
}

.team-member {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4);
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 200px;
}

.team-member:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-lg);
}

.member-avatar {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--white);
    box-shadow: var(--shadow-lg);
}

.member-info {
    text-align: center;
}

.member-name {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--white);
    margin-bottom: var(--space-1);
}

.member-role {
    font-size: var(--text-sm);
    color: var(--gray-300);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.member-description {
    font-size: var(--text-xs);
    color: var(--gray-400);
    margin-top: var(--space-2);
    line-height: 1.4;
}

/* SYSTEM INFO FOOTER */
.system-info-footer {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--space-4);
}

.system-version {
    font-size: var(--text-sm);
    color: var(--gray-300);
    margin-bottom: var(--space-2);
}

.copyright {
    font-size: var(--text-xs);
    color: var(--gray-400);
    opacity: 0.8;
}

/* MINI FOOTER (für Admin-Seiten) */
.mini-footer {
    background: var(--white);
    border-top: 1px solid var(--gray-200);
    padding: var(--space-4) var(--space-6);
    margin-top: var(--space-8);
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.mini-credits {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-4);
    flex-wrap: wrap;
    font-size: var(--text-sm);
    color: var(--gray-600);
}

.mini-credits .separator {
    color: var(--gray-400);
    font-weight: 300;
}

.mini-credits .credit-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-weight: 500;
}

.mini-credits .credit-icon {
    font-size: var(--text-lg);
}

/* FLOATING CREDIT BADGE (optional) */
.floating-credits {
    position: fixed;
    bottom: var(--space-4);
    right: var(--space-4);
    background: linear-gradient(135deg, var(--gray-900) 0%, var(--gray-700) 100%);
    color: var(--white);
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transition: var(--transition);
    opacity: 0.8;
    backdrop-filter: blur(10px);
}

.floating-credits:hover {
    opacity: 1;
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }
    
    .credits-team {
        flex-direction: column;
        gap: var(--space-4);
    }
    
    .team-member {
        min-width: auto;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .mini-credits {
        flex-direction: column;
        gap: var(--space-2);
    }
    
    .floating-credits {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: var(--space-4);
        text-align: center;
        border-radius: var(--radius-lg);
    }
}

@media (max-width: 480px) {
    .app-footer {
        padding: var(--space-6) var(--space-4) var(--space-4);
        border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    }
    
    .credits-section {
        padding: var(--space-4);
    }
    
    .member-avatar {
        width: 48px;
        height: 48px;
        font-size: var(--text-xl);
    }
    
    .credits-title {
        font-size: var(--text-base);
    }
    
    .member-name {
        font-size: var(--text-base);
    }
    
    .member-role {
        font-size: var(--text-xs);
    }
}

/* PRINT STYLES */
@media print {
    .app-footer,
    .mini-footer,
    .floating-credits {
        display: none;
    }
}

/* DARK MODE ADJUSTMENTS */
@media (prefers-color-scheme: dark) {
    .mini-footer {
        background: #374151;
        border-top-color: #4b5563;
    }
    
    .mini-credits {
        color: #d1d5db;
    }
    
    .mini-credits .separator {
        color: #6b7280;
    }
}

/* =============================================================
   FOOTER & CREDITS SYSTEM
   ============================================================= */

/* MAIN FOOTER */
.app-footer {
    background: linear-gradient(135deg, var(--gray-900) 0%, var(--gray-800) 100%);
    color: var(--white);
    padding: var(--space-8) var(--space-6) var(--space-6);
    margin-top: var(--space-16);
    border-radius: var(--radius-2xl) var(--radius-2xl) 0 0;
    box-shadow: var(--shadow-xl);
    position: relative;
    overflow: hidden;
}

.app-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent), var(--success));
    background-size: 400% 100%;
    animation: gradientShift 8s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-8);
    align-items: center;
}

/* CREDITS SECTION */
.credits-section {
    text-align: center;
    padding: var(--space-6);
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.credits-title {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--white);
    margin-bottom: var(--space-4);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.credits-team {
    display: flex;
    justify-content: center;
    gap: var(--space-8);
    flex-wrap: wrap;
    margin-bottom: var(--space-4);
}

.team-member {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4);
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 200px;
}

.team-member:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-lg);
}

.member-avatar {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--white);
    box-shadow: var(--shadow-lg);
}

.member-info {
    text-align: center;
}

.member-name {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--white);
    margin-bottom: var(--space-1);
}

.member-role {
    font-size: var(--text-sm);
    color: var(--gray-300);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.member-description {
    font-size: var(--text-xs);
    color: var(--gray-400);
    margin-top: var(--space-2);
    line-height: 1.4;
}

/* SYSTEM INFO FOOTER */
.system-info-footer {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: var(--space-4);
}

.system-version {
    font-size: var(--text-sm);
    color: var(--gray-300);
    margin-bottom: var(--space-2);
}

.copyright {
    font-size: var(--text-xs);
    color: var(--gray-400);
    opacity: 0.8;
}

/* MINI FOOTER (für Admin-Seiten) */
.mini-footer {
    background: var(--white);
    border-top: 1px solid var(--gray-200);
    padding: var(--space-4) var(--space-6);
    margin-top: var(--space-8);
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.mini-credits {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--space-4);
    flex-wrap: wrap;
    font-size: var(--text-sm);
    color: var(--gray-600);
}

.mini-credits .separator {
    color: var(--gray-400);
    font-weight: 300;
}

.mini-credits .credit-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-weight: 500;
}

.mini-credits .credit-icon {
    font-size: var(--text-lg);
}

/* FLOATING CREDIT BADGE (optional) */
.floating-credits {
    position: fixed;
    bottom: var(--space-4);
    right: var(--space-4);
    background: linear-gradient(135deg, var(--gray-900) 0%, var(--gray-700) 100%);
    color: var(--white);
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transition: var(--transition);
    opacity: 0.8;
    backdrop-filter: blur(10px);
}

.floating-credits:hover {
    opacity: 1;
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }
    
    .credits-team {
        flex-direction: column;
        gap: var(--space-4);
    }
    
    .team-member {
        min-width: auto;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .mini-credits {
        flex-direction: column;
        gap: var(--space-2);
    }
    
    .floating-credits {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: var(--space-4);
        text-align: center;
        border-radius: var(--radius-lg);
    }
    
    .app-footer {
        padding: var(--space-6) var(--space-4) var(--space-4);
        margin-top: var(--space-8);
    }
    
    .credits-section {
        padding: var(--space-4);
    }
    
    .member-avatar {
        width: 48px;
        height: 48px;
        font-size: var(--text-xl);
    }
    
    .credits-title {
        font-size: var(--text-base);
    }
    
    .member-name {
        font-size: var(--text-base);
    }
    
    .member-role {
        font-size: var(--text-xs);
    }
}

@media (max-width: 480px) {
    .app-footer {
        border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    }
}

/* FALLBACK FÜR FEHLENDE CSS VARIABLEN */
.app-footer {
    background: linear-gradient(135deg, #1f2937 0%, #374151 100%);
    color: #ffffff;
    padding: 2rem 1.5rem 1.5rem;
    margin-top: 4rem;
    border-radius: 1rem 1rem 0 0;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.member-avatar {
    background: linear-gradient(135deg, #3b82f6, #6366f1);
}

.credits-title {
    color: #ffffff;
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.member-name {
    color: #ffffff;
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.member-role {
    color: #d1d5db;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.member-description {
    color: #9ca3af;
    font-size: 0.75rem;
    margin-top: 0.5rem;
    line-height: 1.4;
}

.system-version {
    color: #d1d5db;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.copyright {
    color: #9ca3af;
    font-size: 0.75rem;
    opacity: 0.8;
}

/* PRINT STYLES */
@media print {
    .app-footer,
    .mini-footer,
    .floating-credits {
        display: none !important;
    }
}

/* DARK MODE ADJUSTMENTS */
@media (prefers-color-scheme: dark) {
    .mini-footer {
        background: #374151;
        border-top-color: #4b5563;
    }
    
    .mini-credits {
        color: #d1d5db;
    }
    
    .mini-credits .separator {
        color: #6b7280;
    }
}

/* =============================================================
   TRANSACTIONS PAGE - AUTOCOMPLETE & STEP INDICATOR CSS
   ============================================================= */

/* Autocomplete Styles */
.autocomplete-container {
    position: relative;
    width: 100%;
}

.autocomplete-input {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-xl);
    font-size: var(--text-base);
    transition: var(--transition);
    background: var(--white);
    font-weight: 500;
}

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

.autocomplete-input:disabled {
    background: var(--gray-100);
    color: var(--gray-500);
    cursor: not-allowed;
}

.autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 2px solid var(--primary);
    border-top: none;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    backdrop-filter: blur(10px);
}

.autocomplete-item {
    padding: 16px 20px;
    cursor: pointer;
    border-bottom: 1px solid var(--gray-200);
    transition: var(--transition-fast);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--white);
}

.autocomplete-item:hover,
.autocomplete-item.active {
    background: linear-gradient(135deg, var(--gray-50) 0%, #f0f9ff 100%);
    border-left: 4px solid var(--primary);
    padding-left: 16px;
}

.autocomplete-item:last-child {
    border-bottom: none;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
}

.item-info {
    flex: 1;
}

.item-name {
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 4px;
    font-size: var(--text-base);
}

.item-name strong {
    color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
    padding: 2px 4px;
    border-radius: 4px;
}

.item-category {
    font-size: var(--text-sm);
    color: var(--gray-600);
    font-weight: 500;
}

.item-stock {
    text-align: right;
    margin-left: 16px;
    min-width: 100px;
}

.stock-display {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.location-stock {
    font-weight: 800;
    font-size: var(--text-xl);
    display: flex;
    align-items: center;
    gap: 6px;
}

.location-stock.available {
    color: var(--success);
}

.location-stock.low {
    color: var(--warning);
}

.location-stock.empty {
    color: var(--danger);
}

.total-stock {
    font-size: var(--text-xs);
    color: var(--gray-500);
    font-weight: 500;
}

.stock-label {
    font-size: var(--text-xs);
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.loading-indicator {
    padding: 20px;
    text-align: center;
    color: var(--gray-500);
    font-style: italic;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-300);
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.no-results {
    padding: 20px;
    text-align: center;
    color: var(--gray-500);
    background: var(--white);
    font-style: italic;
}

.selected-article {
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    color: var(--white);
    padding: 12px 16px;
    border-radius: var(--radius-xl);
    margin-top: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    box-shadow: var(--shadow-md);
}

.clear-selection {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: var(--white);
    cursor: pointer;
    padding: 6px 10px;
    border-radius: var(--radius-full);
    transition: var(--transition-fast);
    font-weight: 700;
}

.clear-selection:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Step Indicator */
.step-indicator {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding: 16px;
    background: linear-gradient(135deg, var(--gray-50) 0%, #f0f9ff 100%);
    border-radius: var(--radius-xl);
    border: 1px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
}

.step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: var(--text-sm);
    transition: var(--transition);
    border: 2px solid transparent;
}

.step.completed {
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    color: var(--white);
    box-shadow: var(--shadow-sm);
}

.step.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    box-shadow: var(--shadow-md);
    transform: scale(1.05);
}

.step.inactive {
    background: var(--gray-300);
    color: var(--gray-600);
}

.step-arrow {
    color: var(--gray-400);
    font-size: var(--text-lg);
    font-weight: 700;
}

/* Form Sections */
.form-section {
    margin-bottom: 24px;
    padding: 24px;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-xl);
    transition: var(--transition);
    background: var(--white);
}

.form-section.active {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.02) 0%, var(--white) 100%);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.form-section.completed {
    border-color: var(--success);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.02) 0%, var(--white) 100%);
    opacity: 0.8;
}

.section-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-number {
    width: 40px;
    height: 40px;
    background: var(--gray-300);
    color: var(--gray-600);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: var(--text-base);
    transition: var(--transition);
}

.form-section.active .section-number {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.form-section.completed .section-number {
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    color: var(--white);
    box-shadow: var(--shadow-sm);
}

/* Location Helper */
.location-helper {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid var(--warning);
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    margin-top: 8px;
    font-size: var(--text-sm);
    color: #92400e;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Activities List (for Recent Transactions) */
.activities-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.activity-item {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4);
    background: var(--gray-50);
    border-radius: var(--radius-xl);
    border: 1px solid var(--gray-200);
    transition: var(--transition);
}

.activity-item:hover {
    background: var(--white);
    border-color: var(--primary);
    transform: translateX(4px);
    box-shadow: var(--shadow-sm);
}

.activity-type {
    font-size: var(--text-2xl);
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    background: rgba(0,0,0,0.05);
}

.activity-type.type-in {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(5, 150, 105, 0.1));
    color: var(--success);
}

.activity-type.type-out {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(220, 38, 38, 0.1));
    color: var(--danger);
}

.activity-type.type-transfer {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(37, 99, 235, 0.1));
    color: var(--primary);
}

.activity-details {
    flex: 1;
    font-size: var(--text-sm);
    line-height: 1.5;
}

.activity-details strong {
    color: var(--gray-900);
    font-weight: 600;
}

.activity-details small {
    display: block;
    color: var(--gray-500);
    margin-top: var(--space-1);
    font-size: var(--text-xs);
}

/* Responsive Design für Transactions */
@media (max-width: 768px) {
    .step-indicator {
        flex-direction: column;
        gap: var(--space-3);
        text-align: center;
    }
    
    .step-arrow {
        transform: rotate(90deg);
    }
    
    .form-section {
        padding: var(--space-4);
    }
    
    .section-title {
        flex-direction: column;
        text-align: center;
        gap: var(--space-3);
    }
    
    .section-number {
        width: 32px;
        height: 32px;
        font-size: var(--text-sm);
    }
    
    .autocomplete-dropdown {
        max-height: 250px;
    }
    
    .item-stock {
        margin-left: var(--space-3);
        min-width: 80px;
    }
    
    .location-stock {
        font-size: var(--text-base);
    }
    
    .activity-item {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-3);
        text-align: left;
    }
    
    .activity-type {
        width: 40px;
        height: 40px;
        font-size: var(--text-xl);
    }
}

@media (max-width: 480px) {
    .step {
        flex-direction: column;
        padding: var(--space-2) var(--space-3);
        font-size: var(--text-xs);
    }
    
    .autocomplete-item {
        padding: 12px 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-2);
    }
    
    .item-stock {
        margin-left: 0;
        align-self: flex-end;
    }
    
    .form-section {
        padding: var(--space-3);
    }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    .step,
    .form-section,
    .autocomplete-item,
    .activity-item {
        transition: none;
    }
    
    .loading-spinner {
        animation: none;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .autocomplete-dropdown {
        border-width: 3px;
    }
    
    .autocomplete-item.active {
        border-left-width: 6px;
    }
    
    .step.active,
    .step.completed {
        border: 3px solid var(--white);
    }
}

/* Print Styles für Transactions */
@media print {
    .step-indicator,
    .form-section:not(.completed),
    .activity-item .activity-type {
        display: none;
    }
    
    .form-section.completed {
        border: 1px solid #000;
        break-inside: avoid;
    }
}

/* Fallback für fehlende CSS-Variablen */
:root {
    --primary: #3b82f6;
    --primary-dark: #2563eb;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-900: #111827;
    --white: #ffffff;
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --radius-lg: 0.5rem;
    --radius-xl: 0.75rem;
    --radius-full: 9999px;
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --transition-fast: all 0.15s ease;
}

/* =============================================================
   BARCODE SCANNER UI STYLES
   ============================================================= */

/* Scanner Status Indicator */
.scanner-status {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    pointer-events: none;
}

.scanner-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    font-weight: 500;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.scanner-indicator.zebra {
    background: linear-gradient(135deg, #ff6b35, #f7931e);
}

.scanner-indicator.datalogic {
    background: linear-gradient(135deg, #0066cc, #004499);
}

.scanner-indicator.keyboard {
    background: linear-gradient(135deg, #6b7280, #374151);
}

.scanner-indicator.camera {
    background: linear-gradient(135deg, #10b981, #059669);
}

.scanner-indicator.scanning {
    animation: scannerPulse 1s ease-in-out;
}

@keyframes scannerPulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);
    }
}

.scanner-pulse {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: scannerSweep 2s infinite;
}

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

.scanner-icon {
    font-size: var(--text-lg);
}

.scanner-text {
    font-weight: 600;
}

/* Scanner Button */
.btn-scanner {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-lg);
    font-size: var(--text-sm);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 8px;
}

.btn-scanner:hover {
    background: linear-gradient(135deg, #2563eb, #1e40af);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

/* Camera Scanner Modal */
.camera-scanner-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(5px);
}

.scanner-modal-content {
    background: white;
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-2xl);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.scanner-header {
    background: linear-gradient(135deg, #1f2937, #374151);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.scanner-header h3 {
    font-size: var(--text-xl);
    font-weight: 600;
    margin: 0;
}

.close-scanner {
    background: none;
    border: none;
    color: white;
    font-size: var(--text-xl);
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

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

.scanner-body {
    position: relative;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

#scanner-video {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
}

.scanner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    pointer-events: none;
}

.scanner-frame {
    width: 200px;
    height: 200px;
    border: 3px solid #00ff00;
    border-radius: var(--radius-lg);
    position: relative;
    animation: scannerFrame 2s infinite;
}

.scanner-frame::before,
.scanner-frame::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 3px solid #00ff00;
}

.scanner-frame::before {
    top: -3px;
    left: -3px;
    border-right: none;
    border-bottom: none;
}

.scanner-frame::after {
    bottom: -3px;
    right: -3px;
    border-left: none;
    border-top: none;
}

@keyframes scannerFrame {
    0%, 100% {
        border-color: #00ff00;
        box-shadow: 0 0 20px rgba(0, 255, 0, 0.5);
    }
    50% {
        border-color: #00ccff;
        box-shadow: 0 0 30px rgba(0, 204, 255, 0.7);
    }
}

.scanner-instructions {
    color: white;
    text-align: center;
    margin-top: 20px;
    font-size: var(--text-sm);
    background: rgba(0, 0, 0, 0.7);
    padding: 8px 16px;
    border-radius: var(--radius-full);
}

.scanner-controls {
    padding: 20px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    border-top: 1px solid var(--gray-200);
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 10000;
    pointer-events: none;
}

.toast {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    margin-bottom: 12px;
    transform: translateX(100%);
    animation: toastSlideIn 0.3s ease forwards;
    pointer-events: all;
    border-left: 4px solid var(--primary);
    max-width: 400px;
}

.toast-success {
    border-left-color: var(--success);
}

.toast-error {
    border-left-color: var(--danger);
}

.toast-warning {
    border-left-color: var(--warning);
}

.toast-info {
    border-left-color: var(--primary);
}

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

.toast-content {
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.toast-message {
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--gray-800);
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    font-size: var(--text-sm);
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    flex-shrink: 0;
}

.toast-close:hover {
    background: var(--gray-100);
    color: var(--gray-600);
}

/* Search Field Scanner Integration */
.search-input-container,
.autocomplete-container {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-container .btn-scanner,
.autocomplete-container .btn-scanner {
    margin-left: 8px;
    flex-shrink: 0;
}

/* Scanner Success Highlight */
.scanner-highlight {
    animation: scannerHighlight 1s ease;
}

@keyframes scannerHighlight {
    0% { 
        background: var(--success);
        color: white;
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
    100% {
        background: initial;
        color: initial;
        transform: scale(1);
    }
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .scanner-status {
        top: 10px;
        right: 10px;
    }
    
    .scanner-indicator {
        font-size: var(--text-xs);
        padding: 6px 12px;
    }
    
    .scanner-modal-content {
        width: 95%;
        margin: 10px;
    }
    
    .scanner-frame {
        width: 150px;
        height: 150px;
    }
    
    .toast-container {
        top: 70px;
        right: 10px;
        left: 10px;
    }
    
    .toast {
        max-width: none;
    }
    
    .btn-scanner {
        padding: 6px 12px;
        font-size: var(--text-xs);
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .scanner-indicator {
        border: 2px solid white;
    }
    
    .toast {
        border: 2px solid var(--gray-800);
    }
    
    .scanner-frame {
        border-width: 4px;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .scanner-indicator.scanning,
    .scanner-pulse,
    .scanner-frame,
    .toast {
        animation: none;
    }
    
    .scanner-highlight {
        animation: none;
        background: var(--success);
        color: white;
    }
}

/* Print Styles - Hide Scanner UI */
@media print {
    .scanner-status,
    .toast-container,
    .camera-scanner-modal,
    .btn-scanner {
        display: none !important;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .scanner-modal-content {
        background: var(--gray-800);
        color: white;
    }
    
    .scanner-controls {
        border-top-color: var(--gray-600);
    }
    
    .toast {
        background: var(--gray-800);
        color: white;
    }
    
    .toast-message {
        color: white;
    }
    
    .toast-close {
        color: var(--gray-400);
    }
    
    .toast-close:hover {
        background: var(--gray-700);
        color: var(--gray-200);
    }
}

/* Loading States */
.scanner-loading {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}

.scanner-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Pagination Styles */
.pagination-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    background: #f8fafc;
    border-top: 2px solid #e2e8f0;
    flex-wrap: wrap;
    gap: 15px;
}

.pagination-info {
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 2px solid #e5e7eb;
    background: white;
    color: #374151;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.pagination-btn:hover:not(.pagination-disabled):not(.pagination-current) {
    background: #f3f4f6;
    border-color: #d1d5db;
    transform: translateY(-1px);
    text-decoration: none;
}

.pagination-current {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
    border-color: #8b5cf6;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.pagination-disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f9fafb;
    color: #9ca3af;
}

.pagination-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: #9ca3af;
    font-weight: bold;
}

.pagination-per-page {
    display: flex;
    align-items: center;
    gap: 8px;
}

.per-page-select {
    padding: 8px 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    background: white;
    font-size: 0.9rem;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
}

.per-page-select:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.pagination-section {
    background: white;
    border-radius: 0 0 20px 20px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}

/* Responsive Pagination */
@media (max-width: 768px) {
    .pagination-container {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }
    
    .pagination-controls {
        order: 2;
        margin: 15px 0;
    }
    
    .pagination-info {
        order: 1;
        margin-bottom: 10px;
    }
    
    .pagination-per-page {
        order: 3;
    }
    
    .pagination-btn {
        width: 36px;
        height: 36px;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .pagination-controls {
        gap: 2px;
    }
    
    .pagination-btn {
        width: 32px;
        height: 32px;
        font-size: 0.75rem;
    }
    
    /* Hide some navigation on very small screens */
    .pagination-first,
    .pagination-last {
        display: none;
    }
}

/* Loading states */
.pagination-loading {
    opacity: 0.6;
    pointer-events: none;
}

.pagination-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #e5e7eb;
    border-top: 2px solid #8b5cf6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Live Search Styles */
.live-search-container {
    background: white;
    border-radius: 16px;
    padding: 25px;
    margin: 20px 0;
    box-shadow: 0 8px 32px rgba(0,0,0,0.08);
    border: 1px solid #f1f5f9;
}

.live-search-header {
    text-align: center;
    margin-bottom: 20px;
}

.live-search-header h3 {
    margin: 0 0 8px 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
}

.live-search-header p {
    margin: 0;
    color: #6b7280;
    font-size: 1rem;
}

.live-search-input-wrapper {
    position: relative;
    margin-bottom: 20px;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: #9ca3af;
    z-index: 2;
}

.live-search-input {
    width: 100%;
    padding: 16px 20px 16px 50px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    background: white;
    box-sizing: border-box;
}

.live-search-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.live-search-input.searching {
    border-color: #f59e0b;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.1);
}

.search-loader {
    position: absolute;
    right: 50px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.clear-search-btn {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.clear-search-btn:hover {
    background: #dc2626;
    transform: translateY(-50%) scale(1.1);
}

.live-search-results {
    max-height: 400px;
    overflow-y: auto;
    border: 2px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 12px 12px;
    background: white;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    z-index: 1000;
}

.search-result-item {
    padding: 16px 20px;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.search-result-item:hover,
.search-result-item.active {
    background: #f0f9ff;
    border-color: #bae6fd;
}

.search-result-item:last-child {
    border-bottom: none;
}

.result-info {
    flex: 1;
}

.result-name {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
    font-size: 1rem;
}

.result-meta {
    font-size: 0.9rem;
    color: #6b7280;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.result-stock {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.stock-quantity {
    font-weight: 700;
    font-size: 1.2rem;
    padding: 4px 8px;
    border-radius: 8px;
    min-width: 50px;
    text-align: center;
}

.stock-quantity.good {
    background: #dcfce7;
    color: #166534;
}

.stock-quantity.low {
    background: #fef3c7;
    color: #92400e;
}

.stock-quantity.critical {
    background: #fee2e2;
    color: #991b1b;
}

.stock-quantity.out-of-stock {
    background: #fee2e2;
    color: #991b1b;
    font-weight: 800;
}

.stock-label {
    font-size: 0.75rem;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.no-results {
    padding: 40px 20px;
    text-align: center;
    color: #6b7280;
}

.no-results-icon {
    font-size: 3rem;
    margin-bottom: 12px;
    opacity: 0.5;
}

.no-results-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.no-results-text {
    font-size: 0.9rem;
    line-height: 1.5;
}

.live-search-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid #f1f5f9;
    flex-wrap: wrap;
    gap: 12px;
}

.filter-chip-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-chip-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #374151;
}

.filter-chip-select {
    padding: 6px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: white;
    font-size: 0.9rem;
    color: #374151;
    cursor: pointer;
}

.filter-chip-select:focus {
    outline: none;
    border-color: #3b82f6;
}

.search-stats {
    font-size: 0.9rem;
    color: #6b7280;
    font-weight: 500;
}

.search-highlight {
    background: #fef3c7;
    color: #92400e;
    padding: 1px 3px;
    border-radius: 3px;
    font-weight: 600;
}

/* Responsive Live Search */
@media (max-width: 768px) {
    .live-search-container {
        padding: 20px 15px;
        margin: 15px 0;
    }
    
    .live-search-input {
        padding: 14px 16px 14px 45px;
        font-size: 1rem;
    }
    
    .search-icon {
        left: 14px;
        font-size: 1rem;
    }
    
    .search-result-item {
        padding: 12px 16px;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .result-stock {
        align-items: flex-start;
        flex-direction: row;
        justify-content: space-between;
    }
    
    .live-search-filters {
        flex-direction: column;
        align-items: stretch;
    }
}

@media (max-width: 480px) {
    .result-meta {
        flex-direction: column;
        gap: 4px;
    }
    
    .stock-quantity {
        font-size: 1rem;
    }
}

/* Enhanced Search Results with Actions */
.search-result-item {
    padding: 16px 20px;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
    transition: all 0.2s ease;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 16px;
    align-items: center;
}

.search-result-item:hover,
.search-result-item.active {
    background: #f0f9ff;
    border-color: #bae6fd;
    transform: translateX(4px);
}

.result-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 140px;
}

.quick-checkout-btn,
.asset-details-btn {
    padding: 8px 12px;
    border: none;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    white-space: nowrap;
}

.quick-checkout-btn {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.quick-checkout-btn:hover:not(.disabled) {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.quick-checkout-btn.disabled {
    background: #e5e7eb;
    color: #9ca3af;
    cursor: not-allowed;
    box-shadow: none;
}

.asset-details-btn {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.asset-details-btn:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
    transform: translateY(-1px);
}

/* Keyboard navigation highlight */
.search-result-item.active .quick-checkout-btn:not(.disabled) {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.3);
}

/* Loading state for buttons */
.quick-checkout-btn:disabled {
    opacity: 0.7;
    cursor: wait;
}

/* Responsive actions */
@media (max-width: 768px) {
    .search-result-item {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .result-actions {
        flex-direction: row;
        justify-content: space-between;
        min-width: auto;
    }
    
    .quick-checkout-btn,
    .asset-details-btn {
        flex: 1;
        font-size: 0.8rem;
        padding: 6px 8px;
    }
}

@media (max-width: 480px) {
    .result-actions {
        flex-direction: column;
    }
    
    .quick-checkout-btn,
    .asset-details-btn {
        width: 100%;
    }
}

/* Enhanced status indicators */
.result-stock {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    min-width: 80px;
}

/* Animation for successful actions */
@keyframes checkoutSuccess {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); background: #22c55e; }
    100% { transform: scale(1); }
}

.quick-checkout-btn.success {
    animation: checkoutSuccess 0.6s ease-out;
}

/* Enhanced Action Buttons */
.actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin: 25px 0;
    padding: 20px;
    background: #f8fafc;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
}

.actions .btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    min-height: 80px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.actions .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.actions .btn:hover::before {
    left: 100%;
}

.actions .btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.15);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
    box-shadow: 0 12px 32px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
    box-shadow: 0 8px 24px rgba(107, 114, 128, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #4b5563 0%, #374151 100%);
    box-shadow: 0 12px 32px rgba(107, 114, 128, 0.4);
}

.btn-admin {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.3);
}

.btn-admin:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.4);
}

.btn-warning {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.3);
    animation: pulse-warning 2s infinite;
}

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

.btn-warning:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 12px 32px rgba(239, 68, 68, 0.4);
    animation: none;
}

.btn-success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    box-shadow: 0 8px 24px rgba(34, 197, 94, 0.3);
}

.btn-success:hover {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    box-shadow: 0 12px 32px rgba(34, 197, 94, 0.4);
}

/* Responsive Actions */
@media (max-width: 768px) {
    .actions {
        grid-template-columns: 1fr;
        padding: 15px;
        gap: 12px;
    }
    
    .actions .btn {
        padding: 16px;
        min-height: 70px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .actions .btn {
        padding: 14px;
        min-height: 60px;
        font-size: 0.9rem;
    }
    
    .actions .btn small {
        font-size: 0.7rem !important;
    }
}