/**
 * Theme Name:     Baltic Shores
 * Author:         Extendify
 * Template:       extendable
 * Text Domain:	   Baltic Shores
 * Description:    Extendable is a distinct, dynamic block theme designed as a canvas for your next online venture. Sporting multiple style variations, Extendable is the most expressive block theme yet. Go fresh, bold, bohemian or minimal — with a single click.
 */



/* Baltic Shores – About Bosun title spacing */
body.page-id-1862 h1 {
    margin-bottom: 32px !important;
}


/* ALAPEALKIRI H5 */

.alapealkiri {
	line-height: 1.2em;
	transform: translateY(-20px);
	text-transform: uppercase;
}


/* BOSUN APPROVED STAMP */

.bosun-approved {
    position: relative;
    display: inline-block;
    margin: 12px 0 24px;
    border: 0 !important;
}

.bosun-approved > summary {
    display: block;
    list-style: none;
    cursor: pointer;
    border: 0 !important;
    outline: none !important;
}

.bosun-approved > summary::-webkit-details-marker {
    display: none;
}

.bosun-approved > summary::marker {
    content: "";
}

.bosun-approved > summary img {
    display: block;
    width: 120px;
    height: auto;
    border: 0;
    transition: transform 0.25s ease;
}

.bosun-approved > summary:hover img {
    transform: scale(1.08);
}

/* Bosun popup */

.bosun-approved-popup {
    position: static;
    width: 340px;
    max-width: calc(100vw - 40px);
    box-sizing: border-box;
    padding: 18px;
    margin-top: 0;
    background: #fffaf5;
    border: 1px solid #c9a47e;
    border-radius: 8px;
    box-shadow: 0 5px 18px rgba(0,0,0,0.12);
    color: #542d32;
    font-size: 14px;
    line-height: 1.5;
}

.bosun-approved-popup p {
    margin: 8px 0 0;
}

/* Bosun popup close button */

.bosun-approved-popup {
    position: relative;
}

.bosun-approved-popup .bosun-close {
    position: absolute;
    top: 7px;
    right: 9px;
    padding: 2px 6px;
    border: none;
    background: transparent;
    color: #542d32;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}

.bosun-approved-popup .bosun-close:hover {
    color: #c9a47e;
}


/* =========================================
   BALTIC SHORES – UNIFIED PRODUCT CARDS
   ========================================= */

/* Product card */

.wc-block-product {
    position: relative;
    background: transparent !important;
}

/* Remove default card backgrounds and spacing */

.wc-block-product .wp-block-group {
    background: transparent !important;
    padding: 0 !important;
}

/* Product image */

.wc-block-product .wc-block-components-product-image {
    position: relative !important;
    display: block;
    overflow: hidden;
    margin: 0 !important;
}

.wc-block-product .wc-block-components-product-image > a {
    display: block;
}

/* Category badge – top left */

.wc-block-product .bs-product-category-badge {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 5;

    display: block;
    padding: 7px 11px;

    background: #c9a47e;
    color: #ffffff;

    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.08em;
    line-height: 1.2;
    text-transform: uppercase;

    pointer-events: none;
}

/* Price badge – bottom right */

.wc-block-product .bs-product-price-badge {
    position: absolute !important;
    right: 0;
    bottom: 0;
    z-index: 5;

    width: auto !important;
    margin: 0 !important;
    padding: 7px 11px !important;

    background: #ffffff;
    color: #542d32;

    font-size: 13px !important;
    line-height: 1.2;
    text-align: right;

    pointer-events: none;
}

/* Product title */

.wc-block-product .wp-block-post-title {
    margin: 11px 0 0 !important;

    font-size: 13px !important;
    font-weight: 400 !important;
    line-height: 1.4 !important;

    letter-spacing: 0.07em;
    text-align: center;
    text-transform: uppercase;
}

/* Remove Add to Cart / Select options */

.wc-block-product .wp-block-woocommerce-product-button {
    display: none !important;
}

/* Remove unnecessary spacer */

.wc-block-product .wp-block-spacer {
    display: none !important;
}

/* Remove empty paragraph */

.wc-block-product .wp-block-paragraph:empty {
    display: none !important;
}

/* Mobile adjustments */

@media (max-width: 600px) {

    .wc-block-product .bs-product-category-badge {
        padding: 5px 7px;
        font-size: 9px;
    }

    .wc-block-product .bs-product-price-badge {
        padding: 5px 7px !important;
        font-size: 11px !important;
    }

    .wc-block-product .wp-block-post-title {
        font-size: 11px !important;
    }

}

/* Baltic Shores – WooCommerce product title alignment */

.wc-block-product > .wp-block-group > .wp-block-group {
    width: 100% !important;
    max-width: 100% !important;
}

.wc-block-product .wp-block-post-title {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    text-align: center !important;
    box-sizing: border-box;
}

.wc-block-product .wp-block-post-title a {
    display: block;
    width: 100%;
    text-align: center !important;
}


/* Reduce image-to-content spacing in product cards */

.wc-block-product .ext-card {
    gap: 0px !important;
}

.wc-block-product .ext-card > .wp-block-group {
    margin-top: 0 !important;
}


/* Bosun Approved stamp on product images */

.wc-block-components-product-image {
    position: relative;
}

.bosun-product-stamp {
    position: absolute;
    bottom: 10px;
    left: 10px;
    width: 60px;
    height: 60px;
    z-index: 5;
    pointer-events: none;
}

.bosun-product-stamp img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Hide Bosun stamp on the main product gallery image */
body.single-product
.wc-block-components-product-image:has(img.wc-block-woocommerce-product-gallery-large-image__image)
.bosun-product-stamp {
    display: none !important;
}



/* =========================================
   BALTIC SHORES – HERO SLIDER
   ========================================= */

.bsh-hero-slider {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

/* Slideri pildikihid ja videokihid */

.bsh-hero-slider .bsh-slide-layer {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    pointer-events: none;
}

.bsh-hero-slider .bsh-slide-layer.is-active {
    opacity: 1;
    pointer-events: auto;
}

/* Piltide ja videote suurendamine */

.bsh-hero-slider .bsh-slide-layer img,
.bsh-hero-slider .bsh-slide-layer video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1);
    transition: transform 5s linear;
}

