/* Order Modal - Postleitzahl popup shown from every "Jetzt Bestellen / Order Now" button */
.order-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(14, 19, 24, .6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, visibility .25s ease;
    padding: 20px;
}

.order-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.order-modal-box {
    position: relative;
    background: #fff;
    border-radius: 16px;
    max-width: 420px;
    width: 100%;
    padding: 32px 28px 28px;
    box-shadow: 0 25px 60px rgba(14, 19, 24, .3);
    transform: translateY(20px);
    transition: transform .25s ease;
    overflow-x: hidden;
}

.order-modal-overlay.active .order-modal-box {
    transform: translateY(0);
}

.order-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #f5f6f7;
    color: #0e1318;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s ease;
}

.order-modal-close:hover {
    background: #ececec;
}

.order-modal-box h3 {
    font-size: 19px;
    font-weight: 700;
    color: #0e1318;
    margin: 0 0 8px;
    padding-right: 24px;
}

.order-modal-box p {
    font-size: 13.5px;
    color: #666;
    margin: 0 0 18px;
}

.order-modal-plz-field {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f5f6f7;
    border-radius: 12px;
    padding: 0 16px;
}

.order-modal-plz-field i {
    color: #4CAF50;
    font-size: 19px;
}

.order-modal-plz-field input,
.order-modal-plz-field select {
    flex: 1;
    min-width: 0;
    border: 0;
    background: transparent;
    height: 50px;
    font-size: 14.5px;
    font-weight: 600;
    color: #0e1318;
    outline: none;
}

/* Without min-width:0, a flex item won't shrink below its content's natural
   width — the longest option text (e.g. "Morl, Sennewitz, Döckritz, Teicha,
   Gutenberg, Tornau") was forcing the select wider than its container,
   pushing the whole modal/page off-screen on narrow phones. The closed
   select now truncates its own display with an ellipsis instead; the open
   options list is unaffected and still shows the full text. */
.order-modal-plz-field select {
    cursor: pointer;
    appearance: auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-modal-plz-field input::placeholder {
    color: #8a8f94;
    font-weight: 500;
}

#pagePlzOtherInput,
#modalPlzOtherInput {
    width: 100%;
    height: 50px;
    padding: 0 16px;
    background: #f5f6f7;
    border: 0;
    border-radius: 12px;
    font-size: 14.5px;
    font-weight: 600;
    color: #0e1318;
    outline: none;
    box-sizing: border-box;
}

#pagePlzOtherInput::placeholder {
    color: #8a8f94;
    font-weight: 500;
}

.order-modal-hint {
    font-size: 12px;
    color: #c0392b;
    font-weight: 500;
    min-height: 16px;
    margin: 6px 2px 0;
}

.plz-zone-ok { color: #2e8b3d; font-size: 12.5px; font-weight: 600; line-height: 1.5; }
.plz-zone-not-covered { color: #c0392b; font-size: 12.5px; font-weight: 500; line-height: 1.5; }
.plz-zone-not-covered a { color: #c0392b; font-weight: 700; text-decoration: underline; }
.plz-zone-area-prompt { font-size: 12.5px; font-weight: 600; color: #0e1318; margin-bottom: 6px; }
.plz-zone-area-options { display: flex; flex-wrap: wrap; gap: 6px; }
.plz-zone-area-btn {
    border: 1px solid #eee; border-radius: 8px; background: #f5f6f7; padding: 6px 10px;
    font-size: 12px; font-weight: 600; color: #0e1318; transition: all .2s ease;
}
.plz-zone-area-btn:hover { border-color: #4CAF50; }
.plz-zone-area-btn.active { background: #4CAF50; color: #fff; border-color: #4CAF50; }

.order-modal-btn-group {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.order-modal-btn-group .order-action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 50px;
    border-radius: 12px;
    border: none;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: all .25s ease;
}

.order-modal-btn-group .abholung-btn {
    background: #0e1318;
    color: #fff;
}

.order-modal-btn-group .abholung-btn:hover {
    background: #242c34;
    color: #fff;
}

.order-modal-btn-group .lieferung-btn {
    background: #4CAF50;
    color: #fff;
}

.order-modal-btn-group .lieferung-btn:disabled {
    background: #C8E6C9;
    color: #fff;
    cursor: not-allowed;
    opacity: .8;
}

.order-modal-btn-group .lieferung-btn:not(:disabled):hover {
    background: #388E3C;
}

.order-modal-btn-group .lieferung-btn.active {
    box-shadow: 0 0 0 3px rgba(46, 139, 61, .35);
}

body.order-modal-open {
    overflow: hidden;
}

@media (max-width: 480px) {
    .order-modal-box {
        padding: 26px 20px 22px;
    }

    .order-modal-btn-group {
        flex-direction: column;
    }
}

/* Brief bottom confirmation (e.g. "Abholung gewählt") shown right before
   navigating away — reassures the customer their tap registered instead of
   the page just silently changing. */
.cp-order-toast {
    position: fixed;
    left: 50%;
    bottom: 30px;
    transform: translate(-50%, 16px);
    background: #0e1318;
    color: #fff;
    padding: 14px 24px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .3);
    z-index: 10001;
    opacity: 0;
    transition: opacity .3s ease, transform .3s ease;
    pointer-events: none;
    white-space: nowrap;
}

.cp-order-toast i {
    color: #4CAF50;
    margin-right: 8px;
}

.cp-order-toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
}
