/**
 * PERFILMIL CUSTOM PRODUCT PAGE - CSS REDESIGN
 * Inspirado no UX do Magazine Luiza - Cores claras e modernas
 * Version: 2.0 - Clean Design
 */

/* ===== RESET E BASE ===== */
.perfilmil-custom-product-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: #2d3748;
    background: #f7fafc;
    margin: 0;
    padding: 0;
}

.perfilmil-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== LINHA 1: HERO SECTION ===== */
.perfilmil-product-hero {
    background: #ffffff;
    padding: 20px 0 40px;
    border-bottom: 1px solid #e2e8f0;
}

/* Breadcrumb */
.perfilmil-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    font-size: 14px;
    padding: 16px 0;
}

.perfilmil-breadcrumb a {
    color: #4a5568;
    text-decoration: none;
    transition: color 0.3s ease;
}

.perfilmil-breadcrumb a:hover {
    color: #00c853;
}

.perfilmil-breadcrumb span {
    color: #a0aec0;
}

.perfilmil-breadcrumb .current {
    color: #2d3748;
    font-weight: 500;
}

/* Grid Principal */
.perfilmil-product-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
    background: #ffffff;
    padding: 32px;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.24);
}

/* ===== GALERIA DE IMAGENS ===== */
.perfilmil-product-gallery {
    position: sticky;
    top: 20px;
}

.perfilmil-main-image {
    position: relative;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    margin-bottom: 16px;
    aspect-ratio: 1;
}

.perfilmil-main-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 16px;
    transition: transform 0.3s ease;
}

.perfilmil-main-image:hover img {
    transform: scale(1.02);
}

.perfilmil-zoom-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255,255,255,0.95);
    border: 1px solid #e2e8f0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.perfilmil-zoom-btn:hover {
    background: rgba(255,255,255,1);
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.perfilmil-zoom-btn i {
    color: #4a5568;
    font-size: 14px;
}

.perfilmil-thumbnails {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 12px;
}

.perfilmil-thumb-item {
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
    aspect-ratio: 1;
    background: #ffffff;
}

.perfilmil-thumb-item:hover,
.perfilmil-thumb-item.active {
    border-color: #00c853;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,200,83,0.15);
}

.perfilmil-thumb-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 8px;
}

/* ===== INFORMAÇÕES DO PRODUTO ===== */
.perfilmil-product-info {
    padding: 0;
}

.perfilmil-category-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #edf2f7;
    color: #4a5568;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.perfilmil-category-badge:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
}

.perfilmil-category-badge i {
    font-size: 11px;
}

/* Selo de disponibilidade */
.perfilmil-availability-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    margin-left: 8px;
    transition: all 0.3s ease;
}

.perfilmil-availability-badge.in-stock {
    background: rgba(0, 200, 83, 0.1);
    color: #00c853;
    border: 1px solid rgba(0, 200, 83, 0.2);
}

.perfilmil-availability-badge.out-of-stock {
    background: rgba(244, 67, 54, 0.1);
    color: #f44336;
    border: 1px solid rgba(244, 67, 54, 0.2);
}

.perfilmil-availability-badge i {
    font-size: 11px;
}

.perfilmil-product-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0 0 16px 0;
    line-height: 1.3;
}

/* Rating */
.perfilmil-rating-section {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding: 12px 0;
}

.perfilmil-stars {
    display: flex;
    gap: 2px;
}

.perfilmil-stars .star-rating {
    font-size: 18px;
}

.perfilmil-stars .star-rating .star {
    color: #ffa726 !important;
}

.perfilmil-review-count {
    color: #718096;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.perfilmil-review-count strong {
    color: #2d3748;
    font-size: 16px;
    font-weight: 700;
}

.perfilmil-no-reviews-text {
    color: #00c853;
    font-weight: 500;
    font-style: italic;
}

/* Seção sem avaliações */
.perfilmil-no-reviews-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.perfilmil-stars-empty {
    display: flex;
    gap: 3px;
}

