/* WC Category Popups — Frontend Styles
   Compatibel met WoodMart thema (inherits body font, button vars)
   ---------------------------------------------------------------- */

/* Overlay */
.wccp-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.62);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: wccp-fade-in 0.22s ease forwards;
}

@keyframes wccp-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* Popup container */
.wccp-popup {
    position: relative;
    background: #f8f8f8;
    border-radius: 0;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22);
    max-width: 100%;
    width: var(--wccp-width, 520px);
    max-height: 90vh;
    overflow-y: auto;
    animation: wccp-slide-up 0.28s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes wccp-slide-up {
    from { opacity: 0; transform: translateY(28px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* Inner layout */
.wccp-popup__inner {
    display: flex;
    flex-direction: column;
}

.wccp-popup__image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px 8px 0 0;
    object-fit: cover;
    max-height: 260px;
}

.wccp-popup__body {
    padding: 32px 36px 36px;
}

/* Title */
.wccp-popup__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 14px;
    line-height: 1.25;
    color: #1a1a1a;
}

/* Content inherits WoodMart body styling */
.wccp-popup__content {
    font-size: 0.97rem;
    line-height: 1.65;
    color: #444;
    margin-bottom: 24px;
}

.wccp-popup__content p:last-child {
    margin-bottom: 0;
}

/* Actions */
.wccp-popup__actions {
    display: flex;
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: fit-content;
}
.wccp-popup__actions .wccp-close{
    display: block!important;
    position: static!important;
	
}
/* CTA button — mirrors WoodMart primary button */
.wccp-btn {
    display: inline-block;
    padding: 11px 28px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.18s ease, transform 0.12s ease;
    text-decoration: none;
    border: none;
    line-height: 1.4;
}

.wccp-btn--primary {
    background: var(--woodmart-primary-color, #222);
    color: #fff;
}
.wccp-btn--primary:hover {
    background: var(--woodmart-primary-color-hover, #444);
    color: #fff;
    transform: translateY(-1px);
}

.wccp-btn--secondary {
    background: transparent;
    color: var(--woodmart-primary-color, #222);
    border: 2px solid var(--woodmart-primary-color, #222);
}
.wccp-btn--secondary:hover {
    background: var(--woodmart-primary-color, #222);
    color: #fff;
}

/* Close button — inside popup */
.wccp-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: #888;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
    z-index: 1;
}
.wccp-close:hover {
    color: #1a1a1a;
    background: #f5f5f5;
}

/* Close button — outside popup */
.wccp-close--outside {
    position: fixed;
    top: 18px;
    right: 22px;
    background: #fff;
    color: #333;
    font-size: 1.2rem;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}

/* Text alignment variants */
.wccp-align--left  .wccp-popup__body { text-align: left; }
.wccp-align--left  .wccp-popup__actions { justify-content: flex-start; }
.wccp-align--center .wccp-popup__body { text-align: center; }
.wccp-align--center .wccp-popup__actions { justify-content: center; }
.wccp-align--right .wccp-popup__body { text-align: right; }
.wccp-align--right .wccp-popup__actions { justify-content: flex-end; }

/* Mobile */
@media (max-width: 600px) {
    .wccp-popup__body {
        padding: 20px 0 0 0;
    }
	.wccp-popup__actions{
    position: static;
		padding-top:20px;
		
	}
	.wd-product-img-link img{
		
    max-height: 27dvh;
    object-fit: contain;
	}
    .wccp-popup__title {
        font-size: 1.25rem;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .wccp-overlay,
    .wccp-popup {
        animation: none;
    }
}


.products-for-popup > .wd-products{
	display:flex!important;
	max-height:min(500px,70dvh);
	justify-content:center!important;
}
.products-for-popup .wd-product-img-link img:not(:nth-of-type(1)){
	display:none!important;
}
.wccp-close{
    top: 0;
    left: 0;
	
}