/* ── goalz_modal.css — Reusable modal component ─────────────────────────────
 * Used for: Trainer entlassen confirmation dialog (trainer.php, trainerinfo.php)
 * Design language: follows .mobile-help-modal pattern from goalz2.css
 * Toggle: use HTML `hidden` attribute — JS sets/removes element.hidden
 * ──────────────────────────────────────────────────────────────────────────── */

.goalz-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.goalz-modal[hidden] {
    display: none;
}

.goalz-modal__card {
    width: 100%;
    max-width: 560px;
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #d6dee6;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
    overflow: hidden;
    font-family: lucida, verdana, sans-serif;
}

.goalz-modal__title {
    background: #0066a2;
    color: #fff;
    padding: 12px 16px;
    font-size: 16px;
    font-weight: 700;
}

.goalz-modal__body {
    padding: 16px;
    color: #0b3551;
    font-size: 13px;
    line-height: 1.4em;
}

.goalz-modal__body p {
    margin: 0 0 10px 0;
}

.goalz-modal__question {
    font-size: 14px;
    line-height: 1.35;
}

.goalz-modal__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid #f0f0f0;
}

.goalz-modal__row:last-of-type {
    border-bottom: none;
}

.goalz-modal__row-label {
    font-weight: 600;
    color: #0b3551;
}

.goalz-modal__row-value {
    text-align: right;
    color: #0b3551;
}

.goalz-modal__row--warning .goalz-modal__row-label,
.goalz-modal__row--warning .goalz-modal__row-value {
    color: #c0392b;
}

.goalz-modal__hint {
    font-size: 12px;
    color: #355a73;
    margin-top: 10px;
    margin-bottom: 0;
    font-style: italic;
}

.goalz-modal__impact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 12px 0;
}

.goalz-modal__impact-card {
    border: 1px solid #d8e6f2;
    border-radius: 8px;
    background: #f7fbff;
    padding: 10px;
}

.goalz-modal__impact-card--warning {
    background: #fff8f6;
    border-color: #f0c8c0;
}

.goalz-modal__impact-label {
    display: block;
    color: #5c7387;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.goalz-modal__impact-value {
    display: block;
    color: #0b3551;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.2;
}

.goalz-modal__impact-card--warning .goalz-modal__impact-value {
    color: #c0392b;
}

.goalz-modal__form-panel {
    border: 1px solid #d8e6f2;
    border-radius: 8px;
    background: #f9fcff;
    padding: 10px;
    margin: 12px 0;
}

.goalz-modal__section-label {
    color: #0b3551;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.goalz-modal__form-flow {
    display: grid;
    grid-template-columns: minmax(74px, 1fr) 32px minmax(128px, 1.4fr);
    align-items: center;
    gap: 8px;
}

.goalz-modal__form-state {
    min-width: 0;
}

.goalz-modal__form-caption {
    display: block;
    color: #5c7387;
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 5px;
}

.goalz-modal__form-arrow {
    color: #0066a2;
    font-size: 22px;
    font-weight: 700;
    text-align: center;
    padding-top: 16px;
}

.goalz-modal__form-note {
    color: #355a73;
    font-size: 12px;
    line-height: 1.35;
    margin: 9px 0 0 0;
}

.goalz-modal-form-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 11px;
    font-weight: 800;
    font-size: 17px;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.38), 0 1px 3px rgba(11, 53, 81, 0.16);
    vertical-align: middle;
}

.goalz-modal-form-icon__symbol {
    display: none;
}

.goalz-modal-form-icon__value {
    display: block;
}

.goalz-modal-form-icon--top {
    background: #169447;
    color: #fff;
}

.goalz-modal-form-icon--hoch {
    background: #8ecf4d;
    color: #123b18;
}

.goalz-modal-form-icon--neutral {
    background: #d8e6f2;
    color: #294765;
}

.goalz-modal-form-icon--runter {
    background: #f0a35b;
    color: #4d2600;
}

.goalz-modal-form-icon--tief {
    background: #d94c3d;
    color: #fff;
}

.goalz-modal-form-range {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
}

.goalz-modal-form-range__dash {
    color: #5c7387;
    font-size: 12px;
    font-weight: 700;
}

.goalz-modal__consequence-list {
    display: grid;
    gap: 8px;
    margin-top: 10px;
}

.goalz-modal__consequence {
    position: relative;
    color: #355a73;
    background: #ffffff;
    border: 1px solid #e3edf5;
    border-radius: 8px;
    padding: 8px 10px 8px 28px;
    font-size: 12px;
    line-height: 1.35;
}

.goalz-modal__consequence::before {
    content: "!";
    position: absolute;
    left: 9px;
    top: 8px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #f0a35b;
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    line-height: 14px;
    text-align: center;
}

.goalz-modal__actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
    padding: 12px 16px 14px 16px;
    border-top: 1px solid #e6edf3;
}

.goalz-modal__btn {
    border-radius: 8px;
    padding: 7px 14px;
    font-size: 13px;
    font-family: lucida, verdana, sans-serif;
    cursor: pointer;
    border: 1px solid transparent;
    font-weight: 600;
    transition: opacity 0.15s ease;
}

.goalz-modal__btn:hover {
    opacity: 0.88;
}

.goalz-modal__btn--cancel {
    background: #ffffff;
    color: #0066a2;
    border-color: #0066a2;
}

.goalz-modal__btn--danger {
    background: #c0392b;
    color: #ffffff;
    border-color: #c0392b;
}

@media (max-width: 520px) {
    .goalz-modal__impact-grid {
        grid-template-columns: 1fr;
    }

    .goalz-modal__form-flow {
        grid-template-columns: minmax(0, 1fr);
    }

    .goalz-modal__form-arrow {
        padding-top: 0;
        transform: rotate(90deg);
    }

    .goalz-modal__actions {
        flex-direction: column-reverse;
    }

    .goalz-modal__btn {
        width: 100%;
    }
}
