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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #2d3748;
    font-size: 14px;
    line-height: 1.6;
}

/* Login Page */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.login-box {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 400px;
    width: 100%;
}

.login-box h1 {
    text-align: center;
    color: #667eea;
    margin-bottom: 10px;
    font-size: 32px;
}

.login-subtitle {
    text-align: center;
    color: #718096;
    margin-bottom: 30px;
    font-size: 16px;
}

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

.login-box .form-group {
    display: flex;
    flex-direction: column;
}

.login-box .form-group label {
    margin-bottom: 8px;
    color: #4a5568;
    font-weight: 500;
    font-size: 14px;
}

.login-box .form-group input {
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.login-box .form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.login-box .btn {
    margin-top: 10px;
    width: 100%;
    text-align: center;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #FFFFFF;
    padding: 24px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left h1 {
    font-size: 36px;
    color: #FFFFFF;
    margin: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

#usernameDisplay {
    color: #FFFFFF;
    font-weight: 500;
}

main {
    padding: 32px;
}

.section {
    margin-bottom: 40px;
}

.section h2 {
    font-size: 24px;
    color: #2d3748;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e2e8f0;
}

/* Forms */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    align-items: end;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 8px;
    color: #4a5568;
    font-weight: 500;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-btn {
    background: none;
    border: none;
    color: #667eea;
    font-size: 16px;
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    font-weight: normal;
    line-height: 1;
    flex-shrink: 0;
}

.info-btn:hover {
    background: #e2e8f0;
    transform: scale(1.1);
}

.info-btn:active {
    transform: scale(0.95);
}

.form-group input,
.form-group select {
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #FFFFFF;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #e2e8f0;
    color: #4a5568;
}

.btn-secondary:hover {
    background: #cbd5e0;
}

.btn-danger {
    background: #fc8181;
    color: #FFFFFF;
}

.btn-danger:hover {
    background: #f56565;
}

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

/* Events List */
.events-list {
    display: grid;
    gap: 20px;
}

.event-card {
    background: #FFFFFF;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.2s;
}

.event-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.event-card.clickable {
    cursor: pointer;
}

.event-card.clickable:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.event-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 15px;
}

.event-title {
    font-size: 18px;
    font-weight: 600;
    color: #2d3748;
}

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

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

.event-detail-item {
    display: flex;
    flex-direction: column;
}

.event-detail-label {
    font-size: 12px;
    color: #718096;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.event-detail-value {
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.event-detail-value.positive {
    color: #48bb78;
}

.event-detail-value.negative {
    color: #f56565;
}

.empty-message {
    text-align: center;
    color: #718096;
    padding: 40px;
    font-size: 16px;
}

/* Wizard Styles */
.wizard-container {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 32px;
}

.wizard-header {
    margin-bottom: 32px;
}

.wizard-header h2 {
    margin-bottom: 24px;
    color: #2d3748;
    font-size: 28px;
}

.wizard-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    margin-bottom: 40px;
}

.wizard-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e2e8f0;
    z-index: 0;
}

.wizard-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
    flex: 1;
}

.wizard-step.clickable {
    cursor: pointer;
}

.wizard-step.clickable:hover .step-number {
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #718096;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 8px;
    transition: all 0.3s;
}

.wizard-step.active .step-number {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #FFFFFF;
    transform: scale(1.1);
}

.wizard-step.completed .step-number {
    background: #48bb78;
    color: #FFFFFF;
}

.step-label {
    font-size: 12px;
    color: #718096;
    text-align: center;
    font-weight: 500;
}

.wizard-step.active .step-label {
    color: #667eea;
    font-weight: 600;
}

.wizard-step-content {
    max-width: 800px;
    margin: 0 auto;
}

.wizard-step-content h3 {
    font-size: 24px;
    color: #2d3748;
    margin-bottom: 24px;
}

.wizard-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 32px;
    gap: 15px;
}

/* Responsibles List */
.responsibles-list {
    margin: 24px 0;
    min-height: 100px;
}

.responsible-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 10px;
}

.responsible-item span {
    font-size: 14px;
    color: #2d3748;
    font-weight: 500;
}

/* Expenses List */
.expenses-list {
    margin: 24px 0;
    min-height: 100px;
}

.expense-item {
    display: flex;
    justify-content: space-between;
    align-items: start;
    padding: 16px;
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 15px;
    transition: all 0.2s;
}

.expense-item:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.expense-info {
    flex: 1;
}

