* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, sans-serif;
    background-color: #f5f5f7;
    color: #1d1d1f;
    line-height: 1.5;
}

/* ========== HEADER ========== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid #e0e0e0;
    z-index: 1000;
    padding: 12px 24px;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -1px;
    color: #000;
    text-decoration: none;
}
.logo:hover { opacity: 0.8; }

.search-bar {
    flex: 1;
    max-width: 400px;
    padding: 10px 16px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    background: #fff;
    font-size: 16px;
    transition: all 0.2s;
    cursor: pointer;
}
.search-bar:focus {
    outline: none;
    border-color: #007aff;
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
}

.cart-icon {
    position: relative;
    text-decoration: none;
    font-size: 22px;
    color: #1d1d1f;
}
.cart-count {
    position: absolute;
    top: -8px;
    right: -12px;
    background: #ff3b30;
    color: white;
    font-size: 11px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 20px;
    min-width: 18px;
    text-align: center;
}

/* ========== MAIN ========== */
main {
    padding-top: 80px;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
    min-height: calc(100vh - 200px);
}

/* ========== CABEÇALHO DA CATEGORIA ========== */
.categoria-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
    flex-wrap: wrap;
}
.categoria-header .btn-voltar {
    color: #007aff;
    text-decoration: none;
    font-weight: 500;
}
.categoria-header .btn-voltar:hover {
    text-decoration: underline;
}
.categoria-header h1 {
    font-size: 32px;
    font-weight: 700;
}
.categoria-header .icone-categoria {
    font-size: 28px;
}

/* ========== GRID DE PRODUTOS ========== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 48px;
}

/* ========== CARD DO PRODUTO ========== */
.product-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}
.product-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #f9f9fb;
}
.product-card .info {
    padding: 16px;
}
.product-card .info h3 {
    font-size: 16px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 4px;
}
.product-card .info .preco {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
}
.product-card .info .btn-comprar {
    display: block;
    width: 100%;
    padding: 8px;
    background: #007aff;
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.product-card .info .btn-comprar:hover {
    background: #0051b3;
}

/* ========== SEM PRODUTOS ========== */
.sem-produtos {
    text-align: center;
    padding: 60px 24px;
    background: white;
    border-radius: 20px;
    grid-column: 1 / -1;
}
.sem-produtos p {
    color: #6e6e73;
    font-size: 18px;
}

/* ========== FOOTER ========== */
.footer {
    background: #f5f5f7;
    border-top: 1px solid #e0e0e0;
    padding: 32px 24px;
    text-align: center;
    color: #6e6e73;
    font-size: 14px;
    margin-top: 48px;
}
.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}
.footer-social {
    display: flex;
    gap: 16px;
}
.footer-social a {
    color: #6e6e73;
    transition: color 0.2s;
}
.footer-social a:hover {
    color: #007aff;
}

/* ========== RESPONSIVO ========== */
@media (max-width: 900px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 600px) {
    .categoria-header h1 {
        font-size: 24px;
    }
    .products-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    .product-card img {
        height: 160px;
    }
    .product-card .info h3 {
        font-size: 14px;
    }
    .product-card .info .preco {
        font-size: 15px;
    }
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}