/* =================================================
   SINGLE PRODUCT – KrystalSpace Premium
   ================================================= */

/* --- SYSTEMOWE ZMIENNE --- */
:root {
    --ks-green: #22c55e;
    --ks-blue: #3b82f6;
    --ks-navy: #1e293b;
    --ks-slate: #64748b;
    --ks-bg-light: #f8fafc;
    --ks-gradient: linear-gradient(135deg, #22c55e, #3b82f6);
    --ks-transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* --- CONTAINER --- */
.ks-product-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- BREADCRUMBS --- */
.ks-breadcrumbs-wrap {
    padding: 30px 0;
    font-size: 14px;
    color: var(--ks-slate);
}
.ks-breadcrumbs-wrap a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}
.ks-breadcrumbs-wrap a:hover {
    color: var(--ks-blue);
}
.ks-breadcrumbs-wrap i {
    font-size: 10px;
    margin: 0 10px;
    opacity: 0.5;
}

/* --- GRID --- */
.ks-single-wrapper {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 70px;
    margin-bottom: 50px;
    align-items: start;
}

/* --- GALERIA --- */
.ks-gallery-sticky {
    position: sticky;
    top: 110px;
}
.ks-main-img-box {
    position: relative;
    border-radius: 30px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #f1f5f9;
    cursor: zoom-in;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 50px -15px rgba(59, 130, 246, 0.08);
}
#ks-zoom-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.2s ease-out;
}
.ks-thumb-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    margin-top: 20px;
}
.ks-thumb-link {
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid transparent;
    transition: var(--ks-transition);
    background: #fff;
}
.ks-thumb-link:hover {
    border-color: var(--ks-blue);
}

/* --- TYPOGRAFIA --- */
.ks-title-main {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 800;
    color: var(--ks-navy);
    margin-bottom: 15px;
    line-height: 1.1;
}
.ks-short-text {
    font-size: 17px;
    line-height: 1.7;
    color: var(--ks-slate);
    margin-bottom: 30px;
}

/* --- CENA --- */
.ks-price-display .price {
    font-size: 42px;
    font-weight: 800;
    color: var(--ks-navy);
    margin-bottom: 35px;
    display: block;
}
.ks-price-display ins {
    text-decoration: none;
}
.ks-price-display del {
    font-size: 24px;
    opacity: 0.3;
    margin-right: 15px;
}

/* --- ADD TO CART --- */
.ks-buy-row {
    display: flex;
    gap: 15px;
    align-items: stretch;
    margin-bottom: 20px;
}
.ks-add-to-cart-btn {
    flex-grow: 1;
    height: 60px;
    background: var(--ks-gradient);
    color: #fff !important;
    font-weight: 700;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: var(--ks-transition);
    box-shadow: 0 15px 30px rgba(59, 130, 246, 0.2);
}
.ks-add-to-cart-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.3);
}

/* --- PŁATNOŚCI --- */
.ks-secure-payments-wrapper {
    margin-top: 10px;
    padding: 20px;
    background: #fff;
    border: 1px dashed #cbd5e1;
    border-radius: 20px;
    text-align: center;
}
.ks-payment-header {
    font-size: 13px;
    font-weight: 700;
    color: var(--ks-navy);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.ks-payment-header i {
    color: var(--ks-green);
    font-size: 18px;
}
.ks-payment-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
    font-size: 28px;
    color: #cbd5e1;
    margin-top: 10px;
}

/* --- FEATURES BAR --- */
.ks-features-bar {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin: 25px 0;
}
.ks-feat-card {
    background: var(--ks-bg-light);
    padding: 15px 10px;
    border-radius: 15px;
    text-align: center;
    transition: 0.3s;
}
.ks-feat-card i {
    font-size: 24px;
    color: var(--ks-blue);
    margin-bottom: 8px;
    display: block;
}
.ks-feat-card span {
    font-size: 10px;
    font-weight: 800;
    color: var(--ks-navy);
    text-transform: uppercase;
}

/* --- TABS --- */
.ks-tabs-section {
    margin: 80px 0;
    background: #fff;
    border-radius: 40px;
    padding: 60px;
    border: 1px solid #f1f5f9;
}
.ks-tabs-nav {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-bottom: 50px;
    border-bottom: 1px solid #f1f5f9;
    flex-wrap: wrap;
}
.ks-tab-btn {
    padding: 15px 0;
    border: none;
    background: none;
    font-size: 18px;
    color: var(--ks-slate);
    cursor: pointer;
    position: relative;
}
.ks-tab-btn.active {
    color: var(--ks-blue);
    font-weight: 700;
}
.ks-tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--ks-gradient);
    border-radius: 10px;
}
.ks-tab-content {
    display: none;
    line-height: 1.8;
    color: #334155;
    font-size: 16px;
}
.ks-tab-content.active {
    display: block;
    animation: ksFadeUp 0.5s ease forwards;
}

@keyframes ksFadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- RWD --- */
@media (max-width: 1024px) {
    .ks-single-wrapper {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .ks-gallery-sticky {
        position: static;
    }
    .ks-tabs-section {
        padding: 30px 20px;
    }
}
