/* ── returnrequest.css — styl eliqvapoteur ── */

.rr-no-scroll { overflow: hidden; }

a.rr-footer-link {
    display: inline-block;
    color: inherit;
    text-decoration: underline;
    cursor: pointer;
}

/* ── Overlay ── */
.rr-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99990;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    font-family: Figtree, sans-serif;
}

/* ── Modal ── */
.rr-modal {
    background: #fff;
    border-radius: 10px;
    padding: 44px 40px 36px;
    max-width: 820px;
    width: 100%;
    max-height: 92vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 5px 40px rgba(0, 0, 0, 0.18);
    border-top: 5px solid #00a0e3;
}

/* ── Close ── */
.rr-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #7a7a7a;
    line-height: 1;
    padding: 4px 8px;
    transition: color 0.05s;
}
.rr-close:hover { color: #232323; }

/* ── Tytuł ── */
.rr-title {
    margin: 0 0 8px;
    font-size: 1.6rem;
    font-weight: 700;
    color: #232323;
}
.rr-subtitle {
    margin: 0 0 28px;
    font-size: .95rem;
    color: #7a7a7a;
    line-height: 1.5;
}

/* ── Info ── */
.rr-info {
    font-size: 1rem;
    color: #555;
    margin: 0 0 20px;
}

/* ── Pola formularza ── */
.rr-field {
    margin-bottom: 28px;
    position: relative;
}
.rr-field label {
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    width: fit-content;
    position: absolute;
    z-index: 10;
    left: 12px;
    top: -14px;
    padding: 2px 10px;
    background: white;
    font-size: .8rem;
    font-weight: 600;
    color: #444;
    letter-spacing: .5px;
    text-transform: uppercase;
}
.rr-field input,
.rr-field textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 14px 16px;
    border: 2px solid #e5e5e5;
    border-radius: 8px;
    font-size: 1rem;
    color: #232323;
    background: #fff;
    transition: border-color 0.05s;
    outline: none;
    font-family: Figtree, sans-serif;
}
.rr-field input:focus,
.rr-field textarea:focus {
    border-color: #00a0e3;
    box-shadow: 0 0 0 3px rgba(0, 160, 227, 0.12);
}
.rr-reason-field { margin-top: 28px; }

/* ── Przyciski ── */
.rr-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 26px;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: background 0.05s;
    font-family: Figtree, sans-serif;
    min-height: 46px;
}
.rr-btn:disabled { opacity: .5; cursor: not-allowed; }

.rr-btn-primary {
    background: #00a0e3;
    color: #fff;
}
.rr-btn-primary:hover:not(:disabled) { background: #0078b3; }

.rr-btn-secondary {
    background: #f8f9fa;
    color: #444;
    border: 2px solid #e5e5e5;
}
.rr-btn-secondary:hover:not(:disabled) { background: #e5e5e5; }

.rr-btn-sm {
    padding: 10px 20px;
    font-size: .92rem;
    min-height: 40px;
    width: 100%;
    margin-top: 10px;
}

.rr-btn-row {
    display: flex;
    gap: 12px;
    margin-top: 22px;
    flex-wrap: wrap;
}
.rr-btn-row .rr-btn {
    flex: 1;
    min-width: 140px;
}

/* ── Błędy ── */
.rr-error, .rr-error-inline {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 10px;
    padding: 11px 15px;
    font-size: .95rem;
    color: #b91c1c;
    margin-top: 10px;
}

/* ── Lista zamówień — GRID 2 kolumny ── */
.rr-orders-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.rr-order-item {
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    padding: 16px;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: border-color 0.05s;
}
.rr-order-item:not(.rr-expired):hover {
    border-color: #00a0e3;
    background: #fff;
}
.rr-order-item.rr-expired {
    opacity: .55;
}

.rr-order-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}
.rr-order-ref {
    font-weight: 700;
    font-size: 1rem;
    color: #00a0e3;
}
.rr-order-date {
    font-size: .88rem;
    color: #7a7a7a;
}
.rr-order-status {
    font-size: .85rem;
    color: #7a7a7a;
}

/* ── Badges ── */
.rr-badge {
    font-size: .75rem;
    font-weight: 700;
    border-radius: 5px;
    padding: 3px 10px;
    white-space: nowrap;
}
.rr-badge-ok      { background: #dcfce7; color: #166534; }
.rr-badge-expired { background: #fee2e2; color: #991b1b; }
.rr-badge-returned { background: #f0fdf4; color: #15803d; border: 1px solid #86efac; }

/* ── Banner ── */
.rr-expired-banner {
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: 10px;
    padding: 10px 14px;
    font-size: .95rem;
    color: #c2410c;
    margin-bottom: 16px;
}
.rr-returned-banner {
    background: #f0fdf4 !important;
    border-color: #86efac !important;
    color: #15803d !important;
}

/* ── Nagłówek zamówienia ── */
.rr-order-header { margin-bottom: 20px; }
.rr-order-header-inner {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 12px;
    font-size: 1.05rem;
}
.rr-date-label { font-size: .9rem; color: #7a7a7a; }
.rr-label-bold { font-weight: 600; font-size: 1rem; margin: 0 0 14px; }

/* ── Produkty — lista ── */
.rr-product-list { display: flex; flex-direction: column; gap: 10px; }

.rr-product-row {
    border: 2px solid #e5e5e5;
    border-radius: 10px;
    padding: 14px 16px;
    background: #fff;
    transition: border-color 0.05s;
}
.rr-product-row:not(.rr-product-expired):hover {
    border-color: #00a0e3;
}
.rr-product-row.rr-product-expired {
    opacity: .5;
    background: #f8f9fa;
}
.rr-product-label {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    font-size: 1rem;
}
.rr-product-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #00a0e3;
    flex-shrink: 0;
}
.rr-product-name { color: #232323; font-weight: 500; }
.rr-product-qty {
    margin-top: 10px;
    padding-left: 30px;
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: .95rem;
    color: #555;
}
.rr-product-qty select {
    padding: 6px 10px;
    border: 2px solid #e5e5e5;
    border-radius: 8px;
    font-size: .95rem;
    color: #232323;
    font-family: Figtree, sans-serif;
}
.rr-product-qty select:focus {
    border-color: #00a0e3;
    outline: none;
}
.rr-product-price { color: #7a7a7a; }

.rr-product-returned-label {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    background: #f0fdf4;
    color: #15803d;
    border: 1px solid #86efac;
    border-radius: 5px;
    padding: 2px 10px;
    margin-left: 10px;
    white-space: nowrap;
}

/* ── Spinner ── */
.rr-spinner {
    text-align: center;
    padding: 30px;
    color: #7a7a7a;
    font-size: 1rem;
    grid-column: 1 / -1;
}

/* ── Sukces ── */
.rr-success-icon {
    font-size: 3.5rem;
    color: #28a745;
    text-align: center;
    margin-bottom: 16px;
}
#rr-step-success h3 {
    text-align: center;
    margin: 0 0 12px;
    font-size: 1.3rem;
    color: #232323;
}
#rr-step-success p {
    text-align: center;
    color: #555;
    font-size: 1rem;
    margin-bottom: 28px;
}

/* ── Responsive ── */
@media (max-width: 700px) {
    .rr-modal {
        padding: 32px 20px 24px;
        max-height: 95vh;
    }
    .rr-title { font-size: 1.3rem; }
    .rr-orders-list {
        grid-template-columns: 1fr;
    }
    .rr-btn-row {
        flex-direction: column-reverse;
    }
    .rr-btn-row .rr-btn {
        width: 100%;
    }
}