.yps-products-wrap {
    --yps-columns: 3;
    --yps-primary: #0f766e;
    --yps-primary-dark: #064e3b;
    --yps-border: rgba(15, 23, 42, 0.10);
    --yps-text: #0f172a;
    --yps-muted: #64748b;
    width: 100%;
}

.yps-products-grid {
    display: grid;
    grid-template-columns: repeat(var(--yps-columns), minmax(0, 1fr));
    gap: 28px;
}

.yps-product-card {
    overflow: hidden;
    border: 1px solid var(--yps-border);
    border-radius: 24px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 20px 55px rgba(15, 23, 42, 0.10);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.yps-product-card:hover {
    transform: translateY(-7px);
    border-color: rgba(15, 118, 110, 0.35);
    box-shadow: 0 30px 75px rgba(15, 23, 42, 0.16);
}

.yps-product-media {
    position: relative;
    padding: 14px 14px 0;
}

.yps-slider {
    position: relative;
    overflow: hidden;
    height: 265px;
    border-radius: 20px;
    background: #e2e8f0;
}

.yps-slider-track {
    display: flex;
    height: 100%;
    transition: transform 0.55s ease;
}

.yps-slide {
    min-width: 100%;
    height: 100%;
    overflow: hidden;
}

.yps-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transform: scale(1);
    transition: transform 0.7s ease;
}

.yps-slider:hover .yps-slide img {
    transform: scale(1.12);
}

.yps-slider-btn {
    position: absolute;
    top: 50%;
    z-index: 3;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    color: var(--yps-text);
    box-shadow: 0 12px 25px rgba(15, 23, 42, 0.18);
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
    transform: translateY(-50%);
    transition: transform 0.25s ease, background 0.25s ease;
}

.yps-slider-btn:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.08);
}

.yps-prev {
    left: 12px;
}

.yps-next {
    right: 12px;
}

.yps-slider-dots {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 12px;
    z-index: 4;
    display: flex;
    justify-content: center;
    gap: 7px;
}

.yps-slider-dot {
    width: 8px;
    height: 8px;
    border: 0;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.65);
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.yps-slider-dot.is-active {
    width: 24px;
    background: #fff;
}

.yps-empty-image {
    height: 265px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    color: #64748b;
    font-weight: 700;
}

.yps-product-content {
    padding: 22px 24px 24px;
}

.yps-product-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.yps-product-cats span {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(15, 118, 110, 0.10);
    color: var(--yps-primary-dark);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.yps-product-title {
    margin: 0 0 10px;
    color: var(--yps-text);
    font-size: 22px;
    line-height: 1.25;
    font-weight: 800;
}

.yps-product-desc {
    color: var(--yps-muted);
    font-size: 15px;
    line-height: 1.75;
}

.yps-product-desc p {
    margin: 0;
}

.yps-product-features {
    list-style: none;
    margin: 17px 0 0;
    padding: 0;
    display: grid;
    gap: 9px;
}

.yps-product-features li {
    position: relative;
    padding-left: 26px;
    color: #334155;
    font-size: 14px;
    font-weight: 600;
}

.yps-product-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 0;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--yps-primary);
    color: #fff;
    font-size: 12px;
    line-height: 1;
}

.yps-product-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 11px;
    margin-top: 22px;
}

.yps-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 12px 18px;
    border-radius: 14px;
    text-decoration: none !important;
    font-size: 14px;
    font-weight: 800;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.yps-btn:hover {
    transform: translateY(-2px);
}

.yps-btn-primary {
    background: linear-gradient(135deg, var(--yps-primary), var(--yps-primary-dark));
    color: #fff !important;
    box-shadow: 0 14px 30px rgba(15, 118, 110, 0.25);
}

.yps-btn-secondary {
    background: #fff;
    color: var(--yps-text) !important;
    border: 1px solid var(--yps-border);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.yps-no-products {
    padding: 20px;
    border: 1px dashed var(--yps-border);
    border-radius: 16px;
    color: var(--yps-muted);
}

@media (max-width: 1024px) {
    .yps-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .yps-products-grid {
        grid-template-columns: 1fr;
    }

    .yps-slider,
    .yps-empty-image {
        height: 230px;
    }

    .yps-product-content {
        padding: 19px 18px 21px;
    }
}

.yps-product-title a {
    color: inherit;
    text-decoration: none !important;
}

.yps-product-title a:hover {
    color: var(--yps-primary);
}

.yps-related-section {
    --yps-columns: 3;
    --yps-primary: #0f766e;
    --yps-primary-dark: #064e3b;
    --yps-border: rgba(15, 23, 42, 0.10);
    --yps-text: #0f172a;
    --yps-muted: #64748b;
    --yps-carousel-gap: 28px;
    margin-top: 52px;
    padding-top: 34px;
    border-top: 1px solid var(--yps-border);
}

.yps-related-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.yps-related-header h2 {
    margin: 0;
    color: var(--yps-text);
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
    font-weight: 900;
}

.yps-carousel-controls {
    display: flex;
    gap: 10px;
    flex: 0 0 auto;
}

.yps-carousel-btn {
    width: 44px;
    height: 44px;
    border: 1px solid var(--yps-border);
    border-radius: 999px;
    background: #fff;
    color: var(--yps-text);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.10);
    cursor: pointer;
    font-size: 30px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease;
}

