/* =============================================================
   Rette Dein Obst – Sammelstellen – Frontend Styles
   CI: rette-dein-obst.de
   ============================================================= */

:root {
    --rdo-green:       #4a7c3f;
    --rdo-green-dark:  #355c2d;
    --rdo-green-light: #e8f2e5;
    --rdo-orange:      #e8531c;
    --rdo-beige:       #faf7f2;
    --rdo-border:      #d0cec9;
    --rdo-radius:      8px;
    --rdo-shadow:      0 2px 8px rgba(0,0,0,.10);
}

/* Single Sammelstelle ----------------------------------------- */
.rdo-sammelstelle {
    font-family: inherit;
    border: 1px solid var(--rdo-border);
    border-radius: var(--rdo-radius);
    overflow: hidden;
    box-shadow: var(--rdo-shadow);
    background: #fff;
    margin: 1.5em 0;
    /* frontend.js setzt pro Reihe eine gemessene min-height (offsetHeight inkl. Rahmen) */
    box-sizing: border-box;
}

.rdo-sammelstelle.rdo-layout-list {
    display: flex;
    align-items: flex-start;
}

.rdo-ss-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}
.rdo-layout-list .rdo-ss-image {
    flex: 0 0 200px;
}
.rdo-layout-list .rdo-ss-image img {
    height: 100%;
}

.rdo-ss-content {
    padding: 20px 24px;
    flex: 1;
}

.rdo-ss-title {
    margin: 0 0 12px;
    font-size: 1.3rem;
    color: var(--rdo-green-dark);
    border-bottom: 2px solid var(--rdo-green-light);
    padding-bottom: 8px;
}

/* Address ---------------------------------------------------- */
.rdo-ss-address {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}
.rdo-ss-address address {
    font-style: normal;
    line-height: 1.5;
    flex: 1;
}
.rdo-icon {
    font-size: 16px;
    line-height: 1.5;
}

.rdo-route-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--rdo-orange);
    color: #fff !important;
    text-decoration: none !important;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    transition: background .15s;
    white-space: nowrap;
}
.rdo-route-btn:hover {
    background: #c4430f;
    color: #fff !important;
}

/* Contact ---------------------------------------------------- */
.rdo-ss-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 14px;
}
.rdo-ss-contact span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.rdo-ss-contact a {
    color: var(--rdo-green);
    text-decoration: none;
}
.rdo-ss-contact a:hover { text-decoration: underline; }

.rdo-ss-note {
    margin-bottom: 12px;
    color: #555;
    font-size: 14px;
    background: var(--rdo-beige);
    border-left: 3px solid var(--rdo-orange);
    padding: 6px 12px;
    border-radius: 0 4px 4px 0;
}

/* Hours ------------------------------------------------------ */
.rdo-ss-hours {
    margin-top: 16px;
    border-top: 1px solid var(--rdo-border);
    padding-top: 14px;
}
.rdo-ss-hours-title {
    margin: 0 0 12px;
    font-size: 1rem;
    color: var(--rdo-green-dark);
}

.rdo-ss-product-group {
    background: var(--rdo-green-light);
    border-radius: var(--rdo-radius);
    padding: 10px 14px;
    margin-bottom: 10px;
}
.rdo-ss-product-name {
    margin: 0 0 6px;
    font-size: 0.9rem;
    color: var(--rdo-green-dark);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}
.rdo-ss-product-name::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--rdo-green);
}
.rdo-ss-start-date {
    margin: 0 0 6px;
    font-size: 12px;
    color: #555;
}
.rdo-ss-time-list {
    margin: 0;
    padding: 0;
    list-style: none;
}
.rdo-ss-time-list li {
    padding: 3px 0;
    font-size: 14px;
    border-bottom: 1px solid rgba(74,124,63,.15);
}
.rdo-ss-time-list li:last-child { border-bottom: none; }
.rdo-ss-time-list li small { color: var(--rdo-muted, #777); margin-left: 6px; }

/* Overview Table --------------------------------------------- */
.rdo-overview { overflow-x: auto; }

.rdo-overview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
.rdo-overview-table th {
    background: var(--rdo-green);
    color: #fff;
    padding: 10px 14px;
    text-align: left;
    font-weight: 600;
}
.rdo-overview-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--rdo-border);
    vertical-align: top;
}
.rdo-overview-table tr:nth-child(even) td {
    background: var(--rdo-beige);
}
.rdo-overview-table tr:hover td {
    background: var(--rdo-green-light);
}

