/* =========================
   SW Umfragen
   ========================= */

.sw-umfrage-box {
    margin: 24px 0;
    padding: 18px 20px;
    background: #454545;
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 14px;
    color: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,0.16);
}

.sw-umfrage-form {
    margin: 0;
}

.sw-frage-block-frontend {
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(255,255,255,0.10);
}

.sw-frage-block-frontend:last-of-type {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sw-frage {
    font-size: 1.08rem;
    font-weight: 700;
    line-height: 1.45;
    margin-bottom: 8px;
    color: #fff;
}

.sw-frage-beschreibung {
    margin: 0 0 12px 0;
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.78);
}

.sw-umfrage-form label {
    display: inline-flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 8px;
    color: #fff;
    line-height: 1.45;
    cursor: pointer;
}

.sw-umfrage-form textarea,
.sw-umfrage-form input[type="text"],
.sw-umfrage-form input[type="url"],
.sw-umfrage-form select {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    margin-top: 4px;
    background: #f2f2f2;
    color: #222;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease;
}

.sw-umfrage-form textarea:focus,
.sw-umfrage-form input[type="text"]:focus,
.sw-umfrage-form input[type="url"]:focus,
.sw-umfrage-form select:focus {
    outline: none;
    background: #fff;
    border-color: #66ffff;
    box-shadow: 0 0 0 3px rgba(102,255,255,0.12);
}

.sw-umfrage-form textarea {
    min-height: 110px;
    resize: vertical;
}

.sw-umfrage-form input[type="radio"],
.sw-umfrage-form input[type="checkbox"] {
    margin-top: 2px;
    accent-color: #66ffff;
    flex: 0 0 auto;
}

.sw-umfrage-form button[type="submit"] {
    display: inline-block;
    margin-top: 14px;
    padding: 10px 18px;
    background: #1f1f1f;
    color: #e0e0e0;
    border: none;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.sw-umfrage-form button[type="submit"]:hover {
    background: #000;
    color: #66ffff;
}

.sw-umfrage-form button[type="submit"]:active {
    transform: translateY(1px);
}

.sw-danke {
    margin-top: 0;
    margin-bottom: 16px;
    padding: 16px 18px;
    border-radius: 12px;
    background: rgba(102,255,255,0.08);
    border: 1px solid rgba(102,255,255,0.22);
    color: #fff;
    line-height: 1.55;
    font-size: 1rem;
}

.sw-umfrage-fehler {
    margin-bottom: 14px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(255,80,80,0.12);
    border: 1px solid rgba(255,80,80,0.22);
    color: #fff;
    line-height: 1.5;
}

/* =========================
   Ergebnisse
   ========================= */

.sw-umfrage-ergebnisse {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid rgba(255,255,255,0.12);
}

.sw-umfrage-ergebnisse-kopf {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 14px;
    font-size: 0.98rem;
    color: #fff;
}

.sw-umfrage-ergebnisse-gesamt {
    color: rgba(255,255,255,0.78);
}

.sw-ergebnis-block {
    margin-bottom: 22px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.sw-ergebnis-block:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sw-ergebnis-frage {
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.45;
    margin-bottom: 6px;
    color: #fff;
}

.sw-ergebnis-beschreibung {
    margin: 0 0 12px 0;
    font-size: 0.92rem;
    line-height: 1.45;
    color: rgba(255,255,255,0.75);
}

.sw-ergebnis-zeile {
    margin-bottom: 10px;
}

.sw-ergebnis-label-row {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 4px;
}

.sw-ergebnis-label {
    color: #fff;
    font-weight: 600;
    line-height: 1.4;
}

.sw-ergebnis-wert {
    color: rgba(255,255,255,0.82);
    white-space: nowrap;
    font-size: 0.95rem;
}

.sw-ergebnis-balken {
    height: 10px;
    background: rgba(255,255,255,0.10);
    border-radius: 999px;
    overflow: hidden;
}

.sw-ergebnis-balken span {
    display: block;
    height: 100%;
    width: 0;
    background: #66ffff;
    border-radius: 999px;
}

.sw-ergebnis-textliste {
    margin: 0;
    padding-left: 18px;
}

.sw-ergebnis-textliste li {
    margin-bottom: 6px;
    line-height: 1.45;
}

.sw-ergebnis-leer {
    color: rgba(255,255,255,0.75);
    font-style: italic;
}

/* Falls Umfragen in custom-dark-form liegen */
.custom-dark-form .sw-umfrage-box {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.10);
    box-shadow: none;
    padding: 0;
}

.custom-dark-form .sw-frage-block-frontend {
    padding: 0 0 18px 0;
}

.custom-dark-form .sw-umfrage-form button[type="submit"] {
    background: #1f1f1f !important;
    color: #e0e0e0 !important;
}

.custom-dark-form .sw-umfrage-form button[type="submit"]:hover {
    background: #000 !important;
    color: #66ffff !important;
}

@media (max-width: 767px) {
    .sw-umfrage-box {
        padding: 14px;
        border-radius: 12px;
    }

    .sw-frage {
        font-size: 1rem;
    }

    .sw-frage-beschreibung {
        font-size: 0.92rem;
    }

    .sw-umfrage-form button[type="submit"] {
        width: 100%;
    }

    .sw-ergebnis-label-row {
        flex-direction: column;
        align-items: flex-start;
    }
}
