:root {
    /* Cores principais premium */
    --accent-color: #D4AF37; /* Dourado */
    --accent-hover: #f1c40f;
    --view-btn-text: #1a1a2e;
    
    /* Tema Premium */
    --bg-page: #f8f9fa;
    --bg-gradient-header: #000000; /* Preto puro para a logo mesclar perfeitamente */
    --surface-color: #ffffff;
    --surface-color-light: #f0f0f0;
    --text-primary: #121212;
    --text-secondary: #666666;
    --border-color: rgba(0,0,0,0.05);
    
    --font-body: 'Inter', sans-serif;
    --font-heading: 'Outfit', sans-serif;
    
    --header-height: 120px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    touch-action: manipulation; /* FIX: Previne o zoom de duplo-clique no celular */
}

body {
    font-family: var(--font-body);
    background: var(--bg-page);
    color: var(--text-primary);
    -webkit-tap-highlight-color: transparent;
    min-height: 100vh;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
}

/* Header Premium */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--bg-gradient-header);
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    height: 60px;
}

.logo-container {
    display: flex;
    justify-content: flex-start;
    flex: 0 0 auto;
}

.logo {
    height: 40px;
    object-fit: contain;
    border-radius: 4px;
    mix-blend-mode: screen;
    clip-path: inset(2px);
}

/* Category Navigation (Horizontal Scroll) */
.category-nav {
    overflow-x: auto;
    scrollbar-width: none; /* Firefox */
}

.category-nav::-webkit-scrollbar {
    display: none; /* Chrome/Safari/Opera */
}

.category-list {
    display: flex;
    list-style: none;
    padding: 10px 16px;
    gap: 16px;
}

.category-item {
    white-space: nowrap;
}

.category-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 0.95rem;
    font-weight: 500;
    font-family: var(--font-heading);
    padding: 12px 0;
    cursor: pointer;
    position: relative;
    transition: color 0.3s ease;
}

.category-btn.active {
    color: var(--accent-color);
    font-weight: 700;
}

.category-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--accent-color);
    border-radius: 3px 3px 0 0;
    box-shadow: 0 -2px 10px rgba(212, 175, 55, 0.4);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 1;
}

/* Main Catalog Area & Swiper */
.swiper {
    width: 100%;
    height: calc(100vh - var(--header-height));
    height: calc(100dvh - var(--header-height));
    margin-top: var(--header-height);
}

.swiper-slide {
    height: auto;
    overflow-y: auto;
    padding: 16px;
    padding-bottom: 80px;
    box-sizing: border-box;
}

.category-section {
    margin-bottom: 32px;
}

.section-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 16px;
}

/* Product Card Premium */
.product-card {
    background-color: var(--surface-color);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.product-card:active {
    transform: scale(0.96);
}

.product-image-container {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: var(--surface-color-light);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: background-color 0.3s ease;
}

.product-image-container i {
    font-size: 3rem;
    color: var(--text-secondary);
    opacity: 0.5;
}

.product-info {
    padding: 12px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-category {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.product-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--text-primary);
    flex-grow: 1;
}

.product-price {
    font-size: 16px;
    font-weight: 700;
    color: #111;
    margin-bottom: 12px;
}

.price-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    margin-bottom: 12px;
}

.price-container .product-price {
    margin-bottom: 0;
}

/* Linha preço + badge de % dentro do card */
.price-row {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: wrap;
}

.original-price {
    font-size: 13px;
    color: #aaa;
    text-decoration: line-through;
    font-weight: 500;
    line-height: 1;
}

.product-price.discount {
    color: #2e7d32;
    font-size: 17px;
    font-weight: 800;
}

/* Badge de % de desconto no card (ao lado do preço) */
.price-discount-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e53935, #c62828);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 20px;
    font-family: var(--font-heading);
    letter-spacing: 0.2px;
    box-shadow: 0 2px 5px rgba(229,57,53,0.35);
    flex-shrink: 0;
}