.perfilmil-stars-empty i {
    color: #e2e8f0;
    font-size: 18px;
    transition: color 0.3s ease;
}

.perfilmil-no-reviews {
    color: #a0aec0;
    font-size: 14px;
    font-style: italic;
    font-weight: 500;
}

/* Preço */
.perfilmil-price-section {
    margin-bottom: 24px;
    padding: 16px 0;
}

.perfilmil-price-section .woocommerce-Price-amount {
    font-size: 2.5rem;
    font-weight: 700;
    color: #00c853;
}

.perfilmil-price-section .woocommerce-Price-currencySymbol {
    font-size: 2rem;
}

/* Descrição */
.perfilmil-description {
    background: #f7fafc;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
}

.perfilmil-description h3 {
    margin: 0 0 12px 0;
    color: #2d3748;
    font-size: 1.1rem;
    font-weight: 600;
}

.perfilmil-description p {
    margin: 0;
    color: #4a5568;
    line-height: 1.6;
}

/* Especificações */
.perfilmil-product-specs {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.perfilmil-product-specs ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.perfilmil-product-specs li {
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.perfilmil-product-specs li:last-child {
    border-bottom: none;
}

.perfilmil-product-specs strong {
    color: #2d3748;
    font-weight: 600;
}

/* ===== FORMULÁRIO DE COMPRA ===== */
.perfilmil-purchase-form {
    background: #ffffff;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.06);
}

.perfilmil-quantity-section {
    margin-bottom: 20px;
}

.perfilmil-quantity-section label {
    display: block;
    color: #2d3748;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
}

.perfilmil-quantity-controls {
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    width: fit-content;
}

.perfilmil-qty-btn {
    background: #f7fafc;
    border: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    font-weight: 600;
    color: #4a5568;
    transition: background-color 0.3s ease;
}

.perfilmil-qty-btn:hover {
    background: #edf2f7;
}

#perfilmil-quantity {
    border: none;
    width: 60px;
    height: 40px;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #2d3748;
    background: #ffffff;
}

.perfilmil-add-to-cart-btn {
    width: 100%;
    background: #00c853;
    color: #ffffff;
    border: none;
    padding: 16px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.perfilmil-add-to-cart-btn:hover {
    background: #00b347;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,200,83,0.3);
}

.perfilmil-add-to-cart-btn i {
    font-size: 18px;
}

/* ===== COMPARTILHAMENTO ===== */
.perfilmil-share-section {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-top: 1px solid #e2e8f0;
}

.perfilmil-share-label {
    font-weight: 600;
    color: #4a5568;
    font-size: 14px;
}

.perfilmil-share-buttons {
    display: flex;
    gap: 8px;
}

.perfilmil-share-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.perfilmil-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.perfilmil-whatsapp {
    background: #25d366;
    color: white;
}

.perfilmil-facebook {
    background: #1877f2;
    color: white;
}

.perfilmil-twitter {
    background: #1da1f2;
    color: white;
}

.perfilmil-copy {
    background: #4a5568;
    color: white;
}

/* ===== LINHA 2: BENEFÍCIOS ===== */
.perfilmil-benefits {
    padding: 60px 0;
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
}

.perfilmil-benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.perfilmil-benefit-item {
    display: flex;
    align-items: center;
    gap: 16px;
    text-align: left;
    padding: 24px;
    background: #f7fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.perfilmil-benefit-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.perfilmil-benefit-icon {
    width: 56px;
    height: 56px;
    background: #00c853;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.perfilmil-benefit-icon i {
    font-size: 24px;
    color: white;
}

.perfilmil-benefit-content h3 {
    margin: 0 0 8px 0;
    font-size: 1.2rem;
    font-weight: 700;
    color: #2d3748;
}

.perfilmil-benefit-content p {
    margin: 0;
    color: #4a5568;
    line-height: 1.5;
    font-size: 14px;
}

/* ===== LINHA 3: DETALHES ===== */
.perfilmil-details {
    padding: 60px 0;
    background: #f7fafc;
}

/* Tabs */
.perfilmil-tabs {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.06);
    overflow: hidden;
    margin-bottom: 40px;
    border: 1px solid #e2e8f0;
}

.perfilmil-tab-buttons {
    display: flex;
    background: #f7fafc;
    border-bottom: 1px solid #e2e8f0;
}

.perfilmil-tab-btn {
    flex: 1;
    padding: 16px 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    color: #718096;
    transition: all 0.3s ease;
    position: relative;
}

.perfilmil-tab-btn.active {
    color: #00c853;
    background: white;
}

.perfilmil-tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: #00c853;
}

