/**
 * Item (single-items) Styles
 * Modern design for product detail pages
 *
 * @package DonCarlo
 * @version 1.0.0
 */

/* ========================================
   Product Hero
   ======================================== */
.product-hero {
    position: relative;
    padding: 140px 0 80px;
    background-size: cover;
    background-position: center;
    color: var(--color-white);
    text-align: center;
    isolation: isolate;
}

.product-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: -1;
}

.product-hero .container {
    position: relative;
    z-index: 1;
}

.product-hero__title {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.product-hero__subtitle {
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto;
    opacity: 0.95;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* ========================================
   Product Overview
   ======================================== */
.product-overview {
    padding: 60px 0;
    background: var(--color-white);
}

.overview-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

/* Left Column – Images */
.overview-images {
    position: sticky;
    top: 100px;
}

.main-image {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
    background: #f5f5f5;
    box-shadow: var(--shadow-card);
}

.main-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.main-image:hover img {
    transform: scale(1.02);
}

.product-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    background: var(--color-red);
    color: white;
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.thumbnail-list {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.thumbnail {
    flex: 0 0 80px;
    height: 80px;
    border: 2px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    padding: 0;
    cursor: pointer;
    background: none;
    transition: all 0.2s;
}

.thumbnail.active {
    border-color: var(--color-primary);
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Right Column – Content */
.overview-content h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 15px;
}

.overview-content h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--color-primary);
}

.feature-list {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.feature-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--color-text);
}

.feature-list .checkmark {
    color: var(--color-primary);
    font-weight: 700;
    font-size: 16px;
}

.description {
    margin-bottom: 30px;
    font-size: 15px;
    line-height: 1.8;
    color: var(--color-text);
}

.tech-specs {
    background: #f9f9f9;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 30px;
}

.tech-specs h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-dark);
    margin-bottom: 16px;
}

.tech-specs dl {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 8px 16px;
    margin: 0;
}

.tech-specs dt {
    font-weight: 600;
    color: var(--color-dark);
    font-size: 14px;
}

.tech-specs dd {
    font-size: 14px;
    color: var(--color-text);
    margin: 0;
}

/* ========================================
   Benefits Section
   ======================================== */
.benefits-section {
    padding: 60px 0;
    background: #f8f9fa;
}

.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-header h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 12px;
}

.section-subtitle {
    font-size: 16px;
    color: var(--color-text);
    max-width: 600px;
    margin: 0 auto 16px;
}

.section-line {
    width: 60px;
    height: 3px;
    background: var(--color-primary);
    margin: 0 auto;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.benefit-card {
    background: var(--color-white);
    border-radius: 16px;
    padding: 30px 24px;
    text-align: center;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-card-hover);
}

.benefit-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 12px;
}

.benefit-card p {
    font-size: 14px;
    color: var(--color-text);
    line-height: 1.6;
    margin: 0;
}

/* ========================================
   Extra Sections
   ======================================== */
.extra-section {
    padding: 60px 0;
}

.extra-section:nth-child(even) {
    background: #f8f9fa;
}

.extra-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.extra-section--reverse .extra-grid {
    direction: rtl;
}

.extra-section--reverse .extra-content {
    direction: ltr;
}

.extra-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 15px;
}

.extra-content h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: var(--color-primary);
}

.extra-text {
    font-size: 15px;
    line-height: 1.8;
    color: var(--color-text);
}

.extra-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: var(--shadow-card);
}

/* ========================================
   Configuration Section
   ======================================== */
.config-section {
    padding: 60px 0;
    background: var(--color-white);
}

.config-tabs {
    margin-top: 40px;
}

.tab-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.tab-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text);
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 30px;
    position: relative;
}

.tab-btn:hover {
    color: var(--color-primary);
}

.tab-btn.active {
    background: var(--color-primary);
    color: white;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

.config-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.config-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    background: #f5f5f5;
}

.config-item:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-card-hover);
}

.config-item--normal {
    aspect-ratio: 1 / 1;
}

.config-item--wide {
    grid-column: span 2;
    aspect-ratio: 5 / 1;
}

.config-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.config-item__desc{
  font-size:14px;
  line-height:1.35;
  text-align:center;
  color:var(--color-dark);
  font-weight:600;
}

/* ========================================
   Gallery Section
   ======================================== */
.gallery-section {
    padding: 60px 0;
    background: #f8f9fa;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    transition: all 0.3s;
    background: #f5f5f5;
}

.gallery-item:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-card-hover);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* ========================================
   Lightbox
   ======================================== */
.lightbox {
    display: none;
    position: fixed;
    z-index: 10000;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 40px;
}

.lightbox.active,
.lightbox.is-active {
    display: flex;
}

.lightbox-content {
    max-width: 90%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: opacity 0.2s;
    background: none;
    border: none;
    padding: 10px;
    line-height: 1;
}

.lightbox-close:hover {
    opacity: 0.7;
}

.lightbox-caption {
    color: white;
    text-align: center;
    padding: 20px;
    font-size: 16px;
    max-width: 800px;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 30px;
    padding: 15px 20px;
    cursor: pointer;
    transition: background 0.2s;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav--prev {
    left: 20px;
}

.lightbox-nav--next {
    right: 20px;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 1024px) {
    .product-hero__title {
        font-size: 38px;
    }
    
    .overview-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .overview-images {
        position: static;
    }
    
    .tech-specs dl {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .product-hero {
        padding: 120px 0 60px;
    }
    
    .product-hero__title {
        font-size: 28px;
    }
    
    .product-hero__subtitle {
        font-size: 16px;
    }
    
    .extra-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .extra-section--reverse .extra-grid {
        direction: ltr;
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
    }
    
    .tab-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 10px;
    }
    
    .tab-btn {
        white-space: nowrap;
    }
    
    .config-grid {
        grid-template-columns: 1fr;
    }
    
    .config-item--wide {
        grid-column: span 1;
        aspect-ratio: 1 / 1;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .tech-specs dl {
        grid-template-columns: 1fr;
    }
    
    .feature-list {
        grid-template-columns: 1fr;
    }
}

.config-figure { display: block; }

/* =========================
   Realizácie – Carousel
========================= */
.dc-carousel{
    position: relative;
}

.dc-carousel__viewport{
    overflow: hidden;
    border-radius: 12px;
}

.dc-carousel__track{
    display: flex;
    transition: transform 300ms ease;
    will-change: transform;
}

.dc-carousel__slide{
    flex: 0 0 100%;
    padding: 0;
}

.dc-carousel .gallery-item{
    margin: 0;
    width: 100%;
    aspect-ratio: 4 / 3;
}

.dc-carousel__btn{
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    line-height: 1;
    background: rgba(0,0,0,0.55);
    color: #fff;
}

.dc-carousel__btn--prev{ left: 10px; }
.dc-carousel__btn--next{ right: 10px; }

@media (min-width: 900px){
    .dc-carousel__slide{
        flex-basis: 50%;
    }
}