.view-btn {
    background-color: var(--accent-color);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 10px;
    font-weight: 700;
    font-size: 0.9rem;
    font-family: var(--font-heading);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.1s, box-shadow 0.2s;
}

.view-btn:active {
    transform: scale(0.95);
}

@media (min-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

.cart-toggle-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    position: relative;
    padding: 8px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cart-toggle-btn.bounce {
    transform: scale(1.3);
}

.cart-badge {
    position: absolute;
    top: 0;
    right: 0;
    background-color: var(--accent-color);
    color: var(--view-btn-text);
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Sidebar Carrinho */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 85vw;
    max-width: 400px;
    height: 100vh;
    height: 100dvh; /* FIX: Evita que o painel fique "comido" no Safari/iPhone */
    background-color: var(--surface-color);
    z-index: 10001;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    display: flex;
    flex-direction: column;
}

.cart-sidebar.open {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
}

.cart-header h2 {
    font-size: 1.2rem;
}

.close-cart-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

.cart-items-container {
    flex-grow: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cart-empty-msg {
    text-align: center;
    color: var(--text-secondary);
    margin-top: 40px;
}

.cart-item {
    display: flex;
    gap: 12px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
}

.cart-item-img {
    width: 60px;
    height: 60px;
    background-color: var(--surface-color-light);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-size: 1.5rem;
    position: relative;
    overflow: hidden;
}

.cart-item-info {
    flex-grow: 1;
}

.cart-item-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.cart-item-price {
    font-size: 0.95rem;
    font-weight: 800;
    color: #111111;
}

.cart-item-qty-selector {
    display: inline-flex;
    align-items: center;
    background: var(--surface-color-light);
    border-radius: 8px;
    padding: 2px 4px;
}

.qty-btn {
    background: transparent;
    border: none;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 0.8rem;
    border-radius: 4px;
    transition: background 0.2s;
}

.qty-btn:hover {
    background: rgba(0,0,0,0.05);
}

.qty-display {
    min-width: 24px;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 700;
}

.cart-footer {
    padding: 16px;
    padding-bottom: calc(16px + env(safe-area-inset-bottom)); /* FIX: Margem extra para a barrinha preta do iPhone */
    border-top: 1px solid var(--border-color);
    background-color: var(--surface-color);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.checkout-btn {
    width: 100%;
    background-color: #25D366;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    transition: filter 0.2s;
}

.checkout-btn:hover {
    filter: brightness(1.1);
}

.keep-buying-btn {
    width: 100%;
    background-color: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 12px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    display: block;
    text-decoration: none;
}

/* Product Page Specific */
.product-page-container {
    margin-top: var(--header-height);
    padding: 0;
    padding-bottom: 80px;
}

.product-carousel {
    width: 100%;
    min-height: 280px;
    max-height: 480px;
    height: auto;
    background-color: #fff;
    position: relative;
    border-bottom: 1px solid var(--border-color);
}

.carousel-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    height: 100%;
    min-height: 280px;
    max-height: 480px;
}

.carousel-track::-webkit-scrollbar {
    display: none;
}

.carousel-slide {
    flex: 0 0 100%;
    min-height: 280px;
    max-height: 480px;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    cursor: zoom-in;
    position: relative;
    overflow: hidden;
    padding: 12px;
}

.carousel-slide:hover .carousel-zoom-hint {
    opacity: 1;
}

/* Hint de lupa no canto inferior direito */
.carousel-zoom-hint {
    position: absolute;
    bottom: 10px;
    right: 12px;
    background: rgba(0,0,0,0.45);
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    opacity: 0;
    transition: opacity 0.2s;
    pointer-events: none;
    backdrop-filter: blur(4px);
}

.carousel-slide i {
    font-size: 5rem;
    color: var(--text-secondary);
    opacity: 0.5;
}

.carousel-indicators {
    position: absolute;
    bottom: 16px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(0,0,0,0.3);
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.carousel-dot.active {
    background-color: var(--accent-color);
    transform: scale(1.2);
}

.product-details-body {
    padding: 24px 16px;
}

.prod-page-category {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    letter-spacing: 1px;
    margin-bottom: 8px;
    display: block;
}

.prod-page-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.prod-page-price {
    font-size: 24px;
    font-weight: 800;
    color: #111;
    margin-bottom: 24px;
}

.prod-page-price-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    margin-bottom: 24px;
    padding: 16px;
    background: linear-gradient(135deg, #f1f8f1, #fff);
    border: 1px solid rgba(46,125,50,0.15);
    border-radius: 12px;
    border-left: 4px solid #2e7d32;
}

.prod-page-price-container .prod-page-price {
    margin-bottom: 0;
}

/* Linha horizontal: preço com desconto + badge */
.prod-page-price-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.prod-page-original-price {
    font-size: 16px;
    color: #aaa;
    text-decoration: line-through;
    font-weight: 400;
    line-height: 1;
}

.prod-page-price.discount {
    color: #2e7d32;
    font-size: 28px;
    font-weight: 900;
    line-height: 1;
}

.prod-page-description-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.prod-page-description {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 32px;
}

.add-to-cart-btn {
    width: 100%;
    background-color: var(--accent-color);
    color: var(--view-btn-text);
    border: none;
    padding: 16px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: filter 0.2s;
}

.add-to-cart-btn:hover {
    filter: brightness(1.1);
}

/* Botão Comprar pelo WhatsApp (página do produto) */
.buy-whatsapp-btn {
    width: 100%;
    background-color: #25D366;
    color: #ffffff;
    border: none;
    padding: 16px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: var(--font-heading);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    box-shadow: 0 4px 6px rgba(37,211,102,0.25);
    transition: filter 0.2s, transform 0.1s;
}

.buy-whatsapp-btn:hover {
    filter: brightness(1.08);
}

.buy-whatsapp-btn:active {
    transform: scale(0.97);
}

.back-to-catalog-btn {
    width: 100%;
    background-color: var(--surface-color-light);
    color: var(--text-primary);
    border: none;
    border-radius: 8px;
    padding: 16px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    display: block;
    text-decoration: none;
    transition: filter 0.2s;
}

.back-to-catalog-btn:hover {
    filter: brightness(0.9);
}

/* Seta Voltar - Header Produto */
.back-header-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 8px 16px 8px 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Toasts */
.toast-container {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    background-color: #222;
    color: #fff;
    padding: 12px 24px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 8px;
    animation: toastSlideUp 0.3s ease forwards;
}

.toast i {
    color: var(--accent-color);
}

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

/* Skeleton Loading */
.skeleton {
    background: #e0e0e0;
    background: linear-gradient(90deg, #e0e0e0 25%, #f0f0f0 50%, #e0e0e0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-card {
    height: 250px;
    border-radius: 16px;
}

/* Focus styles for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible {
    outline: 2px solid var(--accent-color, #c8a656);
    outline-offset: 2px;
}

/* Max-width for wide screens */
.product-grid,
.product-page-container {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

/* Toast Notification */
.toast-notification {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--accent-color, #c8a656);
    color: #1a1a2e;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    z-index: 10000;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.toast-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Error Message */
.error-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 60px 20px;
    text-align: center;
    color: #999;
}
.error-message i {
    font-size: 3rem;
    color: #c8a656;
}
.error-message p {
    font-size: 1.1rem;
}
.error-message button {
    background: #c8a656;
    color: #1a1a2e;
    border: none;
    padding: 10px 24px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}
.error-message button:hover {
    opacity: 0.85;
}

/* Body scroll lock when cart is open */
body.cart-open {
    overflow: hidden;
}

/* ============================================================
   BUSCA NO HEADER
   ============================================================ */
.header-search {
    flex: 1;
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 20px;
    padding: 6px 14px;
    gap: 8px;
    margin: 0 12px;
    transition: background 0.2s, border-color 0.2s;
}
.header-search:focus-within {
    background: rgba(255,255,255,0.22);
    border-color: var(--accent-color);
}
.header-search i {
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
    flex-shrink: 0;
}
.header-search input {
    background: none;
    border: none;
    color: #fff;
    outline: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    width: 100%;
    min-width: 0;
}
.header-search input::placeholder { color: rgba(255,255,255,0.45); }
#search-clear-btn {
    background: none;
    border: none;
    color: rgba(255,255,255,0.6);
    cursor: pointer;
    padding: 0;
    font-size: 0.85rem;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
}
#search-clear-btn:hover { color: #fff; }

/* Container de resultados de busca */
#search-results-container {
    margin-top: var(--header-height);
    padding: 16px 16px 80px;
    min-height: calc(100vh - var(--header-height));
    min-height: calc(100dvh - var(--header-height));
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}
#search-results-title {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 16px;
    font-weight: 600;
}

/* ============================================================
   CATEGORIA VAZIA — MENSAGEM MELHORADA
   ============================================================ */
.empty-category-msg {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 48px 16px;
    color: #ccc;
    text-align: center;
}
.empty-category-msg i { font-size: 2.5rem; }
.empty-category-msg p  { font-size: 0.95rem; }

/* ============================================================
   BADGE DE DESCONTO NO CARD
   ============================================================ */
.discount-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #e74c3c;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 20px;
    font-family: var(--font-heading);
    z-index: 2;
    box-shadow: 0 2px 6px rgba(231,76,60,0.35);
    letter-spacing: 0.3px;
}

/* ============================================================
   OVERLAY "ESGOTADO" NO CARD
   ============================================================ */
.stock-out-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.48);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
}
.stock-out-overlay span {
    background: rgba(0,0,0,0.75);
    color: #fff;
    font-weight: 700;
    font-size: 0.82rem;
    padding: 5px 14px;
    border-radius: 20px;
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* ============================================================
   MELHORIAS DO CARRINHO
   ============================================================ */
/* Bug 3 fix — Truncação do título */
.cart-item-title {
    font-size: 0.88rem;
    font-weight: 600;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 190px;
}

/* Linha de controles (qty + lixeira) */
.cart-item-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    gap: 8px;
}