.expense-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.expense-name {
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.expense-category {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.expense-category[data-category="Getränke"] {
    background: #bee3f8;
    color: #2c5282;
}

.expense-category[data-category="Speisen"] {
    background: #feb2b2;
    color: #742a2a;
}

.expense-category[data-category="Sonstige"] {
    background: #c6f6d5;
    color: #22543d;
}

.expense-category[data-category="Ausgabe ohne Einnahme"] {
    background: #e2e8f0;
    color: #2d3748;
}

/* Expense Category Groups */
.expense-category-group {
    margin-bottom: 32px;
}

.expense-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px 8px 0 0;
    margin-bottom: 0;
}

.expense-category-title {
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    margin: 0;
}

.expense-category-total {
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
}

.expense-category-items {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding: 16px;
}

.expense-category-items .expense-item {
    margin-bottom: 12px;
    background: #f7fafc;
}

.expense-category-items .expense-item:last-child {
    margin-bottom: 0;
}

/* Expenses Income List (Step 4) */
.expenses-income-list {
    margin: 24px 0;
    min-height: 100px;
}

/* Expense Income Category Groups */
.expense-income-category-group {
    margin-bottom: 32px;
}

.expense-income-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px 8px 0 0;
    margin-bottom: 0;
}

.expense-income-category-header .expense-income-category-title {
    font-size: 18px;
    font-weight: 600;
    color: #ffffff !important;
    margin: 0;
}

.expense-income-category-header .expense-income-category-total {
    font-size: 16px;
    font-weight: 600;
    color: #ffffff !important;
}

.expense-income-category-items {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding: 16px;
}

.expense-income-category-items .expense-income-item {
    margin-bottom: 12px;
}

.expense-income-category-items .expense-income-item:last-child {
    margin-bottom: 0;
}

.expense-income-item {
    display: flex;
    justify-content: space-between;
    align-items: start;
    padding: 16px;
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 15px;
    transition: all 0.2s;
}

.expense-income-item:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.expense-income-info {
    flex: 1;
}

.expense-income-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.expense-income-name {
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.expense-income-details {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #4a5568;
}

.expense-income-input {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-left: 16px;
    min-width: 200px;
}

.expense-income-input label {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 12px;
    color: #4a5568;
}

.selling-price-input {
    padding: 8px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
}

.selling-price-input:focus {
    outline: none;
    border-color: #667eea;
}

/* Income Without Expense List */
.income-without-expense-list {
    margin: 24px 0;
    min-height: 100px;
}

.income-item {
    display: flex;
    justify-content: space-between;
    align-items: start;
    padding: 16px;
    background: #f0fff4;
    border: 2px solid #c6f6d5;
    border-radius: 8px;
    margin-bottom: 15px;
    transition: all 0.2s;
}

.income-item:hover {
    border-color: #48bb78;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.income-info {
    flex: 1;
}

.income-header {
    margin-bottom: 12px;
}

.income-name {
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
}

.income-details {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #4a5568;
}

.income-actions {
    display: flex;
    gap: 8px;
    margin-left: 16px;
}

.wizard-step-content .section {
    margin-bottom: 32px;
}

.wizard-step-content .section h4 {
    font-size: 18px;
    color: #2d3748;
    margin-bottom: 12px;
}

.expense-details {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #4a5568;
}

.expense-details span {
    display: flex;
    align-items: center;
}

.expense-actions {
    display: flex;
    gap: 8px;
    margin-left: 16px;
}

/* Summary Box */
.summary-box {
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 32px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
}

.summary-item {
    display: flex;
    flex-direction: column;
}

.summary-label {
    font-size: 12px;
    color: #718096;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.summary-value {
    font-size: 24px;
    font-weight: 700;
    color: #2d3748;
    font-family: monospace;
}

.summary-value.positive {
    color: #48bb78;
}

.summary-value.negative {
    color: #f56565;
}

/* Error Message */
.error-message {
    background: #fed7d7;
    color: #c53030;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 14px;
}

/* Success Message */
.success-message {
    background: #c6f6d5;
    color: #22543d;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .event-details {
        grid-template-columns: 1fr;
    }
    
    header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .header-right {
        flex-direction: column;
        width: 100%;
    }
    
    .wizard-steps {
        flex-direction: column;
        gap: 20px;
    }
    
    .wizard-steps::before {
        display: none;
    }
    
    .wizard-step {
        width: 100%;
    }
    
    .expense-item {
        flex-direction: column;
        gap: 12px;
    }
    
    .expense-actions {
        margin-left: 0;
        width: 100%;
        justify-content: flex-end;
    }
    
    .summary-box {
        grid-template-columns: 1fr;
    }
}

/* Info Modal */
.info-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.info-modal-content {
    background-color: #FFFFFF;
    margin: 15% auto;
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
}

.info-modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 20px;
    top: 20px;
    line-height: 1;
}

.info-modal-close:hover {
    color: #000;
}

.info-modal-content h3 {
    margin-bottom: 15px;
    color: #2d3748;
    font-size: 20px;
}

.info-modal-content p {
    color: #4a5568;
    line-height: 1.6;
    font-size: 14px;
}

