/* WCAG 2.2 AA. New file so the CDN does not keep an older stylesheet. */

html {
    scroll-padding-top: 5.5rem;
    scroll-padding-bottom: 4.5rem;
}

body:has(.cky-consent-container:not(.cky-hide)) {
    scroll-padding-bottom: 14rem;
}

#continut:focus {
    outline: 2px solid #2d5a1b;
    outline-offset: 2px;
}

.search-overlay-input:focus,
.search-overlay-input:focus-visible {
    outline: 2px solid #2d5a1b;
    outline-offset: 3px;
}

button.slider-dot:focus-visible,
button.zestrea-dot:focus-visible,
.udlb-motion-pause:focus-visible {
    outline: 2px solid #2d5a1b;
    outline-offset: 2px;
}

/*
 * WCAG 2.2 2.5.8: the control box itself must be ≥24×24 (scanners measure
 * getBoundingClientRect, not overflowing ::before). Keep the green disc at 10px.
 * Centres are then ≥24px apart, so hit areas do not overlap.
 */
.zestrea-dots {
    gap: 0.25rem;
}

button.zestrea-dot {
    box-sizing: border-box;
    position: relative;
    width: 24px !important;
    height: 24px !important;
    min-width: 24px;
    min-height: 24px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent !important;
    background-image: none !important;
    transform: none !important;
    overflow: visible;
}

button.zestrea-dot::before {
    content: none;
}

button.zestrea-dot::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    width: 10px;
    height: 10px;
    margin: -5px 0 0 -5px;
    border-radius: 50%;
    background: #029046;
    pointer-events: none;
}

button.zestrea-dot.activ::after,
button.zestrea-dot[aria-current="true"]::after {
    width: 15px;
    height: 15px;
    margin: -7.5px 0 0 -7.5px;
}

.taine-titlu {
    padding-top: 3.5rem;
}

/* Scroll fade must not leave this paragraph below 4.5:1. */
.brand-story-p {
    opacity: 1 !important;
}

/* White controls on a light photograph need a dark edge. Fill stays white.
   Scale only the dot. transition:all was also repainting the ring and the border,
   which made the 14px circle step from pixel to pixel. */
button.slider-dot {
    box-shadow: 0 0 0 1px #231f20;
    transform: translateZ(0) scale(1);
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
    backface-visibility: hidden;
}

button.slider-dot.active {
    transform: translateZ(0) scale(1.2);
}

@media (min-width: 992px) {
    .simple-scroll-slider .slider-dots-right {
        top: 0;
        bottom: 0;
        height: auto;
        transform: none;
        justify-content: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    button.slider-dot {
        transition: none;
    }
}

button.simple-slider-arrow {
    text-shadow:
        0 0 0 #231f20,
        1px 0 0 #231f20,
        -1px 0 0 #231f20,
        0 1px 0 #231f20,
        0 -1px 0 #231f20;
}

.udlb-motion-pause {
    position: fixed;
    z-index: 40;
    top: 5.5rem;
    right: 0.85rem;
    min-width: 24px;
    min-height: 24px;
    padding: 0.28rem 0.65rem;
    border: 1px solid rgba(45, 90, 27, 0.4);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #231f20;
    font-family: "EB Garamond", Georgia, serif;
    font-size: 0.78rem;
    line-height: 1.15;
    cursor: pointer;
    box-sizing: border-box;
}

html.udlb-motion-off *,
html.udlb-motion-off *::before,
html.udlb-motion-off *::after {
    animation-play-state: paused !important;
}

@media (prefers-reduced-motion: reduce) {
    html:not(.udlb-motion-on) *,
    html:not(.udlb-motion-on) *::before,
    html:not(.udlb-motion-on) *::after {
        animation-play-state: paused !important;
    }
}

html.udlb-motion-on *,
html.udlb-motion-on *::before,
html.udlb-motion-on *::after {
    animation-play-state: running !important;
}

/* Legal links are separate targets, not inline text. 24px tall, same type. */
.footer-dreapta a {
    min-height: 24px;
}

/*
 * Zestrea controls: main.css used gradient + background-clip:text, which painted
 * solid green bars and hid "Rețeta anterioară/următoare". Show real text at AA.
 */
.zestrea-arrow-sm {
    background: none !important;
    background-image: none !important;
    -webkit-background-clip: border-box !important;
    background-clip: border-box !important;
    color: #005327 !important;
    -webkit-text-fill-color: #005327 !important;
}

/* Light surfaces: the gold hover was about 2.3:1 on white. */
.site-header .nav-link-udlb:hover,
.header-search-btn:hover,
.taine-citeste:hover,
.produs-reteta-titlu a:hover,
.zestrea-arrow:hover,
.zestrea-arrow-sm:hover {
    color: #7a4e0a !important;
    -webkit-text-fill-color: #7a4e0a !important;
}

/* Dark footer only. Below 860px the footer panel is white, and this gold would fail. */
@media (min-width: 861px) {
    .footer-dreapta a:hover,
    .footer-stanga a:hover {
        color: #e8b04a;
    }
}

/* White text failed on these badge colors. The fill stays. */
.taine-badge--mediu,
.sidebar-cat-btn--retete {
    color: #1a1a1a;
}

.taine-badge--sfaturi,
.taine-badge--sfaturi-practice {
    color: #061416;
}

.sidebar-cat-btn:hover {
    opacity: 1;
}