.perfilmil-tab-btn:hover {
    color: #00c853;
    background: rgba(0,200,83,0.05);
}

.perfilmil-tab-content {
    padding: 32px;
}

.perfilmil-tab-panel {
    display: none;
}

.perfilmil-tab-panel.active {
    display: block;
}

.perfilmil-tab-panel h3 {
    margin: 0 0 20px 0;
    color: #2d3748;
    font-size: 1.5rem;
    font-weight: 700;
}

.perfilmil-write-review-btn {
    display: inline-block;
    background: #00c853;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-top: 16px;
}

.perfilmil-write-review-btn:hover {
    background: #00b347;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,200,83,0.3);
}

/* Produtos Relacionados */
.perfilmil-related-products h2 {
    text-align: center;
    margin: 0 0 40px 0;
    color: #2d3748;
    font-size: 2rem;
    font-weight: 700;
}

.perfilmil-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.perfilmil-related-item {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.perfilmil-related-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.perfilmil-related-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.perfilmil-related-image {
    aspect-ratio: 1;
    overflow: hidden;
    background: #f7fafc;
    border-bottom: 1px solid #e2e8f0;
}

.perfilmil-related-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 16px;
    transition: transform 0.3s ease;
}

.perfilmil-related-item:hover .perfilmil-related-image img {
    transform: scale(1.05);
}

.perfilmil-related-item h4 {
    padding: 16px 16px 8px;
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #2d3748;
    line-height: 1.4;
}

.perfilmil-related-price {
    display: block;
    padding: 0 16px 16px;
    font-size: 1.1rem;
    font-weight: 700;
    color: #00c853;
}

/* ===== LIGHTBOX ===== */
.perfilmil-lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    backdrop-filter: blur(5px);
}

.perfilmil-lightbox-content {
    position: relative;
    margin: auto;
    display: block;
    width: 90%;
    max-width: 800px;
    max-height: 90%;
    top: 50%;
    transform: translateY(-50%);
}

.perfilmil-lightbox-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000;
}

.perfilmil-lightbox-close:hover {
    opacity: 0.7;
}

#perfilmil-lightbox-img {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 1024px) {
    .perfilmil-product-grid {
        gap: 32px;
        padding: 24px;
    }
    
    .perfilmil-product-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .perfilmil-product-grid {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 16px;
    }
    
    .perfilmil-product-gallery {
        position: static;
    }
    
    .perfilmil-product-title {
        font-size: 1.6rem;
    }
    
    .perfilmil-benefits-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .perfilmil-benefit-item {
        text-align: center;
        flex-direction: column;
        gap: 12px;
        padding: 20px;
    }
    
    .perfilmil-tab-buttons {
        flex-direction: column;
    }
    
    .perfilmil-tab-btn {
        text-align: left;
    }
    
    .perfilmil-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .perfilmil-container {
        padding: 0 12px;
    }
    
    .perfilmil-product-hero {
        padding: 16px 0 24px;
    }
    
    .perfilmil-benefits {
        padding: 40px 0;
    }
    
    .perfilmil-details {
        padding: 40px 0;
    }
    
    .perfilmil-tab-content {
        padding: 20px;
    }
    
    .perfilmil-related-grid {
        grid-template-columns: 1fr;
    }
    
    .perfilmil-product-grid {
        padding: 12px;
    }
}