/* Botão remover item do carrinho (UX 2) */
.remove-cart-item {
    background: none;
    border: none;
    color: #ccc;
    cursor: pointer;
    font-size: 0.88rem;
    padding: 5px 8px;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
    flex-shrink: 0;
}
.remove-cart-item:hover { color: #e74c3c; background: #fff0ef; }

/* ============================================================
   PÁGINA DO PRODUTO — BADGES E INDICADORES
   ============================================================ */
.prod-page-stock-out {
    background: #ffebee;
    color: #c62828;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    border-left: 4px solid #c62828;
}
.prod-page-stock-low {
    background: #fff3e0;
    color: #e65100;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    border-left: 4px solid #e65100;
}

/* Badge de % de desconto na página do produto */
.prod-page-discount-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e53935, #c62828);
    color: #fff;
    font-size: 1rem;
    font-weight: 900;
    padding: 6px 14px;
    border-radius: 50px;
    font-family: var(--font-heading);
    letter-spacing: 0.3px;
    box-shadow: 0 3px 10px rgba(229,57,53,0.4);
    flex-shrink: 0;
}

/* ============================================================
   CARROSSEL — SETAS DE NAVEGAÇÃO (Melhoria 6)
   ============================================================ */
.carousel-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: rgba(255,255,255,0.88);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #333;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
    transition: background 0.2s, transform 0.2s;
    font-size: 0.9rem;
}
.carousel-nav-btn:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.08);
}
.carousel-prev { left: 10px; }
.carousel-next { right: 10px; }

