/* ==========================================================================
   MATINA PLAST - E-COMMERCE DESIGN SYSTEM
   ========================================================================== */

:root {
    --primary: #0A2647;      /* Azul Industrial Profundo */
    --primary-light: #144272;
    --accent: #FF4D00;       /* Laranja Neon (agora usado para alertas/ofertas) */
    --accent-blue: #3B82F6;
    --bg-white: #ffffff;
    --bg-light: #f4f6f8;
    --bg-dark: #020617;
    --text-main: #333333;
    --text-muted: #666666;
    --border-color: #e5e7eb;
    --font-main: 'Inter', system-ui, sans-serif;
    --transition: 0.3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; }

.ecom-body { 
    font-family: var(--font-main); 
    background-color: var(--bg-light); 
    color: var(--text-main); 
    line-height: 1.6; 
    overflow-x: hidden;
}

.container { max-width: 1300px; margin: 0 auto; padding: 0 20px; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 20px; border-radius: 6px; font-weight: 600; cursor: pointer; transition: var(--transition); border: none; }
.btn-primary { background-color: #25D366; color: white; } /* WhatsApp Green for conversion */
.btn-primary:hover { background-color: #128C7E; }
.btn-outline { border: 1px solid var(--border-color); background: white; color: var(--text-main); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

/* Top Bar */
.top-bar { background-color: var(--primary); color: white; padding: 8px 0; font-size: 0.85rem; }
.top-bar-inner { display: flex; justify-content: space-between; }
.top-bar-right { display: flex; gap: 20px; }
.top-bar-right a { display: flex; align-items: center; gap: 5px; opacity: 0.8; }
.top-bar-right a:hover { opacity: 1; }

/* Main Header */
.main-header { background-color: rgb(9, 51, 142); padding: 25px 0; border-bottom: 1px solid rgba(255,255,255,0.1); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.logo-area { display: flex; align-items: center; }
.logo-img { 
    height: auto; 
    max-height: 140px; 
    max-width: 500px; 
    object-fit: contain; 
    transition: transform 0.3s ease;
}
.logo-area:hover .logo-img {
    transform: scale(1.02);
}

.search-bar { position: relative; flex-grow: 1; max-width: 600px; display: flex; border: 2px solid rgba(255,255,255,0.2); border-radius: 8px; overflow: visible; background: rgba(255,255,255,0.1); }
.search-bar input { flex-grow: 1; border: none; padding: 12px 15px; outline: none; font-size: 0.95rem; border-radius: 8px 0 0 8px; background: transparent; color: white; }
.search-bar input::placeholder { color: rgba(255,255,255,0.6); }
.search-bar button { background: var(--accent); color: white; border: none; padding: 0 20px; cursor: pointer; transition: background 0.3s ease; border-radius: 0 8px 8px 0; }
.search-bar button:hover { background: #e64500; }

/* DROPDOWN DE BUSCA */
.search-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    width: 100%;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    z-index: 1000;
    max-height: 350px;
    overflow-y: auto;
    flex-direction: column;
    /* Animação Suave */
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    display: flex;
}
.search-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.search-dropdown-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    text-decoration: none;
    color: var(--text-color);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.2s;
}
.search-dropdown-item:last-child {
    border-bottom: none;
}
.search-dropdown-item:hover {
    background: #f8f9fa;
}
.search-dropdown-img {
    width: 45px;
    height: 45px;
    object-fit: contain;
    margin-right: 15px;
}
.search-dropdown-info h4 {
    font-size: 0.95rem;
    margin: 0;
    font-weight: 500;
    color: var(--text-color);
}
.search-dropdown-info p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin: 4px 0 0 0;
}
.search-dropdown-empty {
    padding: 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.header-actions { display: flex; gap: 20px; }
.action-btn { display: flex; align-items: center; gap: 10px; color: white; }
.action-btn i { font-size: 1.8rem; color: #25D366; }
.action-btn.primary-action i { color: var(--accent); }
.action-text { display: flex; flex-direction: column; font-size: 0.8rem; line-height: 1.2; }
.action-text span { color: rgba(255,255,255,0.7); }
.action-text strong { color: white; font-weight: 700; }

/* Category Nav */
.category-nav { background-color: var(--primary); color: white; }
.nav-list { display: flex; }
.nav-list li a { display: inline-flex; align-items: center; gap: 8px; padding: 15px 25px; font-weight: 600; font-size: 0.9rem; transition: var(--transition); }
.nav-list li a:hover, .nav-list li a.active { background-color: rgba(255,255,255,0.1); }

/* Full Width E-commerce Banner (Carousel) */
/* Full Width E-commerce Banner (Carousel) */
.full-banner-wrapper { width: 100%; margin-bottom: 30px; position: relative; overflow: hidden; }
.carousel-container { position: relative; width: 100%; height: 500px; /* Altura fixa padronizada */ }
.carousel-slide { 
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; 
    opacity: 0; transition: opacity 0.8s ease-in-out; z-index: 1; 
    display: flex; align-items: center; 
}
.carousel-slide.active { opacity: 1; z-index: 2; /* Mantém absoluto para não alterar a altura do pai */ }
.banner-slide-inner { display: flex; align-items: center; justify-content: space-between; position: relative; z-index: 2; width: 100%; height: 100%; }

/* Animações Internas do Carrossel para fluidez */
.carousel-slide .banner-text { 
    max-width: 50%; color: white; 
    opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out 0.2s; 
}
.carousel-slide .banner-image {
    width: 50%; 
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}
.carousel-slide .banner-image img { 
    max-width: 100%; 
    height: 380px; /* Altura padronizada para todas as artes */
    object-fit: contain;
    opacity: 0; transform: scale(0.95) translateX(30px); transition: all 1s ease-out 0.1s; 
}

.carousel-slide.active .banner-text { 
    opacity: 1; transform: translateY(0); 
}
.carousel-slide.active .banner-image img { 
    opacity: 1; transform: scale(1) translateX(0); 
}

.banner-text h1 { font-size: 3rem; font-weight: 800; line-height: 1.1; margin-bottom: 20px; }
.banner-text p { font-size: 1.2rem; opacity: 0.9; margin-bottom: 35px; }
.carousel-indicators { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; z-index: 10; }
.indicator { width: 12px; height: 12px; border-radius: 50%; background: rgba(255,255,255,0.4); border: none; cursor: pointer; transition: background 0.3s ease; padding: 0; }
.indicator.active { background: white; transform: scale(1.2); }

/* Mini Banners Grid */
.mini-banners-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 20px; }
.mini-banner { border-radius: 12px; padding: 30px; color: white; display: flex; justify-content: space-between; align-items: center; overflow: hidden; position: relative; transition: var(--transition); }
.mini-banner:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.1); }
.mini-banner h3 { font-size: 1.5rem; line-height: 1.2; margin-bottom: 15px; position: relative; z-index: 2; }
.mini-banner a { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; border-bottom: 2px solid white; padding-bottom: 2px; position: relative; z-index: 2; }
.mini-banner img { position: absolute; right: -20px; bottom: -20px; max-height: 140px; opacity: 0.8; transition: var(--transition); }
.mini-banner:hover img { transform: scale(1.1); }

/* Features Bar */
.features-bar { display: flex; justify-content: space-between; background: white; border: 1px solid var(--border-color); border-radius: 8px; padding: 25px; margin-bottom: 20px; box-shadow: 0 4px 6px rgba(0,0,0,0.02); }
.feature-item { display: flex; align-items: center; gap: 15px; }
.feature-item i { font-size: 2.2rem; color: var(--accent-blue); }
.feature-text { display: flex; flex-direction: column; }
.feature-text strong { color: var(--primary); font-size: 1rem; }
.feature-text span { color: var(--text-muted); font-size: 0.85rem; }

/* Breadcrumbs */
.breadcrumbs { padding: 20px 0; font-size: 0.85rem; color: var(--text-muted); }
.breadcrumbs a { color: var(--primary); }
.breadcrumbs a:hover { text-decoration: underline; }

/* Catalog Layout (index.html) */
.catalog-layout { display: flex; gap: 30px; margin-bottom: 60px; }

/* Sidebar */
.sidebar { width: 260px; flex-shrink: 0; }
.filter-box { background: var(--bg-white); border: 1px solid var(--border-color); border-radius: 8px; padding: 20px; }
.filter-box h3 { font-size: 1.1rem; border-bottom: 1px solid var(--border-color); padding-bottom: 10px; margin-bottom: 15px; color: var(--primary); }
.filter-list li { margin-bottom: 12px; }
.filter-list label { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; cursor: pointer; color: var(--text-main); }

/* Products Area */
.products-area { flex-grow: 1; }
.toolbar { display: flex; justify-content: space-between; align-items: center; background: var(--bg-white); border: 1px solid var(--border-color); padding: 15px 20px; border-radius: 8px; margin-bottom: 20px; }
.toolbar h2 { font-size: 1.2rem; font-weight: 600; color: var(--primary); }
.sort-box select { padding: 8px; border: 1px solid var(--border-color); border-radius: 4px; }

/* Grid */
.ecom-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.ecom-card { background: var(--bg-white); border: 1px solid var(--border-color); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; transition: var(--transition); }
.ecom-card:hover { box-shadow: 0 10px 20px rgba(0,0,0,0.05); transform: translateY(-3px); border-color: var(--primary-light); }
.card-img-wrap { padding: 20px; text-align: center; border-bottom: 1px solid var(--bg-light); background: white; }
.card-img-wrap img { max-width: 100%; height: 180px; object-fit: contain; }
.card-info { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.card-title { font-size: 1rem; font-weight: 600; color: var(--primary); margin-bottom: 10px; line-height: 1.4; }
.card-desc { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 15px; flex-grow: 1; }
.card-btn { text-align: center; background: var(--bg-light); color: var(--primary); padding: 12px; font-weight: 600; border-radius: 6px; border: 1px solid var(--border-color); transition: var(--transition); }
.card-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }

/* Product Page (produto.html) */
.pdp-container { margin-bottom: 60px; }
.product-block { display: flex; gap: 40px; background: var(--bg-white); padding: 40px; border-radius: 12px; border: 1px solid var(--border-color); margin-bottom: 30px; }
.product-gallery { width: 45%; }
.main-image { border: 1px solid var(--border-color); border-radius: 8px; padding: 20px; background: white; text-align: center; }
.main-image img { max-width: 100%; height: auto; max-height: 400px; object-fit: contain; }

.product-info { width: 55%; display: flex; flex-direction: column; }
.product-info h1 { font-size: 2rem; color: var(--primary); margin-bottom: 10px; }
.sku { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 20px; }
.product-short-desc { font-size: 1.05rem; line-height: 1.7; color: var(--text-main); margin-bottom: 30px; }

.action-box { background: var(--bg-light); border: 1px solid var(--border-color); padding: 25px; border-radius: 8px; margin-top: auto; text-align: center; }
.action-title { font-weight: 600; margin-bottom: 15px; color: var(--primary); }
.wa-btn-large { display: inline-flex; width: 100%; padding: 18px; font-size: 1.2rem; justify-content: center; box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3); }
.action-subtitle { font-size: 0.85rem; color: var(--text-muted); margin-top: 15px; }

