/* ========================================
   SINGLE PRODUCT REDESIGN STYLES
   ======================================== */

/* Container principal */
.producte-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    padding-bottom: 0 !important;
}

/* Grid principal (imatge + detalls) - EXACTAMENT 50% - 50% */
.producte-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
    width: 100%;
}

/* ========== GALERIA D'IMATGES ========== */
.producte-gallery {
    position: sticky;
    top: 100px;
    height: fit-content;
    width: 100%;
}

.main-image {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e0e0e0;
    margin-bottom: 1rem;
    background: #f8f9fa;
    position: relative;
}

.main-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Badges DINS de la imatge */
.image-badges {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
    z-index: 10;
}

.thumbnail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 0.4rem;
}

.thumbnail {
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
}

.thumbnail:hover,
.thumbnail.active {
    border-color: #EC8D36;
}

.thumbnail img {
    width: 100%;
    height: 60px;
    object-fit: cover;
    display: block;
}

/* ========== DETALLS DEL PRODUCTE ========== */
.producte-details {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    width: 100%;
}

.producte-title {
    font-size: 1.56rem;
    font-weight: 600;
    color: #222;
    margin: 0;
    line-height: 1.3;
}

/* Badges (dins de la imatge) */
.badge {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    border: 1px solid;
}

.badge-bestseller {
    background: rgba(255, 215, 0, 0.15);
    color: #B8860B;
    border-color: rgba(184, 134, 11, 0.3);
}

.badge-outlet {
    background: rgba(255, 107, 107, 0.15);
    color: #C92A2A;
    border-color: rgba(201, 42, 42, 0.3);
}

.badge-reciclat {
    background: rgba(81, 207, 102, 0.15);
    color: #2B8A3E;
    border-color: rgba(43, 138, 62, 0.3);
}