.bsh-hero-slider .bsh-slide-layer.is-active img,
.bsh-hero-slider .bsh-slide-layer.is-active video {
    transform: scale(1.1);
}

/* Navigeerimispunktid */

.bsh-hero-slider .bsh-slider-dots {
    position: absolute;
    z-index: 5;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

/* Punktide välimus */

.bsh-hero-slider .bsh-slider-dot {
    width: 9px;
    height: 9px;
    padding: 0;
    border: 1px solid #ffffff;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: background 0.3s ease,
                transform 0.3s ease;
}

.bsh-hero-slider .bsh-slider-dot.is-active {
    background: #ffffff;
    transform: scale(1.25);
}

@media (prefers-reduced-motion: reduce) {
    .bsh-hero-slider .bsh-slide-layer,
    .bsh-hero-slider .bsh-slide-layer img,
    .bsh-hero-slider .bsh-slide-layer video {
        transition: none;
    }
}


/* Prevent zoom bounce during slide transition */

.bsh-hero-slider .bsh-slide-layer.is-leaving img {
    transform: scale(1.1);
    transition: none;
}


/* Baltic Shores – continuous zoom during transition */

.bsh-hero-slider .bsh-slide-layer img,
.bsh-hero-slider .bsh-slide-layer video {
    transition: transform 6s linear;
}

.bsh-hero-slider .bsh-slide-layer.is-active img,
.bsh-hero-slider .bsh-slide-layer.is-active video {
    transform: scale(1.12);
}

.bsh-hero-slider .bsh-slide-layer.is-leaving img,
.bsh-hero-slider .bsh-slide-layer.is-leaving video {
    transform: scale(1.12);
    transition: transform 1s linear;
}


/* Prevent initial hero image zoom jump */

.bsh-hero-slider .bsh-slide-layer.is-initial img {
    transform: scale(1.12);
    transition: none;
}

/* Prevent hero image jump before slider initializes */

.bsh-hero-slider > .wp-block-cover__image-background {
    transform: scale(1.12) !important;
    transition: none !important;
}

/* Baltic Shores – no zoom on videos */
.bsh-hero-slider .bsh-slide-layer video,
.bsh-hero-slider .bsh-slide-layer.is-active video,
.bsh-hero-slider .bsh-slide-layer.is-leaving video {
    transform: scale(1);
    transition: none;
}


/* Baltic Shores – hero text fade-in */

.bsh-hero-slider .bsh-copy-title,
.bsh-hero-slider .bsh-copy-text,
.bsh-hero-slider .bsh-copy-button {
    opacity: 1;
    transition: opacity 0.6s ease;
}

/* Staggered appearance */
.bsh-hero-slider .bsh-copy-title {
    transition-delay: 0.15s;
}

.bsh-hero-slider .bsh-copy-text {
    transition-delay: 0.4s;
}

.bsh-hero-slider .bsh-copy-button {
    transition-delay: 0.65s;
}

/* Hidden state */
.bsh-hero-slider .bsh-copy-hidden {
    opacity: 0 !important;
    transition-delay: 0s !important;
}


/* Baltic Shores – fixed hero text area */

/* Title – reserve space for 2 lines */
.bsh-hero-slider .bsh-copy-title {
    line-height: 1.0;
    height: 2.5em;
    overflow: hidden;
    box-sizing: border-box;
	align-content: center;
	max-width: 75%;
	margin: 0 auto;
}

/* Description – reserve space for 3 lines */
.bsh-hero-slider .bsh-copy-text {
    line-height: 1.2;
    height: 4.5em;
    overflow: hidden;
    box-sizing: border-box;
	align-content: center;
	max-width: 50%;
	margin: 0 auto;
}

/* Mobile adjustments */
@media (max-width: 767px) {

/* Title – reserve space for 3 lines */
    .bsh-hero-slider .bsh-copy-title {
        height: 2.4em;
    }

/* Description – reserve space for 4 lines */
    .bsh-hero-slider .bsh-copy-text {
        height: 6em;
		max-width: 75%;
    }

}



/* Baltic Shores – product search width */

.wp-block-search.wp-block-search__button-outside {
    width: 450px !important;
    max-width: 100% !important;
}

.wp-block-search__inside-wrapper {
    width: 100% !important;
    max-width: none !important;
    box-sizing: border-box;
}



/* Baltic Shores – footer layout */

/* Baltic Shores – footer desktop */

.bsh-footer-row {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    align-items: center !important;
    width: 100% !important;
    gap: 0 !important;
}

/* Brand – left */
.bsh-footer-row > :nth-child(1) {
    justify-self: start;
}

/* Email – centered */
.bsh-footer-row > :nth-child(2) {
    justify-self: center;
    text-align: center;
}

/* Copyright – centered */
.bsh-footer-row > :nth-child(3) {
    justify-self: center;
    text-align: center;
}

/* Pinterest – right */
.bsh-footer-row > :nth-child(4) {
    justify-self: end;
}

/* Mobile layout */

@media (max-width: 781px) {

    .bsh-footer-row {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 14px !important;
    }

    .bsh-footer-row > * {
        justify-self: auto;
        text-align: left;
    }

    .bsh-footer-row .wp-block-social-links {
        justify-content: flex-start;
        margin-left: 0;
    }
}