/* PDP Tabs */
.product-tabs-section { background: var(--bg-white); border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; }
.pdp-tabs-nav { display: flex; background: var(--bg-light); border-bottom: 1px solid var(--border-color); }
.pdp-tab-btn { padding: 18px 30px; font-size: 1.05rem; font-weight: 600; color: var(--text-muted); background: transparent; border: none; border-right: 1px solid var(--border-color); cursor: pointer; transition: var(--transition); }
.pdp-tab-btn:hover { background: white; }
.pdp-tab-btn.active { background: white; color: var(--primary); border-bottom: 2px solid var(--primary); margin-bottom: -1px; }

.pdp-tabs-content { padding: 40px; }
.pdp-pane { display: none; animation: fadeIn 0.4s ease; }
.pdp-pane.active { display: block; }

.specs-table { width: 100%; max-width: 600px; border-collapse: collapse; }
.specs-table tr { border-bottom: 1px solid var(--border-color); }
.specs-table td { padding: 15px 0; }
.specs-table td:first-child { font-weight: 600; color: var(--primary); width: 40%; }
.specs-table td:last-child { color: var(--text-main); }

.apps-list-pdp { list-style: none; padding: 0; }
.apps-list-pdp li { position: relative; padding-left: 25px; margin-bottom: 12px; font-size: 1.05rem; }
.apps-list-pdp li::before { content: '✓'; position: absolute; left: 0; color: #25D366; font-weight: bold; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Footer */
.ecom-footer { background: var(--primary); color: white; padding-top: 60px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-col h4 { margin-bottom: 20px; color: var(--accent); font-size: 1.1rem; }
.footer-col p, .footer-col a { color: rgba(255,255,255,0.7); margin-bottom: 10px; display: block; }
.footer-bottom { background: #071930; padding: 20px 0; text-align: center; color: rgba(255,255,255,0.5); font-size: 0.85rem; }

/* Floating WhatsApp Widget */
.wa-floating-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}
.wa-floating-btn {
    width: 60px;
    height: 60px;
    background-color: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2rem;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: transform 0.3s ease, background-color 0.3s ease;
}
.wa-floating-btn:hover {
    transform: scale(1.1);
    background-color: #128C7E;
}
.wa-form-popup {
    background: white;
    width: calc(100vw - 40px);
    max-width: 320px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    margin-bottom: 20px;
    overflow: hidden;
    display: none;
    transform-origin: bottom right;
    animation: popupFadeIn 0.3s ease forwards;
    border: 1px solid var(--border-color);
}
.wa-form-popup.active {
    display: block;
}
@keyframes popupFadeIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}
.wa-form-header {
    background: var(--primary);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.wa-form-header h4 {
    font-size: 1.05rem;
    font-weight: 600;
}
.wa-form-header button {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
}
.wa-form-body {
    padding: 20px;
}
.wa-form-body p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 15px;
    line-height: 1.4;
}
.wa-form-body form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.wa-form-body input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.3s ease;
}
.wa-form-body input:focus {
    border-color: #25D366;
}
.wa-submit-btn {
    margin-top: 10px;
    width: 100%;
    justify-content: center;
}

