/* ================================================
   Marketplace Multivendedor - Estilo Principal
   Tema Visual Fiel ao Wolmart
   ================================================ */

:root {
    --primary-color: #00B853;
    --primary-dark: #00A047;
    --secondary-color: #E91E63;
    --text-dark: #1a1a1a;
    --text-light: #666666;
    --border-color: #e0e0e0;
    --bg-light: #f5f5f5;
    --bg-white: #ffffff;
    --success: #4CAF50;
    --warning: #FFC107;
    --danger: #f44336;
    --info: #2196F3;
    --rating-color: #FFC107;
}

/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-light);
    line-height: 1.6;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-dark);
}

/* Containers */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    flex: 1;
    padding: 0 15px;
    min-width: 0;
}

/* Header */
.header {
    background-color: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 0.875rem;
    border-bottom: 1px solid var(--border-color);
}

.header-top-left, .header-top-right {
    display: flex;
    gap: 20px;
    align-items: center;
}

.header-top a {
    color: var(--text-light);
    font-size: 0.875rem;
}

.header-top a:hover {
    color: var(--primary-color);
}

.header-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    gap: 20px;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background-color: var(--primary-color);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
}

.search-bar {
    flex: 1;
    max-width: 500px;
    display: flex;
    gap: 10px;
}

.search-bar select,
.search-bar input {
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95rem;
}

.search-bar select {
    min-width: 150px;
    background-color: var(--bg-white);
    cursor: pointer;
}

.search-bar input {
    flex: 1;
}

.search-bar button {
    padding: 10px 16px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.search-bar button:hover {
    background-color: var(--primary-dark);
}

.header-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.header-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: color 0.3s ease;
    position: relative;
}

.header-action:hover {
    color: var(--primary-color);
}

.header-action-icon {
    font-size: 1.5rem;
}

.header-action-label {
    font-size: 0.75rem;
    color: var(--text-light);
}

.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--danger);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

/* Category Navigation */
.category-nav {
    background-color: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
    overflow-x: auto;
}

.category-nav-scroll {
    display: flex;
    gap: 30px;
    min-width: min-content;
    padding: 0 15px;
}

.category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 100px;
    cursor: pointer;
    transition: color 0.3s ease;
    color: var(--text-light);
}

.category-item:hover {
    color: var(--primary-color);
}

.category-item-icon {
    width: 80px;
    height: 80px;
    background-color: var(--bg-light);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    transition: background-color 0.3s ease;
}

.category-item:hover .category-item-icon {
    background-color: var(--primary-color);
    color: white;
}

.category-item-name {
    font-size: 0.875rem;
    font-weight: 600;
    text-align: center;
    color: inherit;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #f5f5f5 0%, #ffffff 100%);
    padding: 40px 0;
    margin-bottom: 40px;
    border-bottom: 2px dashed var(--border-color);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.hero-text h2 {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 10px;
    font-weight: 400;
}

.hero-text h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.hero-discount {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 600;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.hero-cta {
    display: inline-block;
    padding: 12px 32px;
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hero-cta:hover {
    background-color: var(--primary-color);
    color: white;
}

.hero-image {
    text-align: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
}

/* Benefits Section */
.benefits {
    background-color: var(--bg-white);
    padding: 40px 0;
    margin-bottom: 40px;
    border: 2px dashed var(--border-color);
}

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

.benefit-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.benefit-icon {
    font-size: 2rem;
    color: var(--primary-color);
    flex-shrink: 0;
}

.benefit-text h4 {
    margin-bottom: 5px;
}

.benefit-text p {
    font-size: 0.9rem;
    margin: 0;
}

/* Products Section */
.section {
    background-color: var(--bg-white);
    padding: 40px 0;
    margin-bottom: 40px;
}

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

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
}

.section-more {
    color: var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

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

.product-card {
    background-color: var(--bg-light);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.product-image {
    width: 100%;
    aspect-ratio: 1;
    background-color: #e8e8e8;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

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

.product-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.product-card:hover .product-actions {
    opacity: 1;
}

.product-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.product-action-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

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

.product-name {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-dark);
    font-size: 0.95rem;
    line-height: 1.3;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 10px;
    font-size: 0.85rem;
}

.stars {
    color: var(--rating-color);
}

.reviews-count {
    color: var(--text-light);
}

.product-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 12px;
}

.price-current {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
}

.price-original {
    font-size: 0.9rem;
    color: var(--text-light);
    text-decoration: line-through;
}

.product-buttons {
    display: flex;
    gap: 8px;
    margin-top: auto;
}

.btn-add-cart,
.btn-select-options {
    flex: 1;
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.btn-add-cart {
    background-color: var(--primary-color);
    color: white;
}

.btn-add-cart:hover {
    background-color: var(--primary-dark);
}

.btn-select-options {
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-select-options:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
}

.tab {
    padding: 12px 0;
    cursor: pointer;
    color: var(--text-light);
    font-weight: 600;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

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

.tab:hover {
    color: var(--text-dark);
}

/* Vendors Section */
.vendors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.vendor-card {
    background-color: var(--bg-light);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.vendor-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.vendor-logo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: white;
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    overflow: hidden;
}

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

.vendor-name {
    font-weight: 700;
    margin-bottom: 5px;
}

.vendor-products {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 10px;
}

.vendor-rating {
    color: var(--rating-color);
    font-size: 0.9rem;
}

.vendor-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 15px;
}

.vendor-product-thumb {
    aspect-ratio: 1;
    background-color: white;
    border-radius: 4px;
    overflow: hidden;
}

.vendor-product-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    text-align: center;
}

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

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

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-small {
    padding: 6px 12px;
    font-size: 0.85rem;
}

/* Popup/Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background-color: white;
    border-radius: 8px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
}

.modal-close:hover {
    color: var(--text-dark);
}

.modal-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.modal-subtitle {
    color: var(--text-light);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-dark);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95rem;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 184, 83, 0.1);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.checkbox-group input {
    width: auto;
}

/* Footer */
.footer {
    background-color: var(--text-dark);
    color: white;
    padding: 40px 0 20px;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h4 {
    color: white;
    margin-bottom: 15px;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    display: block;
    margin-bottom: 8px;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
}

/* Scroll to Top */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    z-index: 999;
    transition: all 0.3s ease;
}

.scroll-to-top.visible {
    display: flex;
}

.scroll-to-top:hover {
    background-color: var(--primary-dark);
    transform: translateY(-5px);
}

/* Responsive */
@media (max-width: 768px) {
    .header-main {
        flex-direction: column;
        gap: 15px;
    }

    .search-bar {
        max-width: 100%;
    }

    .hero-content {
        grid-template-columns: 1fr;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .vendors-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .category-nav-scroll {
        gap: 15px;
    }

    .category-item-icon {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }

    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    .header-top {
        flex-direction: column;
        gap: 10px;
    }

    .header-actions {
        gap: 10px;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .vendors-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        width: 95%;
        padding: 20px;
    }
}