/* Preu i Stock */
.producte-price-stock {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 1rem 0 1.5rem 0;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.producte-preu {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.preu-label {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

.preu-amount {
    font-size: 1.8rem;
    font-weight: 700;
    color: #EC8D36;
}

.producte-stock {
    display: flex;
    align-items: center;
}

.stock-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.4rem 0.8rem;
    background: #51CF66;
    color: white;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Link per comprar - Estil minimalista blanc */
.producte-buy-link {
    margin: 1.5rem 0;
}

.btn-comprar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 2.5rem;
    background: #ffffff;
    color: #333;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: 1px solid #ccc;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.btn-comprar:hover {
    background: #f8f9fa;
    border-color: #999;
    color: #333;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.12);
}

/* Descripció curta */
.producte-description-short {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #555;
}

.producte-description-short p {
    margin: 0 0 0.5rem;
    font-size: 16px !important;
}

/* Link mides */
.producte-mides-link {
    padding: 0.6rem 1rem;
    background: transparent;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.link-mides {
    color: #000;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.link-mides:hover {
    color: #EC8D36;
}

.link-mides-icon {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid currentColor;
    display: inline-block;
}

/* Producte personalitzable */
.producte-personalitzable {
    padding: 0.75rem 1rem;
    background: transparent;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.personalitzable-box strong {
    display: block;
    margin-bottom: 0.3rem;
    color: #333;
    font-size: 0.85rem;
    font-weight: 700;
}

.personalitzable-box p {
    margin: 0;
    font-size: 0.8rem;
    color: #666;
    font-weight: 600;
}

/* Ajuda / Xatbot - ELIMINAT */

/* Enviament */
.producte-enviament {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: transparent;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
    font-size: 0.85rem;
    color: #000;
    font-weight: 700;
}

.producte-film-specs {
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
    background: #f8f9fb;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.producte-film-specs h3 {
    margin: 0 0 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    color: #1a202c;
}

.film-spec-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.film-spec-list li {
    font-size: 0.95rem;
    color: #2d3748;
}

.film-spec-list li strong {
    font-weight: 600;
    margin-right: 0.35rem;
}

/* Tipus de producte */
.producte-tipus {
    font-size: 0.9rem;
    color: #666;
    padding: 0.75rem 0;
    border-top: 1px solid #e0e0e0;
}

/* Documents */
.producte-documents {
    padding: 1rem 0;
    border-top: 1px solid #e0e0e0;
}

.producte-documents h4 {
    margin: 0 0 0.75rem;
    font-size: 1rem;
    font-weight: 600;
}

.document-link {
    display: inline-block;
    margin: 0.25rem 0.5rem 0.25rem 0;
    padding: 0.5rem 1rem;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    color: #495057;
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.document-link:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* ========== TABS DE CONTINGUT ========== */
.producte-tabs-container {
    margin-bottom: 3rem;
}

.producte-tabs-nav {
    display: flex;
    gap: 0;
    border-bottom: 2px solid #e0e0e0;
    margin-bottom: 2rem;
}

.tab-button {
    padding: 1rem 2rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    color: #666;
    transition: all 0.3s;
    position: relative;
    bottom: -2px;
}

.tab-button:hover {
    color: #222;
}

.tab-button.active {
    color: #EC8D36;
    border-bottom-color: #EC8D36;
}

.producte-tabs-content {
    padding: 2rem 0;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Taula de mides */
.taula-mides-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -1rem;
    padding: 0 1rem;
}

.producte-taula-mides {
    width: 100%;
    border-collapse: collapse;
    min-width: 500px;
}

.producte-taula-mides th,
.producte-taula-mides td {
    padding: 0.75rem 1rem;
    border: 1px solid #e0e0e0;
    text-align: left;
    white-space: nowrap;
}

.producte-taula-mides th {
    background: #f7b95a;
    color: #222;
    font-weight: 600;
}

.producte-taula-mides tr:hover {
    background: #f8f9fa;
}

@media (max-width: 768px) {
    .taula-mides-wrapper {
        margin: 0 -1rem;
        padding: 0 1rem;
        max-width: 100vw;
    }
    
    .producte-taula-mides {
        min-width: 400px;
        font-size: 0.85rem;
    }
    
    .producte-taula-mides th,
    .producte-taula-mides td {
        padding: 0.5rem 0.75rem;
    }
}

@media (max-width: 480px) {
    .producte-taula-mides {
        min-width: 300px;
        font-size: 0.8rem;
    }
    
    .producte-taula-mides th,
    .producte-taula-mides td {
        padding: 0.4rem 0.5rem;
    }
}

/* Contingut de beneficis */
.beneficis-content {
    line-height: 1.7;
    color: #555;
}

.beneficis-content h2,
.beneficis-content h3 {
    color: #222;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.beneficis-content p {
    margin-bottom: 1rem;
}

.beneficis-content ul,
.beneficis-content ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.beneficis-content li {
    margin-bottom: 0.5rem;
}

/* Característiques */
.caracteristiques-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.caracteristiques-list li {
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 3px solid #EC8D36;
}

.caracteristiques-list strong {
    display: block;
    margin-bottom: 0.25rem;
    color: #222;
}

/* ========== PRODUCTES RELACIONATS ========== */
.producte-relacionats-section {
    margin-bottom: 3rem;
}

/* ========== FORMULARI DE CONTACTE ========== */
.producte-contact-section {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-bottom: 0 !important;
    padding: 2rem;
    background: #f8f9fa;

}

.contact-intro {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-intro h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
    color: #222;
}

.contact-intro p {
    margin: 0;
    color: #666;
    font-size: 0.95rem;
}

.producte-contact-form {
    max-width: 800px;
    margin: 0 auto;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.9rem;
    color: #333;
}

.form-group input,
.form-group textarea {
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #EC8D36;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.btn-submit {
    width: 100%;
    padding: 1rem;
    background: #EC8D36;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-submit:hover {
    background: #d97a26;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 900px) {
    .producte-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .producte-gallery {
        position: static;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .caracteristiques-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .producte-container {
        padding: 1rem 0.75rem;
    }
    
    .producte-tabs-nav {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .tab-button {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
        white-space: nowrap;
    }
    
    .producte-contact-section {
        padding: 1.5rem 1rem;
        margin-bottom: 0 !important;
    }
    
    .contact-intro h3 {
        font-size: 1.25rem;
    }
}