/* ==========================================================================
   Premium Video Section
   ========================================================================== */
.premium-video-section {
    position: relative;
    width: 100%;
    height: 75vh;
    min-height: 600px;
    max-height: 900px;
    overflow: hidden;
    margin-bottom: 30px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    background: var(--bg-dark);
}
#hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 1;
}
.video-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to right, rgba(10, 38, 71, 0.95) 0%, rgba(10, 38, 71, 0.6) 50%, rgba(10, 38, 71, 0.1) 100%);
    z-index: 2;
    pointer-events: none;
}
.video-content {
    position: relative;
    z-index: 3;
    color: white;
    max-width: 700px;
    padding: 0 50px;
}
.video-content h2 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 15px;
    line-height: 1.1;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
}
.video-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.95;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
    line-height: 1.6;
}

/* ==========================================================================
   MEDIA QUERIES (MOBILE E TABLET)
   ========================================================================== */
@media (max-width: 768px) {
    /* Header e Navegação */
    .top-bar-inner { flex-direction: column; align-items: center; gap: 10px; text-align: center; }
    .top-bar-right { flex-direction: column; align-items: center; gap: 10px; }
    .header-inner { flex-direction: column; gap: 15px; text-align: center; }
    .logo-img { max-height: 80px; max-width: 100%; }
    .search-bar { width: 100%; }
    .header-actions { flex-direction: column; align-items: stretch; width: 100%; gap: 10px; }
    .action-btn { justify-content: center; }
    .nav-list { flex-wrap: wrap; justify-content: center; }
    .nav-list li a { padding: 8px 12px; font-size: 0.8rem; }

    /* Carrossel Principal */
    .carousel-container { height: auto; min-height: 500px; }
    .banner-slide-inner { flex-direction: column; justify-content: center; text-align: center; padding-top: 40px; padding-bottom: 40px; }
    .carousel-slide .banner-text { max-width: 100%; margin-bottom: 30px; }
    .banner-text h1 { font-size: 2.2rem; }
    .banner-text p { font-size: 1rem; }
    .carousel-slide .banner-image { width: 100%; justify-content: center; }
    .carousel-slide .banner-image img { max-height: 250px; }

    /* Mini Banners e Features */
    .mini-banners-grid { grid-template-columns: 1fr; }
    .features-bar { flex-direction: column; gap: 20px; align-items: flex-start; }

    /* Premium Video Section Mobile */
    .premium-video-section { height: 400px; border-radius: 8px; }
    .video-overlay { background: linear-gradient(to bottom, rgba(10, 38, 71, 0.9) 0%, rgba(10, 38, 71, 0.5) 100%); }
    .video-content { padding: 0 20px; text-align: center; margin: 0 auto; }
    .video-content h2 { font-size: 2.2rem; }
    .video-content p { font-size: 1rem; }

    /* Catálogo (index.html) */
    .catalog-layout { flex-direction: column; }
    .sidebar { width: 100%; margin-bottom: 20px; }
    .toolbar { flex-direction: column; gap: 15px; text-align: center; }
    .ecom-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 15px; }

    /* Página de Produto (produto.html) */
    .product-block { flex-direction: column; padding: 20px; }
    .product-gallery, .product-info { width: 100%; }
    .product-info h1 { font-size: 1.6rem; }
    .pdp-tabs-nav { flex-direction: column; }
    .pdp-tab-btn { border-right: none; border-bottom: 1px solid var(--border-color); }
    .pdp-tabs-content { padding: 20px; }
    .specs-table td { display: block; width: 100% !important; padding: 5px 0; }
    .specs-table tr { padding: 10px 0; display: block; border-bottom: 1px solid var(--border-color); }
    .specs-table td:first-child { padding-bottom: 0; color: var(--text-muted); font-size: 0.85rem; }
    .specs-table td:last-child { padding-top: 0; font-weight: 600; color: var(--text-main); border: none; }

    /* Rodapé */
    .footer-inner { grid-template-columns: 1fr; gap: 30px; text-align: center; }
    .wa-floating-btn { width: 50px; height: 50px; font-size: 1.5rem; }
}
