:root {
    --primary-color: #4a6fa5;
    --secondary-color: #6b96c9;
    --accent-color: #ff9f43;
    --text-color: #333;
    --background-color: #f8f9fa;
    --card-color: #ffffff;
    --border-color: #e0e0e0;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --input-bg: #ffffff;
    --success-color: #28a745;
    --error-color: #dc3545;
    --transition-speed: 0.3s;
}

.dark-theme {
    --primary-color: #5d87c3;
    --secondary-color: #3b5998;
    --accent-color: #ffa752;
    --text-color: #f1f1f1;
    --background-color: #121212;
    --card-color: #1e1e1e;
    --border-color: #333333;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --input-bg: #2c2c2c;
    --success-color: #2ecc71;
    --error-color: #e74c3c;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
    height: 100%;
    display: flex;
    flex-direction: column;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    animation: fadeInUp 1s ease-out;
}

.theme-switch {
    position: relative;
    width: 60px;
    height: 30px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-label {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--secondary-color);
    border-radius: 30px;
    transition: .4s;
}

.toggle-label:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    border-radius: 50%;
    transition: .4s;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23FFC107" width="16px" height="16px"><path d="M0 0h24v24H0z" fill="none"/><path d="M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zM2 13h2c.55 0 1-.45 1-1s-.45-1-1-1H2c-.55 0-1 .45-1 1s.45 1 1 1zm18 0h2c.55 0 1-.45 1-1s-.45-1-1-1h-2c-.55 0-1 .45-1 1s.45 1 1 1zM11 2v2c0 .55.45 1 1 1s1-.45 1-1V2c0-.55-.45-1-1-1s-1 .45-1 1zm0 18v2c0 .55.45 1 1 1s1-.45 1-1v-2c0-.55-.45-1-1-1s-1 .45-1 1zM5.99 4.58c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0 .39-.39.39-1.03 0-1.41L5.99 4.58zm12.37 12.37c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0 .39-.39.39-1.03 0-1.41l-1.06-1.06zm1.06-10.96c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41.39.39 1.03.39 1.41 0l1.06-1.06zM7.05 18.36c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41.39.39 1.03.39 1.41 0l1.06-1.06z"/></svg>');
    background-position: center;
    background-repeat: no-repeat;
}

input:checked + .toggle-label {
    background-color: var(--primary-color);
}

input:checked + .toggle-label:before {
    transform: translateX(30px);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23121212" width="16px" height="16px"><path d="M0 0h24v24H0z" fill="none"/><path d="M12.7 4.91C15.25 6.24 17 8.92 17 12s-1.75 5.76-4.3 7.09c1.46-2 2.3-4.46 2.3-7.09s-.84-5.09-2.3-7.09M9 2c-1.05 0-2.05.16-3 .46 4.06 1.27 7 5.06 7 9.54s-2.94 8.27-7 9.54c.95.3 1.95.46 3 .46 5.52 0 10-4.48 10-10S14.52 2 9 2z"/></svg>');
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.welcome-message {
    animation: fadeIn 1.5s ease;
}

.welcome-message h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.welcome-message p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.8;
}

.hidden {
    display: none;
}

.active {
    display: flex;
}

#start-screen {
    cursor: pointer;
    position: relative;
    height: 100%;
    width: 100%;
}

#main-menu {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    padding: 2rem;
    width: 100%;
}

.menu-option {
    background-color: var(--card-color);
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 4px 15px var(--shadow-color);
    width: 100%;
    max-width: 500px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    animation: slideInUp 0.5s forwards;
    opacity: 0;
}

.menu-option:nth-child(1) {
    animation-delay: 0.1s;
}

.menu-option:nth-child(2) {
    animation-delay: 0.3s;
}

.menu-option:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px var(--shadow-color);
}

.menu-option h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.menu-option p {
    color: var(--text-color);
    opacity: 0.8;
}

/* Formulare */
form {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    animation: fadeIn 0.8s;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

input[type="text"],
input[type="number"],
select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    background-color: var(--input-bg);
    color: var(--text-color);
    font-size: 1rem;
}

button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background-color 0.3s;
}

button:hover {
    background-color: var(--secondary-color);
}

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

.button-accent {
    background-color: var(--accent-color);
}

.button-group {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

/* Produkteliste */
.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
    width: 100%;
}

.product-card {
    background-color: var(--card-color);
    border-radius: 8px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px var(--shadow-color);
    animation: fadeIn 0.5s forwards;
    opacity: 0;
}

.product-card:nth-child(3n+1) {
    animation-delay: 0.1s;
}

.product-card:nth-child(3n+2) {
    animation-delay: 0.2s;
}

.product-card:nth-child(3n+3) {
    animation-delay: 0.3s;
}

.product-name {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.product-price {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.product-quantity {
    display: flex;
    align-items: center;
    margin-top: auto;
}

.quantity-btn {
    width: 30px;
    height: 30px;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.quantity-input {
    width: 50px;
    text-align: center;
    margin: 0 0.5rem;
}

/* QR Code */
.qr-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 2rem 0;
    animation: fadeIn 1s;
}

.receipt-details {
    margin: 2rem 0;
    width: 100%;
    max-width: 600px;
    background-color: var(--card-color);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 15px var(--shadow-color);
}

.receipt-details h3 {
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.receipt-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.receipt-total {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    font-weight: 700;
    font-size: 1.2rem;
    display: flex;
    justify-content: space-between;
}

/* Animationen */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

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

/* Responsivität */
@media (max-width: 768px) {
    .logo {
        font-size: 2rem;
    }
    
    .menu-option {
        padding: 1.5rem;
    }
    
    .welcome-message h2 {
        font-size: 2rem;
    }
    
    .receipt-details {
        padding: 1.5rem;
    }
}

/* Ladeindikator */
.loading-indicator {
    text-align: center;
    padding: 20px;
    color: var(--text-color);
    position: relative;
}

.loading-indicator::after {
    content: "";
    display: block;
    width: 30px;
    height: 30px;
    border: 3px solid var(--primary-color);
    border-radius: 50%;
    border-top-color: transparent;
    margin: 10px auto 0;
    animation: spin 1s linear infinite;
}

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

/* Leere Zustände */
.empty-state {
    text-align: center;
    padding: 30px;
    color: var(--text-color);
    opacity: 0.7;
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    margin: 20px 0;
}

/* Produktbearbeitung */
.product-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    background-color: var(--card-color);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 2px 5px var(--shadow-color);
    position: relative;
    animation: fadeIn 0.5s ease-in-out;
}

.product-row .form-group {
    flex: 1;
    min-width: 150px;
}

.product-row .remove-product-btn {
    background-color: var(--error-color);
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    align-self: center;
    transition: background-color 0.3s;
}

.product-row .remove-product-btn:hover {
    background-color: #c82333;
} 