/* ============================================================
   Ratgeber PDF Download Plugin – Styles
   Matches the red/white design from the reference screenshots
============================================================ */

.ratgeber-wrapper {
    max-width: 520px;
    background: #fff;
    border: 1px solid #e4e4e4;
    border-radius: 6px;
    padding: 28px 28px 24px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    font-size: 15px;
    color: #222;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
    margin: 20px 0;
}

/* ── Header ── */
.ratgeber-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 18px;
}

.ratgeber-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #e8ecf7;
    color: #102474;
    border-radius: 8px;
    width: 52px;
    height: 52px;
    flex-shrink: 0;
}

.ratgeber-header-text h3 {
    margin: 0 0 4px;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.25;
    color: #111;
}

.ratgeber-header-text p {
    margin: 0;
    font-size: 13.5px;
    color: #555;
    line-height: 1.4;
}

/* ── Notice ── */
.ratgeber-notice {
    font-size: 14px;
    color: #333;
    margin-bottom: 14px;
    line-height: 1.5;
}

/* ── Email field ── */
.ratgeber-field {
    margin-bottom: 16px;
}

.ratgeber-email {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 14px;
    border: 1.5px solid #d1d1d1;
    border-radius: 4px;
    font-size: 15px;
    color: #222;
    outline: none;
    transition: border-color .2s;
    background: #fff;
}

.ratgeber-email::placeholder {
    color: #aaa;
}

.ratgeber-email:focus {
    border-color: #102474;
    box-shadow: 0 0 0 3px rgba(16,36,116,.12);
}

.ratgeber-email.is-invalid {
    border-color: #102474;
}

.ratgeber-field-error,
.ratgeber-consent-error {
    display: block;
    font-size: 12.5px;
    color: #102474;
    margin-top: 5px;
    min-height: 18px;
}

/* ── Consent checkbox ── */
.ratgeber-consent {
    margin-bottom: 20px;
}

.ratgeber-checkbox-label {
    display: flex;
    gap: 10px;
    cursor: pointer;
    align-items: flex-start;
    line-height: 1.5;
}

/* Hide native checkbox */
.ratgeber-consent-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

/* Custom checkbox box */
.ratgeber-custom-checkbox {
    display: inline-flex;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 1.5px solid #102474;
    border-radius: 3px;
    margin-top: 2px;
    background: #fff;
    transition: background .15s, border-color .15s;
    position: relative;
}

.ratgeber-consent-input:checked + .ratgeber-custom-checkbox {
    background: #102474;
    border-color: #102474;
}

.ratgeber-custom-checkbox::after {
    content: '';
    display: none;
    position: absolute;
    left: 4px;
    top: 1px;
    width: 6px;
    height: 10px;
    border: 2px solid #fff;
    border-top: none;
    border-left: none;
    transform: rotate(45deg);
}

.ratgeber-consent-input:checked + .ratgeber-custom-checkbox::after {
    display: block;
}

.ratgeber-consent-input.is-invalid + .ratgeber-custom-checkbox {
    border-color: #102474;
    box-shadow: 0 0 0 3px rgba(16,36,116,.15);
}

.ratgeber-consent-text {
    font-size: 13.5px;
    color: #333;
    line-height: 1.55;
}

.ratgeber-consent-text a {
    color: #102474;
    text-decoration: underline;
}

.ratgeber-consent-text a:hover {
    color: #0a1a5a;
}

/* ── Submit button ── */
.ratgeber-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #102474;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s, transform .1s;
    position: relative;
    min-width: 200px;
    justify-content: center;
}

.ratgeber-btn:hover:not(:disabled) {
    background: #0c1c5e;
}

.ratgeber-btn:active:not(:disabled) {
    transform: scale(.98);
}

.ratgeber-btn:disabled {
    opacity: .7;
    cursor: not-allowed;
}

/* Loading spinner inside button */
.ratgeber-btn-loading {
    display: none;
}

.ratgeber-btn-loading svg {
    animation: ratgeber-spin .8s linear infinite;
}

.ratgeber-btn.is-loading .ratgeber-btn-text {
    display: none;
}

.ratgeber-btn.is-loading .ratgeber-btn-loading {
    display: inline-flex;
}

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

/* ── Success message ── */
.ratgeber-success {
    margin-top: 14px;
    padding: 12px 16px;
    background: #edfbf0;
    border: 1px solid #7dd99a;
    border-radius: 4px;
    color: #1a6b35;
    font-size: 14px;
    display: none;
}

.ratgeber-success.is-visible {
    display: block;
}

/* ============================================================
   STEP 2 – Success banner + Callback form
============================================================ */

/* ── Success banner ── */
.ratgeber-step2-banner {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    background: #edfbf0;
    border: 1.5px solid #7dd99a;
    border-radius: 6px;
    padding: 16px 18px;
    font-size: 13.5px;
    color: #1a6b35;
    margin-bottom: 24px;
    line-height: 1.6;
}

.ratgeber-step2-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    background: #1a6b35;
    color: #fff;
    border-radius: 50%;
    margin-top: 1px;
}

.ratgeber-step2-banner-text strong {
    font-weight: 700;
}

.ratgeber-step2-email {
    font-weight: 600;
}

/* ── Callback section ── */
.ratgeber-callback-section h4 {
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    color: #111;
}

.ratgeber-callback-section > p {
    margin: 0 0 18px;
    font-size: 13.5px;
    color: #555;
}

