:root {
    --primary: #5c67f2;
    --primary-hover: #4a54d1;
    --secondary: #6c757d;
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --card-header: #2d3748;
    --text-color: #f8fafc;
    --text-muted: #94a3b8;
    --border-color: #334155;
    --leicht: #10b981;
    --mittel: #f59e0b;
    --schwer: #ef4444;
    --radius: 16px;
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

h1, h2, h3 {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
}

[v-cloak] { display: none !important; }

/* Transitions */
.fade-enter-active, .fade-leave-active { transition: opacity 0.3s ease; }
.fade-enter-from, .fade-leave-to { opacity: 0; }
.list-enter-active, .list-leave-active { transition: all 0.5s ease; }
.list-enter-from, .list-leave-to { opacity: 0; transform: translateY(20px); }

/* Login Screen Styles */
#login-screen {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 1.5rem;
}
.login-card {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: 24px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.4);
    width: 100%;
    max-width: 420px;
    text-align: center;
    border: 1px solid var(--border-color);
}
.login-logo {
    width: 140px;
    height: auto;
    margin-bottom: 1.5rem;
}
.login-card h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.login-card p { color: var(--text-muted); margin-bottom: 2rem; }

.login-card form { display: flex; flex-direction: column; gap: 1.5rem; }

.login-card input[type="password"] {
    width: 100%;
    padding: 1.2rem;
    font-size: 1.2rem;
    border-radius: 16px;
    border: 2px solid var(--border-color);
    background: rgba(15, 23, 42, 0.6);
    color: white;
    text-align: center;
    transition: border-color 0.3s, box-shadow 0.3s;
}
.login-card input[type="password"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(92, 103, 242, 0.2);
}

/* Header & Navigation */
header {
    background-color: var(--card-bg);
    padding: 1.5rem 1rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
    border-bottom: 1px solid var(--border-color);
}
.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.header-logo { width: 63px; height: auto; }
header h1 { font-size: 1.8rem; letter-spacing: -0.02em; color: white; }

nav {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    background: rgba(15, 23, 42, 0.5);
    padding: 0.5rem;
    border-radius: 16px;
    max-width: 480px;
    margin: 0 auto;
}
nav button {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 0.8rem 1rem;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s;
    font-size: 0.95rem;
}
nav button.active {
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(92, 103, 242, 0.4);
}

/* Base Buttons */
.primary-btn, .secondary-btn, .danger-btn {
    padding: 1rem 1.5rem;
    border-radius: 14px;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    font-size: 1rem;
}
.primary-btn { background: var(--primary); color: white; box-shadow: 0 4px 14px rgba(92, 103, 242, 0.3); }
.primary-btn:hover { background: var(--primary-hover); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(92, 103, 242, 0.4); }
.primary-btn:active { transform: translateY(0) scale(0.98); }

.secondary-btn { background: var(--border-color); color: white; }
.danger-btn { background: rgba(239, 68, 68, 0.1); color: var(--schwer); border: 1px solid var(--schwer); }

/* Main Content */
main { padding: 2rem 1rem; max-width: 1100px; margin: 0 auto; }
h2 { margin-bottom: 1.5rem; font-size: 1.8rem; }

/* Modern Generator Config */
.config-card {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    margin-bottom: 3rem;
    box-shadow: var(--shadow);
}
.config-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2.5rem;
}
.config-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.config-item:last-child { border-bottom: none; }
.config-item label { font-weight: 700; font-size: 1.1rem; }

.modern-counter {
    display: flex;
    align-items: center;
    gap: 0;
    background: rgba(15, 23, 42, 0.8);
    padding: 0.3rem;
    border-radius: 30px;
    border: 1px solid var(--border-color);
}
.modern-counter button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    transition: background 0.2s;
}
.modern-counter button:hover { background: rgba(255,255,255,0.1); }
.modern-counter input {
    width: 45px;
    text-align: center;
    background: none;
    border: none;
    color: white;
    font-size: 1.1rem;
    font-weight: 800;
}

/* Stats Bar */
.stats-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem; /* Abstand zwischen den Countern */
    margin-bottom: 2rem;
    font-size: 1.05rem;
    font-weight: 700;
    background: rgba(15, 23, 42, 0.3);
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    width: fit-content;
}

.manage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
.manage-header h2 { margin-bottom: 0; }

/* Filter Bar Modern */
.filter-bar {
    display: flex;
    gap: 1rem;
    margin-top: 1rem; /* Platz nach oben zum Header */
    margin-bottom: 2rem;
    background: rgba(15, 23, 42, 0.4);
    padding: 0.8rem;
    border-radius: 18px;
    border: 1px solid var(--border-color);
}
.filter-bar input, .filter-bar select {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: white;
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    font-size: 1rem;
    flex: 1;
    min-width: 0;
    transition: all 0.3s;
}
.filter-bar select {
    flex: 0 0 180px;
    cursor: pointer;
}
.filter-bar input:focus, .filter-bar select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(92, 103, 242, 0.1);
}

/* Cards */
.results-grid, .manage-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}
.result-card, .manage-item {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}
.result-card:hover { transform: translateY(-5px); }

.card-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; cursor: pointer; }
.card-footer {
    padding: 1.2rem;
    background: var(--card-header);
    display: flex;
    justify-content: space-between;
    align-items: flex-start; /* Alignment changed to start for better wrapping */
    gap: 1rem;
}
.card-info { flex: 1; min-width: 0; }
.card-info h3 { 
    font-size: 1.15rem; 
    margin-bottom: 0.2rem; 
    line-height: 1.2;
    word-wrap: break-word; 
    overflow: visible;
    white-space: normal;
    max-width: none;
    color: white; /* Name not colored anymore */
}

.card-actions { display: flex; gap: 1rem; }
.card-actions button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.3rem;
    transition: transform 0.2s;
    opacity: 0.8;
}
.card-actions button:hover { transform: scale(1.2); opacity: 1; }

/* Footer */
footer {
    text-align: center;
    padding: 4rem 1rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
    background: rgba(15, 23, 42, 0.2);
}
footer p {
    max-width: 600px;
    margin: 0 auto;
}
/* Options & Settings */
.options-view { max-width: 600px; margin: 0 auto; }
.settings-card {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    text-align: center;
}
.action-stack { display: flex; flex-direction: column; gap: 1.5rem; align-items: center; margin-top: 2rem; }
.action-stack button, .action-stack label { width: 100%; max-width: 320px; }

/* Modals */
.modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    padding: 1.5rem;
}
.modal-content {
    background: var(--card-bg);
    width: 100%;
    max-width: 480px;
    padding: 2rem;
    border-radius: 28px;
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    max-height: 90vh;
    overflow-y: auto;
}
.preview-img {
    width: 100%;
    max-height: 250px;
    object-fit: cover;
    border-radius: 14px;
    margin-bottom: 1rem;
    border: 1px solid var(--border-color);
}
.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: white;
    margin-top: 0.5rem;
}

.text-leicht { color: var(--leicht) !important; }
.text-mittel { color: var(--mittel) !important; }
.text-schwer { color: var(--schwer) !important; }

.border-leicht { border-left: 5px solid var(--leicht) !important; }
.border-mittel { border-left: 5px solid var(--mittel) !important; }
.border-schwer { border-left: 5px solid var(--schwer) !important; }

/* Responsive */
@media (max-width: 600px) {
    .config-card { padding: 1.5rem; }
    .config-item { flex-direction: column; gap: 1rem; text-align: center; }
    .login-card { padding: 2rem 1.5rem; }
    .stats-bar { justify-content: center; width: 100%; }
}