.rdo-overview-times {
    margin: 0;
    padding: 0;
    list-style: none;
}
.rdo-overview-times li { margin-bottom: 3px; font-size: 13px; }

.rdo-no-results {
    padding: 20px;
    color: #777;
    font-style: italic;
}

/* Status Badge ----------------------------------------------- */
.rdo-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    white-space: nowrap;
    letter-spacing: .2px;
}
.rdo-status-badge::before {
    content: '';
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
    animation: rdoStatusPulse 1.8s ease-in-out infinite;
}
.rdo-badge--open {
    background: #e8f5e4;
    color: #2e7d32;
    border: 1px solid #81c784;
}
.rdo-badge--open::before    { background: #43a047; --rdo-pulse-color: 67,160,71; }
.rdo-badge--soon {
    background: #fff3e0;
    color: #e65100;
    border: 1px solid #ffb74d;
}
.rdo-badge--soon::before    { background: #fb8c00; --rdo-pulse-color: 251,140,0; }
.rdo-badge--closed {
    background: #fce4e4;
    color: #b71c1c;
    border: 1px solid #ef9a9a;
}
.rdo-badge--closed::before  { background: #e53935; --rdo-pulse-color: 229,57,53; }

@keyframes rdoStatusPulse {
    0%   { box-shadow: 0 0 0 0 rgba(var(--rdo-pulse-color, 0,0,0), .55); }
    70%  { box-shadow: 0 0 0 6px rgba(var(--rdo-pulse-color, 0,0,0), 0); }
    100% { box-shadow: 0 0 0 0 rgba(var(--rdo-pulse-color, 0,0,0), 0); }
}
@media (prefers-reduced-motion: reduce) {
    .rdo-status-badge::before { animation: none; }
}

.rdo-status-next {
    display: block;
    font-size: 11px;
    color: #666;
    margin-top: 3px;
}

/* Dual-Badge (Sammelstelle + Getränkemarkt) ------------------ */
.rdo-dual-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: flex-start;
}

/* Getränkemarkt-Badge: Blau (eigene Farbe) */
.rdo-badge--gm.rdo-badge--open {
    background: #e3f0fb;
    color: #1565c0;
    border-color: #90caf9;
}
.rdo-badge--gm.rdo-badge--open::before  { background: #1976d2; --rdo-pulse-color: 25,118,210; }
.rdo-badge--gm.rdo-badge--soon {
    background: #fff3e0;
    color: #e65100;
    border-color: #ffb74d;
}
.rdo-badge--gm.rdo-badge--closed {
    background: #fce4e4;
    color: #b71c1c;
    border-color: #ef9a9a;
}

/* Getränkemarkt-Block im Frontend ---------------------------- */
.rdo-getraenk-block {
    margin-top: 16px;
    border-top: 1px solid var(--rdo-border);
    padding-top: 14px;
}
.rdo-getraenk-title {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 1rem;
    margin: 0 0 10px;
    color: #1565c0;
}
.rdo-getraenk-icon { font-size: 1rem; }
.rdo-getraenk-list {
    margin: 0 0 6px;
    padding: 0;
    list-style: none;
}
.rdo-getraenk-list li {
    padding: 4px 10px;
    background: #e3f0fb;
    border-radius: 4px;
    margin-bottom: 4px;
    font-size: 14px;
    border-left: 3px solid #1976d2;
}
.rdo-getraenk-note {
    font-size: 12px;
    color: #1976d2;
    font-weight: 600;
    margin: 0;
}

.rdo-ss-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}
.rdo-ss-title-row .rdo-ss-title { margin: 0; }

/* Typ-Fähnchen (Strip oben an der Karte) --------------------- */
.rdo-type-strip {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 7px 16px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #fff;
    line-height: 1;
}
.rdo-type-strip::before {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 5px 0 5px 7px;
    border-color: transparent transparent transparent rgba(255,255,255,.45);
    flex-shrink: 0;
}
.rdo-type--sammelstelle         { background: var(--rdo-green); }
.rdo-type--ankauf-lohn          { background: #1976d2; }           /* Blau  */
.rdo-type--ankauf-lohn-getraenk { background: var(--rdo-orange); } /* Orange */

/* Modern Layout (zweispaltige Vollansicht) -------------------- */
.rdo-layout-modern {
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(0,0,0,.08);
    /* Macht die Karte zum Query-Container: die Kompakt-Regeln weiter unten
       reagieren auf die tatsächlich gerenderte Kartenbreite (z. B. in einer
       schmalen Spalten-Übersicht), nicht auf die Bildschirmbreite. Eine
       einzeln stehende volle Vollansicht bleibt dadurch unangetastet. */
    container-type: inline-size;
}

.rdo-modern-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.rdo-modern-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--rdo-green-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
}
.rdo-modern-heading { min-width: 0; }
.rdo-modern-title {
    margin: 0 0 6px;
    font-size: 1.7rem;
    color: var(--rdo-green-dark);
}
.rdo-modern-contact {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    color: #555;
    font-size: 14px;
}
.rdo-modern-contact a { color: #555; text-decoration: none; }
.rdo-modern-contact a:hover { text-decoration: underline; }
.rdo-modern-dot { color: #bbb; }
.rdo-modern-icon { margin-right: 3px; }

.rdo-modern-badges {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}
.rdo-layout-modern .rdo-status-badge {
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 6px;
    width: 100%;
    justify-content: center;
}
.rdo-layout-modern .rdo-status-next { display: none; }

.rdo-modern-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 20px;
    padding: 12px 16px;
    background: #fff4e9;
    border: 2px solid var(--rdo-orange);
    border-radius: 10px;
    color: #8a3c10 !important;
    font-size: 14px;
    animation: rdoNotePulse 2s ease-in-out infinite;
}
.rdo-modern-note-icon { flex-shrink: 0; font-size: 18px; line-height: 1.2; }
.rdo-modern-note-text { color: inherit !important; font-weight: 400; }

@keyframes rdoNotePulse {
    0%   { box-shadow: 0 0 0 0 rgba(232,83,28,.45); }
    70%  { box-shadow: 0 0 0 8px rgba(232,83,28,0); }
    100% { box-shadow: 0 0 0 0 rgba(232,83,28,0); }
}

.rdo-modern-divider {
    border: none;
    border-top: 1px solid var(--rdo-border);
    margin: 0 0 24px;
}

.rdo-modern-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px;
}
.rdo-modern-columns.rdo-modern-columns--with-gm {
    grid-template-columns: 1.3fr 1fr;
}

.rdo-modern-col-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px;
    font-size: 1.05rem;
    color: var(--rdo-green-dark) !important;
}
.rdo-modern-col-title--gm { color: #1565c0 !important; }

.rdo-modern-product-card {
    border: 1px solid var(--rdo-border);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 14px;
}
.rdo-modern-product-card:last-child { margin-bottom: 0; }
.rdo-modern-product-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 10px;
}
.rdo-modern-product-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--rdo-green-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}
.rdo-modern-product-name { font-weight: 700; color: #222 !important; }
.rdo-modern-product-start { font-size: 12px; color: #888 !important; }
.rdo-modern-product-title { flex: 1; min-width: 0; }
/* Letzter Annahmetag rechtsbündig im Produktkopf */
.rdo-modern-product-last {
    font-size: 13px;
    font-weight: 700;
    color: #7a4d00 !important;
    background: #fff4d6;
    border: 1px solid #f0b429;
    border-radius: 999px;
    padding: 4px 12px;
    white-space: nowrap;
    text-align: right;
}
.rdo-modern-product-last--today {
    color: #fff !important;
    background: #c62828;
    border-color: #c62828;
}

/* Zeiten als Grid statt frei fließendem Text: Tag/Uhrzeit/Datum stehen bei
   jeder Zeile exakt untereinander. .rdo-modern-time-row selbst legt sich per
   "display: contents" nicht als eigenes Grid an, sondern reicht seine Kinder
   an das umgebende Grid durch — daher müssen Tage/Uhrzeit/Start-Zelle in der
   PHP-Ausgabe immer als 3–4 Elemente vorhanden sein (ggf. leer), sonst
   verrutscht die Spaltenzuordnung der nachfolgenden Zeilen. */
.rdo-modern-times {
    border-top: 1px solid var(--rdo-border);
    padding-top: 10px;
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    column-gap: 10px;
    row-gap: 8px;
    align-items: baseline;
}
.rdo-modern-gm-card .rdo-modern-time-row,
.rdo-modern-times .rdo-modern-time-row {
    display: contents;
}
.rdo-modern-time-icon { font-size: 13px; }
.rdo-modern-time-row strong { color: #222 !important; white-space: nowrap; }
.rdo-modern-time-row span { color: #222 !important; }
.rdo-modern-time-row small { color: #999 !important; white-space: nowrap; }

.rdo-modern-gm-card {
    border: 1px solid #cfe3f7;
    background: #f4f9fe;
    border-radius: 14px;
    padding: 16px;
    display: grid;
    grid-template-columns: auto auto 1fr;
    column-gap: 10px;
    row-gap: 10px;
    align-items: baseline;
}

.rdo-modern-empty { color: #888 !important; font-style: italic; }

@media (max-width: 700px) {
    .rdo-layout-modern { padding: 20px; }
    .rdo-modern-columns,
    .rdo-modern-columns.rdo-modern-columns--with-gm { grid-template-columns: 1fr; }
}

/* Kompakt-Modus: greift, wenn die Karte selbst schmal gerendert wird (z. B.
   in einer mehrspaltigen Übersicht) — unabhängig von der Bildschirmbreite. */
@container (max-width: 480px) {
    .rdo-layout-modern { padding: 18px; }

    .rdo-modern-header { gap: 10px; }
    .rdo-modern-avatar { width: 40px; height: 40px; font-size: 18px; }
    .rdo-modern-title { font-size: 1.1rem; }
    .rdo-modern-contact { font-size: 12px; }

    .rdo-modern-col-title { font-size: .9rem; }

    .rdo-modern-columns,
    .rdo-modern-columns.rdo-modern-columns--with-gm { grid-template-columns: 1fr; }

    .rdo-modern-product-card { padding: 10px; }
    .rdo-modern-product-icon { width: 30px; height: 30px; font-size: 15px; }
    .rdo-modern-product-name { font-size: .92rem; }
    .rdo-modern-product-head { flex-wrap: wrap; row-gap: 6px; }
    .rdo-modern-product-last { font-size: 12px; white-space: normal; text-align: left; }

    /* Statt starrer Grid-Spalten (die bei wenig Platz mitten im Wort umbrechen)
       lieber eine frei umbrechende Zeile pro Zeitangabe. */
    .rdo-modern-times,
    .rdo-modern-gm-card {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }
    .rdo-modern-times .rdo-modern-time-row,
    .rdo-modern-gm-card .rdo-modern-time-row {
        display: flex;
        flex-wrap: wrap;
        align-items: baseline;
        gap: 6px;
        font-size: 13px;
    }
}

/* Mini Card -------------------------------------------------- */
.rdo-mini-card {
    border: 1px solid var(--rdo-border);
    border-radius: var(--rdo-radius);
    background: #fff;
    box-shadow: var(--rdo-shadow);
    margin: .75em 0;
    overflow: hidden;
    transition: box-shadow .2s;
    /* Feste Mindesthöhe statt Höhenangleich über den Elterncontainer: die Karten
       stecken in unabhängig gestapelten Spalten (kein gemeinsamer Zeilen-Wrapper
       über alle 3 Spalten), daher lässt sich Gleichhöhe nicht per Grid/Flex-Stretch
       vom Divi-Layout ableiten. Bei ungewöhnlich langem Inhalt wächst die Karte
       trotzdem über die Mindesthöhe hinaus, statt Text abzuschneiden. */
    min-height: 260px;
    height: 100%;
    /* frontend.js setzt pro Reihe eine gemessene min-height (offsetHeight inkl. Rahmen) */
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}
.rdo-mini-card:hover { box-shadow: 0 3px 14px rgba(0,0,0,.14); }

.rdo-mini-body {
    display: flex;
    justify-content: space-between;
    padding: 12px 16px;
    gap: 14px;
    flex-wrap: wrap;
    /* nimmt jede zusätzliche Höhe der Card auf, Kinder verteilen sich per align-self */
    flex: 1;
}

.rdo-mini-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
    align-self: flex-start;
}

/* Status: volle Kartenbreite, als Balken statt Pille */
.rdo-mini-status-row {
    padding: 10px 16px 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.rdo-mini-status-row .rdo-dual-badges {
    flex-direction: column;
}
.rdo-mini-status-row .rdo-status-badge {
    width: 100%;
    justify-content: center;
    font-size: 14px;
    padding: 6px 14px;
    border-radius: 6px;
}
.rdo-mini-status-row .rdo-status-badge::before {
    width: 9px;
    height: 9px;
}
.rdo-mini-status-row .rdo-status-next {
    text-align: center;
}

.rdo-mini-name {
    font-size: 15px;
    font-weight: 700;
    color: var(--rdo-green-dark);
    line-height: 1.3;
}

.rdo-mini-address-block {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.rdo-mini-addr-line {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #555;
    line-height: 1.4;
}
.rdo-mini-addr-plz {
    padding-left: 18px; /* fluchtet mit Icon oben */
    font-weight: 600;
    color: #333;
}
.rdo-mini-icon { font-size: 13px; flex-shrink: 0; }

/* "Alle Infos"-Button */
.rdo-mini-detail-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--rdo-green);
    color: #fff;
    border: none;
    border-radius: 22px;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background .15s, transform .1s;
    line-height: 1;
    align-self: flex-end;
}
.rdo-mini-detail-btn:hover  { background: var(--rdo-green-dark); }
.rdo-mini-detail-btn:active { transform: scale(.97); }
.rdo-mini-detail-btn svg    { flex-shrink: 0; }

/* Modal (optional, via JS trigger) --------------------------- */
.rdo-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    /* Maximal möglicher z-index: manche Theme-Sticky-Header setzen sehr hohe eigene
       Werte, die das Modal sonst überdecken würden. */
    z-index: 2147483647;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: rdoFadeIn .2s ease;
}
.rdo-modal-overlay[hidden] { display: none; }

@keyframes rdoFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.rdo-modal-box {
    background: #fff;
    border-radius: var(--rdo-radius);
    max-width: 640px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    padding: 24px;
    box-shadow: 0 8px 32px rgba(0,0,0,.25);
    animation: rdoSlideUp .2s ease;
}
@keyframes rdoSlideUp {
    from { transform: translateY(20px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

/* Typ-Strip im Modal: negativer Rand damit es bündig am oberen Rahmen liegt */
.rdo-modal-body .rdo-type-strip {
    margin: -24px -24px 16px -24px;
    border-radius: var(--rdo-radius) var(--rdo-radius) 0 0;
}

.rdo-modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    color: #888;
    padding: 2px 6px;
}
.rdo-modal-close:hover { color: #111; }

body.rdo-modal-open { overflow: hidden; }

.rdo-popup-header { margin-bottom: 14px; }
.rdo-popup-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 6px;
}
.rdo-popup-title { margin: 0; font-size: 1.2rem; color: var(--rdo-green-dark); }
.rdo-popup-image img {
    width: 100%;
    max-height: 180px;
    object-fit: cover;
    border-radius: var(--rdo-radius);
}

/* Responsive ------------------------------------------------- */
@media (max-width: 600px) {
    .rdo-layout-list { flex-direction: column; }
    .rdo-layout-list .rdo-ss-image { flex: none; width: 100%; }
    .rdo-ss-content { padding: 14px 16px; }
    .rdo-ss-address { flex-direction: column; }

    /* Mini-Card: Button unter statt neben den (oft umbrechenden) Adresstext.
       Etwas mehr Mindesthöhe als auf Desktop, da der Button jetzt eine eigene
       Zeile braucht und Text auf schmaler Breite eher umbricht. */
    .rdo-mini-card { min-height: 300px; }
    .rdo-mini-body {
        flex-direction: column;
        align-items: stretch;
    }
    .rdo-mini-info { align-self: stretch; }
    .rdo-mini-detail-btn {
        align-self: stretch;
        justify-content: center;
        margin-top: 4px;
    }
}

/* Enddatum: "Letzter Annahmetag" / "Saison beendet" ---------------
   Farben mit !important aus demselben Grund wie im modern-Layout: Divi-Module
   mit "Text Color: Light" vererben sonst weiße Schrift auf den hellen Kasten. */
.rdo-end-notice {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin: 8px 0;
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #e0a100;
    background: #fff8e1;
    color: #6b4a00 !important;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.35;
}
.rdo-end-notice-icon { flex-shrink: 0; }
.rdo-end-notice-text { color: inherit !important; }
.rdo-mini-status-row .rdo-end-notice { margin: 0; justify-content: center; text-align: center; }

.rdo-group-ended {
    margin: 4px 0 0;
    font-size: 13px;
    font-style: italic;
    color: #888 !important;
}

/* Popup + Card/List: letzter Annahmetag bzw. "Saison beendet" je Produkt
   rechts im Produktkopf (wie .rdo-modern-product-last), bricht bei wenig Platz
   unter den Produktnamen um. */
.rdo-ss-product-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 6px 10px;
}
.rdo-ss-product-title { flex: 1 1 auto; min-width: 0; }
.rdo-ss-product-last {
    font-size: 12px;
    font-weight: 700;
    color: #7a4d00 !important;
    background: #fff4d6;
    border: 1px solid #f0b429;
    border-radius: 999px;
    padding: 3px 10px;
    white-space: nowrap;
}
.rdo-ss-product-last--today {
    color: #fff !important;
    background: #c62828;
    border-color: #c62828;
}
.rdo-ss-product-last--ended {
    color: #555 !important;
    background: #eee;
    border-color: #ccc;
}
.rdo-ss-product-group--ended { background: #f3f3f3; }
.rdo-ss-product-group--ended .rdo-ss-product-name { color: #777 !important; }
.rdo-ss-product-group--ended .rdo-ss-product-name::before { background: #aaa; }
@media (max-width: 480px) {
    .rdo-ss-product-last { white-space: normal; }
}

/* ------------------------------------------------------------------ */
/*  „Bei Änderungen benachrichtigen“ (E-Mail-Abo)                       */
/*  Farben mit !important – Divi „Text Color: Light“ vererbt sonst Weiß  */
/* ------------------------------------------------------------------ */
.rdo-abo {
    margin: 20px 0 0;
    padding: 14px 16px;
    background: var(--rdo-green-light);
    border: 1px solid #cfe3c9;
    border-radius: 10px;
    color: #2b3a28 !important;
    font-size: 14px;
    line-height: 1.5;
    text-align: left;
}
.rdo-abo:not(.is-open) {
    padding: 0;
    background: transparent;
    border: 0;
}
.rdo-abo .rdo-abo-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    background: #fff !important;
    color: var(--rdo-green-dark) !important;
    border: 2px solid var(--rdo-green);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}
.rdo-abo .rdo-abo-toggle:hover { background: var(--rdo-green-light) !important; }
.rdo-abo .rdo-abo-toggle[hidden],
.rdo-abo .rdo-abo-form[hidden],
.rdo-abo [hidden] { display: none !important; }
.rdo-abo p, .rdo-abo label, .rdo-abo strong { color: #2b3a28 !important; }
.rdo-abo .rdo-abo-intro { margin: 0 0 10px; padding: 0; }
.rdo-abo .rdo-abo-label { display: block; margin: 8px 0 4px; font-weight: 600; font-size: 13px; }
.rdo-abo .rdo-abo-email,
.rdo-abo .rdo-abo-select {
    width: 100%;
    box-sizing: border-box;
    padding: 9px 12px;
    border: 1px solid var(--rdo-border);
    border-radius: 8px;
    background: #fff !important;
    color: #222 !important;
    font-size: 15px;
}
.rdo-abo .rdo-abo-submit {
    margin-top: 10px;
    padding: 9px 22px;
    background: var(--rdo-green) !important;
    color: #fff !important;
    border: 0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}
.rdo-abo .rdo-abo-submit:hover { background: var(--rdo-green-dark) !important; }
.rdo-abo .rdo-abo-submit:disabled { opacity: .6; cursor: wait; }
.rdo-abo .rdo-abo-hint { margin: 10px 0 0; padding: 0; font-size: 12px; color: #5b6b57 !important; }
.rdo-abo .rdo-abo-hint a { color: var(--rdo-green-dark) !important; text-decoration: underline; }
.rdo-abo .rdo-abo-msg { margin: 10px 0 0; padding: 8px 12px; border-radius: 8px; font-weight: 600; }
.rdo-abo .rdo-abo-msg.is-ok    { background: #fff; color: var(--rdo-green-dark) !important; }
.rdo-abo .rdo-abo-msg.is-error { background: #fff4e9; color: #8a3c10 !important; }
/* Honeypot – für Menschen unsichtbar, aber nicht display:none (manche Bots ignorieren das) */
.rdo-abo .rdo-abo-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* Abo-Button im Modern-Layout immer unten an der Karte (Karten einer Reihe sind per JS gleich hoch).
   Flex-Spalte statt Block: Abstände zwischen Kindern addieren sich hier statt zu kollabieren –
   deshalb den oberen Rand des Ende-Hinweises unter den Badges auf 0 setzen (vorher 20px kollabiert). */
.rdo-layout-modern { display: flex; flex-direction: column; }
.rdo-layout-modern > .rdo-end-notice { margin-top: 0; }
.rdo-layout-modern > .rdo-abo { margin-top: auto; }
.rdo-layout-modern > :has(+ .rdo-abo) { margin-bottom: 20px; }

/* Abo-Leiste unten in der Mini-Karte („Bei Änderungen benachrichtigen“) ----------------------
   Volle Breite am Kartenfuß, hellgrün mit leicht wackelnder Glocke, damit sie auffällt.
   Farben mit !important wegen Divi-Textfarben-Vererbung. */
.rdo-mini-card .rdo-mini-abo-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin: 0;
    padding: 11px 16px;
    background: var(--rdo-green-light) !important;
    color: var(--rdo-green-dark) !important;
    border: 0;
    border-top: 1px solid #cfe3c9;
    border-radius: 0;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
    cursor: pointer;
    transition: background .15s;
}
.rdo-mini-card .rdo-mini-abo-btn:hover,
.rdo-mini-card .rdo-mini-abo-btn:focus-visible {
    background: #d6ebd0 !important;
}
.rdo-mini-abo-bell {
    display: inline-block;
    font-size: 16px;
    transform-origin: 50% 10%;
    animation: rdoBellRing 4s ease-in-out infinite;
}
.rdo-mini-abo-btn:hover .rdo-mini-abo-bell { animation-duration: 1s; }
@keyframes rdoBellRing {
    0%, 80%, 100% { transform: rotate(0); }
    84% { transform: rotate(16deg); }
    88% { transform: rotate(-14deg); }
    92% { transform: rotate(10deg); }
    96% { transform: rotate(-6deg); }
}
@media (prefers-reduced-motion: reduce) {
    .rdo-mini-abo-bell { animation: none; }
}
