:root {
    --bg: #f4f7f9;
    --card-bg: #ffffff;
    --primary: #cb0c9f;
    --text: #344767;
    --muted: #67748e;
    --gradient: linear-gradient(310deg, #7928ca, #ff0080);
    --radius: 16px;
    --shadow: 0 4px 20px 0 rgba(0,0,0,0.05);
}

/* Dark Mode Automatik */
@media (prefers-color-scheme: dark) {
    :root {
        --bg: #1a1c23;
        --card-bg: #242832;
        --text: #e2e8f0;
        --muted: #94a3b8;
        --shadow: 0 4px 20px 0 rgba(0,0,0,0.3);
    }

    .logo { color: #ffffff !important; }

    .quick-nav a {
        background: #334155 !important;
        color: #f1f5f9 !important;
    }

    .search-box input {
        background: #1e293b !important;
        border-color: #334155 !important;
        color: white !important;
    }

    .pill {
        background: #334155 !important;
        border-color: #475569 !important;
        color: #f1f5f9 !important;
    }

    .pill:hover { background: #475569 !important; }
}

body {
    font-family: 'Open Sans', -apple-system, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    margin: 0;
    padding: 20px;
    line-height: 1.5;
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto 30px;
}

.logo {
    font-size: 24px;
    font-weight: 800;
    color: #141727;
    text-decoration: none;
}

.logo span { color: var(--primary); }

.bento-container {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    gap: 20px;
}

.solution-block, .bento-card {
    display: block
    background: var(--card-bg);
    padding: 24px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* Suchbereich */
.search-box {
    display: flex;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 14px;
    border: 1px solid #d2d6da;
    border-radius: 10px;
    font-size: 16px;
    outline: none;
}

.btn-gradient {
    background: var(--gradient);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s, opacity 0.2s;
}

.btn-gradient:hover {
    transform: scale(1.02);
    opacity: 0.9;
}

/* Titel & Quick-Nav */
h1 { margin: 0; font-size: 1.8rem; font-weight: 800; }

.quick-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.quick-nav a {
    background: #e9ecef;
    color: var(--text);
    padding: 6px 14px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
}

/* Das Solutions Grid (Einheitliche Kacheln) */
.solutions-grid {
    display: grid;
    /* Erzeugt automatisch Spalten mit mind. 300px Breite */
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

h3 {
    margin-top: 0;
    color: var(--muted);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

/* Der Container: Erlaubt das Nebeneinanderstehen und Umbrechen */
.word-pills {
    display: flex;
    flex-wrap: wrap; /* Wichtig: Zeilenumbruch, wenn kein Platz mehr ist */
    flex-direction: row;
    gap: 12px;       /* Moderner Abstand zwischen den Pills (horizontal & vertikal) */
    margin-top: 10px;
}

/* Die Pill: Muss sich wie ein Inline-Block verhalten */
.pill {
    display: inline-flex;  /* Sorgt dafür, dass sie nebeneinander stehen können */
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    padding: 10px 18px;    /* Innenabstand: oben/unten 10px, links/rechts 18px */
    border-radius: 12px;
    color: var(--text);
    text-decoration: none;
    font-weight: 700;
    font-family: 'SFMono-Regular', Consolas, monospace;
    font-size: 1rem;
    white-space: nowrap;   /* Verhindert, dass ein Wort in der Pill umbricht */
    transition: all 0.2s ease-in-out;
}

/* Hover-Effekt für bessere UX */
.pill:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.pill.highlight {
    background: var(--gradient);
    color: white;
    border: none;
}

/* Footer Bereich */
.footer-area {
    margin-top: 20px;
}

.footer-area p { margin: 0; font-weight: 600; }

.related {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    font-size: 0.85rem;
}

.related a { margin-left: 10px; color: var(--primary); text-decoration: none; font-weight: 600; }

/* Mobile Anpassung */
@media (max-width: 600px) {
    .search-box { flex-direction: column; }
    .solutions-grid { grid-template-columns: 1fr; }
    body { padding: 15px; }
}

/* Modal Hintergrund (Overlay) */
.modal-overlay {
    display: none; /* Versteckt */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px); /* Der moderne Blur-Effekt */
}

/* Modal Fenster */
.modal-content {
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 500px;
    animation: slide 0.3s ease-out;
}

@keyframes slide {
    from { transform: translate(-50%, -40%); opacity: 0; }
    to { transform: translate(-50%, -50%); opacity: 1; }
}

.close-button {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 28px;
    cursor: pointer;
    color: var(--muted);
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.form-row {
    display: flex;
    gap: 10px;
}

.modal-form input, .modal-form textarea {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ddd;
    background: var(--bg);
    color: var(--text);
    width: 100%;
}

.disclaimer {
    font-size: 11px;
    color: var(--muted);
    line-height: 1.3;
}
