/* Featured image */
.rm-img-cover {
    display: flex;
    align-items: stretch;
}
.rm-img-cover .elementor-widget-container,
.rm-img-cover .elementor-widget-image {
    width: 100%;
}
.rm-img-cover img {
    width: 100% !important;
    height: 100% !important;
    aspect-ratio: 3 / 4;
    object-fit: cover !important;
    object-position: center top !important;
    display: block;
    transform: none !important;
    transition: none !important;
}

.rm-dietary-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 28px;
    margin-top: 4px;
}

.rm-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-size: 15px;
    text-align: center;
    color: #000000;
    text-decoration: none;
}
.rm-badge:hover {
    opacity: 0.8;
    color: #000000;
}
.rm-badge-icon {
    display: block;
    width: 40px;
    height: 40px;
    background-color: #000000;
    -webkit-mask-image: var(--rm-icon);
    mask-image: var(--rm-icon);
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
}
.rm-time-text {
    color: #000000;
}

.rm-ingredient-group-name {
    font-weight: 700;
    margin: 12px 0 4px;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.05em;
}
.rm-ingredient-list {
    margin: 0 0 8px 0;
    padding-left: 18px;
}
.rm-steps {
    padding-left: 0;
    counter-reset: rm-step;
    list-style: none;
    margin: 0;
}
.rm-steps li {
    counter-increment: rm-step;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 24px;
    line-height: 1.7;
}
.rm-steps li::before {
    content: counter(rm-step);
    font-size: 64px;
    font-weight: 700;
    line-height: 0.8;
    min-width: 36px;
    flex-shrink: 0;
    color: currentColor;
    opacity: 0.85;
    margin-top: -18px;
}

/* Gallery */
.rm-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.rm-gallery-img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 20px !important;
    display: block;
}

/* Recipe section headings */
.rm-section-h3 {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-bottom: 24px;
}

.rm-gallery-link {
    display: block;
    border-radius: 20px;
    overflow: hidden;
}

/* Dále potřebujeme – zarovnání k nadpisu */
.rm-potrebujeme-list {
    padding-left: 0 !important;
    margin-left: 0 !important;
    margin-top: 0;
    list-style-position: inside;
}

/* Tlačítko tisku – plovoucí nad scroll-to-top */
.rm-print-btn {
    position: fixed;
    right: 20px;
    bottom: 75px;
    top: auto;
    transform: none;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    padding: 0;
    border: none;
    border-radius: 4px;
    background: rgba(40, 25, 10, 0.75);
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    cursor: pointer;
    color: #fff !important;
    transition: background 0.2s, box-shadow 0.2s;
}
.rm-print-btn:hover {
    background: rgba(40, 25, 10, 0.95);
    color: #fff !important;
    box-shadow: 0 6px 24px rgba(0,0,0,0.35);
}
.rm-print-btn svg { width: 22px; height: 22px; flex-shrink: 0; stroke: #fff !important; }

/* ── Mobil / tablet ── */
@media (max-width: 1024px) {
    .rm-print-btn { display: none !important; }
}

@media (max-width: 767px) {
    .rm-dietary-badges { justify-content: center; }
    .rm-time-text { display: block; text-align: center; width: 100%; }

    /* Odstraň negativní margin a přetékající šířku barevných boxů */
    .elementor-4433 .elementor-element.elementor-element-ae17166,
    .elementor-4433 .elementor-element.elementor-element-731520e,
    .elementor-4433 .elementor-element.elementor-element-5e902d6 {
        margin-left: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    /* Kontejner s titulkem/dietou/časem – plná šířka */
    .elementor-4433 .elementor-element.elementor-element-de98576 {
        width: 100% !important;
        max-width: 100% !important;
        flex-grow: 1 !important;
    }

    /* Nadpis receptu – vycentrovat */
    .elementor-4433 .elementor-element.elementor-element-e618ddc .elementor-heading-title {
        text-align: center !important;
    }

    /* Čas přípravy – vycentrovat */
    .elementor-4433 .elementor-element.elementor-element-d5a9fe5 {
        align-items: center !important;
        justify-content: center !important;
        text-align: center !important;
    }
}

/* ── Print ── */
@media print {
    /* Skrýt header, footer, navigaci, tlačítka */
    .elementor-location-header,
    .elementor-location-footer,
    .rm-print-btn,
    .rm-img-cover,
    .rm-gallery { display: none !important; }

    /* Skrýt všechny obrázky */
    img { display: none !important; }

    /* Zachovat text dietních odznaků */
    .rm-badge { color: #000 !important; }

    /* Čistý černobílý výtisk */
    * {
        color: #000 !important;
        background: #fff !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }

    body { font-size: 12pt; }

    /* Rozložení na celou šířku */
    .elementor-section,
    .elementor-container,
    .elementor-column,
    .elementor-widget-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
        float: none !important;
    }

    /* Krok recepty – menší čísla pro tisk */
    .rm-steps li::before {
        font-size: 32pt;
        margin-top: -8px;
    }

    /* Nevkládat prázdné stránky mezi sloupce */
    .elementor-column { page-break-inside: avoid; }
}