/* Dots clicáveis */
.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(0,0,0,0.28);
    border: none;
    cursor: pointer;
    padding: 0;
    transition: background 0.2s, transform 0.2s;
}
.carousel-dot.active {
    background: var(--accent-color);
    transform: scale(1.35);
}

/* ============================================================
   BOTÃO COMPARTILHAR (Melhoria 4)
   ============================================================ */
.share-product-btn {
    width: 100%;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    transition: background 0.2s, color 0.2s;
    font-family: var(--font-heading);
}
.share-product-btn:hover { background: #f5f5f5; color: var(--text-primary); }

/* ============================================================
   SEÇÃO DE DESCRIÇÃO NA PÁGINA DO PRODUTO
   ============================================================ */
.prod-page-description-section {
    margin-top: 32px;
    padding-bottom: 8px;
}

/* ============================================================
   PRODUTOS RELACIONADOS (Melhoria 7)
   ============================================================ */
.related-products-section {
    padding: 24px 16px 80px;
    background: var(--bg-page);
    border-top: 1px solid var(--border-color);
}
.related-products-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}
.related-products-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 4px;
}
.related-products-scroll::-webkit-scrollbar { display: none; }

.related-card {
    flex: 0 0 135px;
    background: var(--surface-color);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.related-card:hover  { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.08); }