/* ── Time label ── */
.ratgeber-time-label {
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    color: #444;
    margin-bottom: 12px;
}

/* ── Clocks grid ── */
.ratgeber-clocks {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 6px;
}

.ratgeber-clock-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    border: 2px solid #d8d8d8;
    border-radius: 8px;
    padding: 14px 10px 12px;
    width: 90px;
    user-select: none;
    transition: border-color .18s, background .18s, color .18s, box-shadow .18s;
    color: #333;
    background: #fff;
    position: relative;
}

.ratgeber-clock-label:hover {
    border-color: #102474;
    color: #102474;
    box-shadow: 0 0 0 3px rgba(16,36,116,.10);
}

.ratgeber-clock-label.is-selected {
    border-color: #102474;
    background: #102474;
    color: #fff;
    box-shadow: 0 0 0 3px rgba(16,36,116,.18);
}

/* Checkmark badge top-right corner */
.ratgeber-clock-label .ratgeber-clock-check {
    display: none;
    position: absolute;
    top: -8px;
    right: -8px;
    width: 22px;
    height: 22px;
    background: #102474;
    border: 2px solid #fff;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
}

.ratgeber-clock-label.is-selected .ratgeber-clock-check {
    display: flex;
}

/* Hide the real checkbox visually but keep it functional */
.ratgeber-clock-input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}

.ratgeber-clock-face svg {
    display: block;
}

.ratgeber-clock-text {
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
}

.ratgeber-time-error {
    display: block;
    font-size: 12.5px;
    color: #102474;
    margin-bottom: 14px;
    min-height: 18px;
}

/* ── Name row ── */
.ratgeber-name-row {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
}

.ratgeber-name-col {
    flex: 1;
    min-width: 0;
}

.ratgeber-field-label {
    display: block;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .06em;
    color: #444;
    margin-bottom: 6px;
}

.ratgeber-input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1.5px solid #d1d1d1;
    border-radius: 4px;
    font-size: 14px;
    color: #222;
    outline: none;
    transition: border-color .2s;
    background: #fff;
}

.ratgeber-input:focus {
    border-color: #102474;
    box-shadow: 0 0 0 3px rgba(16,36,116,.12);
}

.ratgeber-input.is-invalid {
    border-color: #102474;
}

.ratgeber-input-error {
    display: block;
    font-size: 12px;
    color: #102474;
    margin-top: 4px;
    min-height: 16px;
}

/* ── Phone row ── */
.ratgeber-phone-row {
    margin-bottom: 6px;
}

.ratgeber-phone-group {
    display: flex;
    gap: 8px;
}

.ratgeber-phone-prefix {
    flex-shrink: 0;
    width: 110px;
    padding: 10px 8px;
    border: 1.5px solid #d1d1d1;
    border-radius: 4px;
    font-size: 14px;
    color: #222;
    background: #fff;
    outline: none;
    cursor: pointer;
    transition: border-color .2s;
}

.ratgeber-phone-prefix:focus {
    border-color: #102474;
}

.ratgeber-phone-input {
    flex: 1;
}

.ratgeber-phone-error {
    display: block;
    font-size: 12.5px;
    color: #102474;
    margin-top: 5px;
    min-height: 18px;
}

/* ── Callback result ── */
.ratgeber-callback-result {
    margin-top: 14px;
    padding: 12px 16px;
    border: 1px solid transparent;
    border-radius: 4px;
    font-size: 14px;
    display: none;
}

.ratgeber-callback-result.is-visible {
    display: block;
}

/* ── Responsive ── */
@media (max-width: 420px) {
    .ratgeber-name-row {
        flex-direction: column;
    }
    .ratgeber-clocks {
        justify-content: center;
    }
    .ratgeber-clock-label {
        width: 80px;
    }
}

/* ============================================================
   CALLBACK FORM v2 – Clean design (Image 2 style)
============================================================ */

/* Header */
.ratgeber-cb-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}
.ratgeber-cb-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #102474;
    color: #fff;
    border-radius: 10px;
    width: 50px;
    height: 50px;
    flex-shrink: 0;
}
.ratgeber-cb-header h4 {
    margin: 0 0 3px;
    font-size: 18px;
    font-weight: 700;
    color: #102474;
}
.ratgeber-cb-header p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

/* Field wrap */
.ratgeber-cb-field-wrap {
    margin-bottom: 16px;
}
.ratgeber-cb-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}
.ratgeber-req {
    color: #102474;
}

/* Time / topic select */
.ratgeber-timepicker-wrap {
    position: relative;
}
.ratgeber-timepicker {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 44px 11px 12px;
    border: 1.5px solid #d1d1d1;
    border-radius: 4px;
    font-size: 14px;
    color: #222;
    background: #fff;
    appearance: none;
    -webkit-appearance: none;
    outline: none;
    cursor: pointer;
    transition: border-color .2s;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 10 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23666' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ratgeber-timepicker:focus {
    border-color: #102474;
    box-shadow: 0 0 0 3px rgba(16,36,116,.10);
}

/* Phone hint */
.ratgeber-phone-hint {
    display: block;
    font-size: 11.5px;
    color: #999;
    margin-top: 4px;
}

/* Required note */
.ratgeber-required-note {
    font-size: 12px;
    color: #888;
    margin: 10px 0 14px;
}