.yps-carousel-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.14);
}

.yps-carousel-btn:disabled {
    opacity: 0.42;
    cursor: not-allowed;
    transform: none;
}

.yps-carousel-viewport {
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scrollbar-width: none;
    padding: 4px 2px 20px;
}

.yps-carousel-viewport::-webkit-scrollbar {
    display: none;
}

.yps-carousel-track {
    display: flex;
    gap: var(--yps-carousel-gap);
    align-items: stretch;
}

.yps-carousel-item {
    flex: 0 0 calc((100% - (var(--yps-carousel-gap) * 2)) / 3);
    min-width: 0;
}

.yps-carousel-item .yps-product-card {
    height: 100%;
}

@media (max-width: 1024px) {
    .yps-carousel-item {
        flex-basis: calc((100% - var(--yps-carousel-gap)) / 2);
    }
}

@media (max-width: 640px) {
    .yps-related-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .yps-carousel-item {
        flex-basis: 88%;
    }

    .yps-carousel-controls {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Catalog cards: WooCommerce-style product listing */
.yps-product-card {
    position: relative;
}

.yps-product-card-catalog .yps-product-content {
    text-align: center;
    padding: 20px 22px 24px;
}

.yps-product-card-catalog .yps-product-cats {
    justify-content: center;
}

.yps-product-card-catalog .yps-product-title {
    margin-bottom: 0;
}

.yps-card-click-area {
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: 24px;
}

.yps-product-card .yps-slider-btn,
.yps-product-card .yps-slider-dots,
.yps-product-title a,
.yps-product-actions a {
    position: relative;
    z-index: 5;
}

.yps-product-card-catalog:hover .yps-product-title a {
    color: var(--yps-primary);
}

/* Single product detail page */
.yps-single-product {
    --yps-primary: #0f766e;
    --yps-primary-dark: #064e3b;
    --yps-border: rgba(15, 23, 42, 0.10);
    --yps-text: #0f172a;
    --yps-muted: #64748b;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
    gap: 38px;
    align-items: start;
    margin: 10px 0 42px;
}

.yps-single-media,
.yps-single-summary,
.yps-single-description {
    border: 1px solid var(--yps-border);
    border-radius: 28px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.10);
}

.yps-single-media {
    padding: 16px;
}

.yps-single-summary {
    padding: 34px;
}

.yps-single-slider,
.yps-empty-image.yps-single-slider {
    height: 520px;
    border-radius: 22px;
    background: #f8fafc;
}

.yps-single-slider .yps-slide img {
    object-fit: contain;
    background: #f8fafc;
}

.yps-single-title {
    margin: 0 0 18px;
    color: var(--yps-text);
    font-size: clamp(32px, 4vw, 54px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.yps-single-excerpt {
    color: var(--yps-muted);
    font-size: 17px;
    line-height: 1.8;
    margin-bottom: 24px;
}

.yps-single-excerpt p {
    margin: 0;
}

.yps-single-feature-box {
    margin-top: 24px;
    padding: 22px;
    border-radius: 22px;
    background: rgba(15, 118, 110, 0.06);
    border: 1px solid rgba(15, 118, 110, 0.12);
}

.yps-single-feature-box h3 {
    margin: 0 0 14px;
    color: var(--yps-text);
    font-size: 20px;
    font-weight: 900;
}

.yps-single-actions {
    margin-top: 28px;
}

.yps-single-description {
    --yps-text: #0f172a;
    --yps-muted: #64748b;
    margin-top: 34px;
    padding: 34px;
}

.yps-single-description h2 {
    margin: 0 0 18px;
    color: var(--yps-text);
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
    font-weight: 900;
}

.yps-single-description-content {
    color: var(--yps-muted);
    font-size: 16px;
    line-height: 1.85;
}

.yps-single-description-content p:last-child {
    margin-bottom: 0;
}

@media (max-width: 900px) {
    .yps-single-product {
        grid-template-columns: 1fr;
    }

    .yps-single-slider,
    .yps-empty-image.yps-single-slider {
        height: 420px;
    }
}

@media (max-width: 640px) {
    .yps-single-summary,
    .yps-single-description {
        padding: 24px 20px;
    }

    .yps-single-slider,
    .yps-empty-image.yps-single-slider {
        height: 310px;
    }
}

/* Forced plugin single-product page wrapper */
.yps-single-page-main {
    --yps-primary: #0f766e;
    --yps-primary-dark: #064e3b;
    --yps-border: rgba(15, 23, 42, 0.10);
    --yps-text: #0f172a;
    --yps-muted: #64748b;
    padding: 60px 18px;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 45%, #f8fafc 100%);
}

.yps-single-page-container {
    width: min(1180px, 100%);
    margin: 0 auto;
}

.yps-single-description-content img {
    max-width: 100%;
    height: auto;
    border-radius: 18px;
}

.yps-products-wrap .yps-product-card-catalog .yps-slider,
.yps-related-section .yps-product-card-catalog .yps-slider {
    cursor: pointer;
}