.related-card:active { transform: scale(0.97); }

.related-card-img {
    width: 100%;
    aspect-ratio: 1/1;
    background: var(--surface-color-light);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.related-card-img img { width: 100%; height: 100%; object-fit: cover; }
.related-card-img i   { font-size: 2rem; color: #ccc; }

.related-card-info { padding: 8px 10px; }
.related-card-title {
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.related-card-price {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-primary);
}

/* ============================================================
   RESPONSIVIDADE ADICIONAL
   ============================================================ */
@media (max-width: 480px) {
    .header-search { margin: 0 8px; padding: 5px 10px; }
    .cart-item-title { max-width: 145px; }
    .carousel-nav-btn { width: 30px; height: 30px; font-size: 0.8rem; }
    .related-card { flex: 0 0 120px; }
}

/* ============================================================
   LIGHTBOX — Visualizador em tela cheia
   ============================================================ */
#lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

#lightbox-overlay.active {
    display: flex;
}

/* Impede scroll da página quando o lightbox está aberto */
body.lightbox-open {
    overflow: hidden;
}

/* Wrapper da imagem — ocupa espaço disponível */
.lb-img-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 60px 70px 40px;
    box-sizing: border-box;
    overflow: hidden;
}

/* Imagem dentro do lightbox */
#lb-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    user-select: none;
    -webkit-user-drag: none;
}

/* Animação fade ao trocar imagem */
@keyframes lbFadeIn {
    from { opacity: 0; transform: scale(0.96); }
    to   { opacity: 1; transform: scale(1); }
}
.lb-fade-in {
    animation: lbFadeIn 0.22s ease forwards;
}

/* Botão fechar */
.lb-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.15s;
    z-index: 10;
    backdrop-filter: blur(4px);
}
.lb-close:hover { background: rgba(255,255,255,0.25); transform: scale(1.1); }

/* Botões de navegação (setas) */
.lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.15s;
    z-index: 10;
    backdrop-filter: blur(4px);
}
.lb-nav:hover { background: rgba(255,255,255,0.28); transform: translateY(-50%) scale(1.1); }
.lb-prev { left: 12px; }
.lb-next { right: 12px; }

/* Contador: "1 / 3" */
.lb-counter {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255,255,255,0.12);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 5px 16px;
    border-radius: 20px;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.15);
    white-space: nowrap;
}

/* Mobile: reduz padding para aproveitar toda a tela */
@media (max-width: 480px) {
    .lb-img-wrapper { padding: 60px 52px 50px; }
    .lb-nav { width: 38px; height: 38px; font-size: 0.85rem; }
    .lb-prev { left: 6px; }
    .lb-next { right: 6px; }
}

/* ============================================================
   SUPORTE A VÍDEOS NAS MÍDIAS DO PRODUTO
   ============================================================ */
.video-thumb-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(0,0,0,0.55);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    pointer-events: none;
    backdrop-filter: blur(2px);
}

.carousel-slide-video {
    cursor: default;
}

.carousel-slide-video video {
    background: #000;
}

