/* ═══════════════════════════════════════════════════
   Demo Widerrufsformular – Stylesheet
   Basiert auf dem originalen Formular-CSS
   ═══════════════════════════════════════════════════ */

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    color: #222;
    background: #fff;
}

/* ─── Demo Banner ──────────────────────────────────── */

.demo-banner {
    background: #fff3cd;
    border-bottom: 1px solid #ffc107;
    color: #856404;
    text-align: center;
    padding: 10px 16px;
    font-size: 0.85rem;
    line-height: 1.4;
}

.demo-banner--inline {
    border: 1px solid #ffc107;
    border-radius: 4px;
    margin: 24px auto 0;
    max-width: 480px;
    font-size: 0.82rem;
}

/* ─── Container ────────────────────────────────────── */

.wr-container {
    max-width: 640px;
    margin: 0 auto;
    padding: 24px 20px 40px;
    background: transparent;
    min-height: 100vh;
}

h1 {
    font-size: 1.35rem;
    margin: 0 0 12px;
    color: #333;
}

/* ─── Intro / Hinweise ─────────────────────────────── */

.wr-intro {
    margin-bottom: 20px;
    color: #555;
}

.wr-privacy {
    font-size: 0.82rem;
    color: #777;
    margin: 16px 0 8px;
    padding: 10px 12px;
    background: #f5f5f5;
    border-left: 3px solid #ccc;
}

.wr-hint {
    color: #999;
    margin-top: 10px;
}

/* ─── Fieldset / Fields ────────────────────────────── */

fieldset {
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 16px 16px 8px;
    margin: 0 0 16px;
}

legend {
    font-weight: 600;
    font-size: 0.95rem;
    color: #444;
    padding: 0 6px;
}

.wr-field {
    margin-bottom: 12px;
}

.wr-field label {
    display: block;
    font-weight: 500;
    margin-bottom: 4px;
    font-size: 0.9rem;
}

.wr-field input[type="text"],
.wr-field input[type="email"],
.wr-field input[type="tel"],
.wr-field textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.15s;
}

.wr-field input:focus,
.wr-field textarea:focus {
    outline: none;
    border-color: #4a90d9;
    box-shadow: 0 0 0 2px rgba(74, 144, 217, 0.15);
}

.wr-field textarea {
    resize: vertical;
}

.wr-req {
    color: #c0392b;
    font-weight: 700;
}

.wr-opt {
    color: #999;
    font-weight: 400;
    font-size: 0.85em;
}

/* ─── Checkbox ─────────────────────────────────────── */

.wr-checkbox label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-weight: 400;
    line-height: 1.4;
    cursor: pointer;
}

.wr-checkbox input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
}

/* ─── Row Layout ───────────────────────────────────── */

.wr-row {
    display: flex;
    gap: 12px;
}

.wr-half {
    flex: 1 1 50%;
}

.wr-third {
    flex: 0 0 30%;
    max-width: 30%;
}

.wr-twothird {
    flex: 1 1 70%;
}

/* ─── Buttons ──────────────────────────────────────── */

.wr-actions {
    margin: 20px 0 10px;
}

.wr-btn {
    display: inline-block;
    padding: 12px 28px;
    background: #2a7ae2;
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s;
}

.wr-btn:hover,
.wr-btn:focus {
    background: #1a5bb5;
}

.wr-btn-secondary {
    background: #6c757d;
}

.wr-btn-secondary:hover,
.wr-btn-secondary:focus {
    background: #545b62;
}

/* ─── Error Box ────────────────────────────────────── */

.wr-errors {
    background: #fdf0f0;
    border: 1px solid #e8c4c4;
    border-radius: 4px;
    padding: 14px 16px;
    margin-bottom: 18px;
    color: #721c24;
}

.wr-errors ul {
    margin: 6px 0 0;
    padding-left: 18px;
}

/* ─── Success Box ──────────────────────────────────── */

.wr-success {
    text-align: center;
    padding: 30px 10px;
}

.wr-success h1 {
    color: #27ae60;
    font-size: 1.4rem;
}

.wr-summary {
    margin: 20px auto;
    border-collapse: collapse;
    text-align: left;
}

.wr-summary th,
.wr-summary td {
    padding: 6px 14px;
    border-bottom: 1px solid #eee;
    font-size: 0.95rem;
}

.wr-summary th {
    color: #666;
    font-weight: 500;
    white-space: nowrap;
}

.wr-notice {
    background: #eaf7ef;
    border: 1px solid #b8e2c8;
    border-radius: 4px;
    padding: 14px 18px;
    margin: 20px auto;
    max-width: 480px;
    text-align: left;
}

/* ─── Responsive ───────────────────────────────────── */

@media (max-width: 500px) {
    .wr-container {
        padding: 16px 14px 30px;
    }

    .wr-row {
        flex-direction: column;
        gap: 0;
    }

    .wr-half,
    .wr-third,
    .wr-twothird {
        flex: 1 1 100%;
        max-width: 100%;
    }

    .wr-btn {
        width: 100%;
        text-align: center;
    }
}
