/* ======================================================
   Floating cart bar (fc-bar) — sitewide, mobile + desktop.
   A floating rounded "pill" bar with side gutters, not a flush
   edge-to-edge strip — reads as a modern floating action bar
   instead of a flat toolbar glued to the screen edge.
   ====================================================== */
@keyframes fcBarSlideUp {
    from { transform: translateY(120%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fcBarPulse {
    0% { transform: scale(1); }
    35% { transform: scale(1.06); }
    100% { transform: scale(1); }
}

@keyframes fcBadgePop {
    0% { transform: scale(0.4); opacity: 0; }
    60% { transform: scale(1.25); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
}

.fc-bar {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 998;
    display: flex;
    align-items: center;
    gap: 14px;
    max-width: 480px;
    margin: 0 auto;
    background: #0e1318;
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 10px 12px 10px 10px;
    font-family: "Rubik", sans-serif;
    cursor: pointer;
    box-shadow: 0 14px 34px rgba(14, 19, 24, .35);
    animation: fcBarSlideUp .4s cubic-bezier(.25, .8, .35, 1);
    transition: background-color .25s ease, transform .15s ease, box-shadow .25s ease;
}

.fc-bar:hover {
    box-shadow: 0 18px 40px rgba(14, 19, 24, .42);
}

.fc-bar:active {
    transform: scale(.97);
}

.fc-bar.is-updated {
    animation: fcBarPulse .4s ease;
}

.fc-bar:not(.is-empty) {
    background: #142018;
}

.fc-bar__icon {
    position: relative;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #4CAF50;
    font-size: 16px;
    transition: background-color .25s ease, transform .2s ease;
}

.fc-bar:not(.is-empty) .fc-bar__icon {
    animation: fcBarPulse .5s ease;
}

.fc-bar__badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 19px;
    height: 19px;
    padding: 0 4px;
    border-radius: 999px;
    background: #ff5a3c;
    color: #fff;
    font-size: 10.5px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #0e1318;
    animation: fcBadgePop .3s cubic-bezier(.25, .8, .35, 1);
}

.fc-bar__text {
    flex: 1 1 auto;
    text-align: left;
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.fc-bar__text small {
    display: block;
    font-size: 10.5px;
    font-weight: 500;
    color: #9aa1a8;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.fc-bar.is-empty .fc-bar__text {
    color: #e4e6e8;
}

.fc-bar:not(.is-empty) .fc-bar__text {
    color: #81C784;
}

.fc-bar__go {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    transition: transform .2s ease;
}

.fc-bar:hover .fc-bar__go i {
    transform: translateX(3px);
}

.fc-bar__go i {
    transition: transform .2s ease;
}

.fc-bar:not(.is-empty) .fc-bar__go {
    background: #4CAF50;
    padding: 9px 14px;
    border-radius: 999px;
}

/* Reserve room at the bottom of every page so this floating bar never
   covers footer content/links underneath it. */
body.has-fc-bar {
    padding-bottom: 84px;
}

@media (max-width: 480px) {
    .fc-bar { left: 10px; right: 10px; bottom: 10px; padding: 8px 10px 8px 8px; gap: 10px; }
    .fc-bar__icon { width: 38px; height: 38px; }
    .fc-bar__text { font-size: 12.5px; }
    .fc-bar__go span { display: none; }
    .fc-bar:not(.is-empty) .fc-bar__go { padding: 10px; }
}

@media (min-width: 992px) {
    .fc-bar { max-width: 420px; }
}

/* ======================================================
   Cart details popup (opened from fc-bar on pages without
   the full order.html checkout modal)
   ====================================================== */
.fc-popup-overlay {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(14, 19, 24, .6);
    display: none;
    align-items: flex-end;
    justify-content: center;
}

.fc-popup-overlay.active {
    display: flex;
}

.fc-popup-box {
    width: 100%;
    max-width: 480px;
    max-height: 92vh;
    overflow-y: auto;
    background: #fff;
    border-radius: 18px 18px 0 0;
    padding: 24px;
    position: relative;
    animation: fcPopupUp .25s ease-out;
}

@media (min-width: 768px) {
    .fc-popup-overlay { align-items: center; }
    .fc-popup-box { border-radius: 18px; }
}

@keyframes fcPopupUp {
    from { transform: translateY(24px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.fc-popup-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 26px;
    line-height: 1;
    color: #8a8f94;
    cursor: pointer;
}

.fc-popup-box h3 {
    font-size: 19px;
    margin-bottom: 16px;
    padding-right: 24px;
}

.fc-popup-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
    max-height: 240px;
    overflow-y: auto;
}

.fc-popup-item-row {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid #f0f1f2;
}

.fc-popup-item-main {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.fc-popup-item-main i {
    flex: 0 0 auto;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f0f7f0;
    color: #4CAF50;
    font-size: 11px;
    margin-top: 1px;
}

.fc-popup-item-price {
    flex: 0 0 auto;
    min-width: 54px;
    text-align: right;
    white-space: nowrap;
    font-weight: 600;
}

.fc-popup-item-row small {
    display: block;
    color: #8a8f94;
    font-size: 12px;
    margin-top: 2px;
}

/* --- order type banner (read-only Abholung/Lieferung confirmation) --- */
.fc-popup-order-type {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f5f6f7;
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 700;
    color: #0e1318;
    margin-bottom: 16px;
}
.fc-popup-order-type i { color: #4CAF50; font-size: 15px; }

/* --- item qty steppers --- */
.fc-popup-item-info { display: flex; flex-direction: column; }

.fc-popup-item-qty {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

.fc-popup-qty-btn {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: #fff;
    color: #0e1318;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .15s ease;
}
.fc-popup-qty-btn:hover { border-color: #4CAF50; color: #4CAF50; }
.fc-popup-qty-btn:active { transform: scale(.92); }

.fc-popup-qty-val {
    min-width: 16px;
    text-align: center;
    font-size: 13.5px;
    font-weight: 700;
}

/* --- discount code --- */
.fc-popup-promo {
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
}
.fc-popup-promo-input {
    flex: 1;
    min-width: 0;
    height: 42px;
    padding: 0 14px;
    border-radius: 10px;
    border: 1px solid #e4e6e8;
    background: #f9fafa;
    font-size: 13.5px;
    outline: none;
}
.fc-popup-promo-apply {
    flex: 0 0 auto;
    height: 42px;
    padding: 0 16px;
    border-radius: 10px;
    border: none;
    background: #0e1318;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}
.fc-popup-promo-msg {
    font-size: 12px;
    font-weight: 600;
    margin: 6px 2px 14px;
}
.fc-popup-promo-msg.is-ok { color: #2e8b3d; }
.fc-popup-promo-msg.is-error { color: #c0392b; }

/* --- totals breakdown --- */
.fc-popup-totals {
    margin: 16px 0;
    padding-top: 14px;
    border-top: 1px solid #f0f1f2;
}
.fc-popup-totals .row {
    display: flex;
    justify-content: space-between;
    font-size: 13.5px;
    color: #555;
    padding: 4px 0;
}
.fc-popup-totals .row-grand {
    font-size: 17px;
    font-weight: 700;
    color: #0e1318;
    padding-top: 12px;
    margin-top: 6px;
    border-top: 2px solid #0e1318;
}
.fc-popup-totals .row-discount { color: #2e8b3d; font-weight: 600; }

/* --- tip --- */
.fc-popup-tip { margin-bottom: 16px; }
.fc-popup-tip-label {
    display: block;
    font-size: 12.5px;
    font-weight: 700;
    color: #0e1318;
    margin-bottom: 10px;
}
.fc-popup-tip-label small { color: #8a8f94; font-weight: 500; }
.fc-popup-tip-options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.fc-popup-tip-btn {
    flex: 1 1 auto;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid #e4e6e8;
    background: #fff;
    color: #0e1318;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s ease;
}
.fc-popup-tip-btn.active { background: #4CAF50; border-color: #4CAF50; color: #fff; }
.fc-popup-tip-custom {
    width: 100%;
    height: 42px;
    margin-top: 8px;
    padding: 0 14px;
    border-radius: 10px;
    border: 1px solid #e4e6e8;
    background: #f9fafa;
    font-size: 13.5px;
    outline: none;
    box-sizing: border-box;
}

/* --- delivery-fee policy note --- */
.fc-popup-delivery-note {
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.5;
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 16px;
}
.fc-popup-delivery-note.is-free { background: #f1f8f1; color: #2e8b3d; }
.fc-popup-delivery-note.is-fee { background: #fff7ed; color: #b8650f; }

/* --- shared section label (used for both "Ihre Daten" and "Zahlungsart") --- */
.fc-popup-section-label {
    font-size: 12.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #8a8f94;
    margin: 20px 0 10px;
    display: block;
}

/* --- customer details (name/phone/email/address/remarks/privacy) --- */
.fc-popup-customer {
    margin-bottom: 4px;
}

.fc-popup-field {
    margin-bottom: 12px;
}

.fc-popup-field span {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #0e1318;
    margin-bottom: 5px;
}

.fc-popup-field-row {
    display: flex;
    gap: 10px;
}

.fc-popup-field-row .fc-popup-field {
    flex: 1;
    min-width: 0;
}

.fc-popup-input {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border-radius: 10px;
    border: 1px solid #e4e6e8;
    background: #f9fafa;
    font-size: 13.5px;
    color: #0e1318;
    outline: none;
    box-sizing: border-box;
    font-family: inherit;
    transition: border-color .15s ease;
}

.fc-popup-input:focus {
    border-color: #4CAF50;
}

textarea.fc-popup-input {
    height: auto;
    padding: 10px 14px;
    resize: vertical;
}

.fc-popup-address-fields {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.fc-popup-privacy {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 11.5px;
    line-height: 1.5;
    color: #666;
    cursor: pointer;
    margin-top: 8px;
}

.fc-popup-privacy input {
    flex: 0 0 auto;
    margin-top: 2px;
    width: 16px;
    height: 16px;
    accent-color: #4CAF50;
}

/* --- payment method --- */
.fc-popup-payment-options {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
}

.fc-popup-payment-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 14px 10px;
    border-radius: 12px;
    border: 2px solid #eee;
    background: #fff;
    color: #0e1318;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s ease;
}

.fc-popup-payment-btn i {
    font-size: 20px;
    color: #8a8f94;
}

.fc-popup-payment-btn.active {
    border-color: #4CAF50;
    background: #f1f8f1;
    color: #4CAF50;
}
.fc-popup-payment-btn.active i {
    color: #4CAF50;
}

/* --- submit button --- */
.fc-popup-checkout-btn {
    width: 100%;
    height: 52px;
    margin-top: 18px;
    border-radius: 12px;
    border: none;
    background: #4CAF50;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .2s ease, transform .15s ease, opacity .2s ease;
}
.fc-popup-checkout-btn:hover:not(:disabled) { background: #388E3C; }
.fc-popup-checkout-btn:active:not(:disabled) { transform: scale(.98); }
.fc-popup-checkout-btn:disabled {
    background: #C8E6C9;
    cursor: not-allowed;
}

/* --- success state (shown in place of the form after a Barzahlung order) --- */
.fc-popup-success {
    text-align: center;
    padding: 20px 10px 6px;
}
.fc-popup-success-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    border-radius: 50%;
    background: #f1f8f1;
    color: #4CAF50;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.fc-popup-success h3 {
    font-size: 19px;
    margin-bottom: 8px;
}
.fc-popup-success p {
    font-size: 13.5px;
    color: #666;
    margin-bottom: 4px;
}
.fc-popup-success-close {
    width: 100%;
    height: 48px;
    margin-top: 18px;
    border-radius: 12px;
    border: none;
    background: #0e1318;
    color: #fff;
    font-size: 14.5px;
    font-weight: 700;
    cursor: pointer;
}

.fc-popup-payment-btn:hover {
    border-color: #4CAF50;
    background: #f3faf3;
}

.fc-popup-payment-btn:hover i {
    color: #4CAF50;
}
