/* Accessibility: visually hide the skip link until it receives focus */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

.skip-link.screen-reader-text:focus {
    background-color: #fff;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 14px;
    font-weight: 700;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* Sticky header variation */
.wp-site-blocks > header:has(.rinico-header-sticky) {
    position: sticky;
    top: 0;
    z-index: 100;
}

.admin-bar .wp-site-blocks > header:has(.rinico-header-sticky) {
    top: 32px;
}

@media (max-width: 782px) {
    .admin-bar .wp-site-blocks > header:has(.rinico-header-sticky) {
        top: 46px;
    }
}

/* Fallback when a saved Global Styles palette predates the Surface color */
.has-surface-color-background-color {
    background-color: var(--wp--preset--color--surface-color, #94969926);
}

/* Visible keyboard focus */
:where(a, button, input, select, textarea, summary, .wp-element-button):focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* Light body text on dark backgrounds (the default text color is dark gray) */
.has-title-link-color-background-color:not(.has-text-color) {
    color: var(--wp--preset--color--text-color);
}

/* WooCommerce */
.wc-block-components-product-sale-badge,
.woocommerce span.onsale {
    border: 0;
    border-radius: 50px;
    background-color: var(--wp--preset--color--primary-color);
    color: var(--wp--preset--color--title-link-color);
    font-weight: 600;
}

.wp-block-woocommerce-product-details h2,
.woocommerce-tabs h2 {
    font-size: var(--wp--preset--font-size--medium);
}

.woocommerce .wp-block-woocommerce-product-image-gallery {
    max-width: none;
}

/* Header: keep the logo readable and make room for shop icons on small screens */
header .wp-block-site-logo,
header .wp-block-image {
    flex-shrink: 0;
}

header .wp-block-button__link {
    white-space: nowrap;
}

@media (max-width: 480px) {
    header:has(.wp-block-woocommerce-mini-cart) .wp-block-buttons {
        display: none;
    }
}
