/* ============================================
   RESET E VARIÁVEIS CSS
   ============================================ */

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

:root {
    /* Paleta de cores */
    --amarelo-principal: #FFC107;
    --amarelo-escuro: #FFA000;
    --amarelo-claro: #FFECB3;
    --preto: #1a1a1a;
    --cinza-escuro: #2c2c2c;
    --cinza-medio: #666666;
    --cinza-claro: #f5f5f5;
    --branco: #ffffff;
    
    /* Espaçamentos responsivos */
    --spacing-xs: clamp(0.25rem, 1vw, 0.5rem);
    --spacing-sm: clamp(0.5rem, 2vw, 1rem);
    --spacing-md: clamp(1rem, 3vw, 1.5rem);
    --spacing-lg: clamp(1.5rem, 4vw, 2rem);
    --spacing-xl: clamp(2rem, 5vw, 3rem);
    --spacing-xxl: clamp(3rem, 6vw, 4rem);
    
    /* Tipografia */
    --font-principal: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    
    /* Bordas e sombras */
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
    
    /* Transições */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-principal);
    line-height: 1.6;
    color: var(--preto);
    background-color: var(--branco);
    overflow-x: hidden;
    min-width: 320px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all var(--transition-fast);
}

ul {
    list-style: none;
}

/* ============================================
   HEADER / NAVEGAÇÃO - MOBILE FIRST
   ============================================ */

.header {
    background-color: var(--preto);
    padding: 1rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-md);
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.logo img {
    max-height: 40px;
    width: auto;
}

.botoes ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    width: 100%;
}

.botoes li {
    flex: 1 1 auto;
    min-width: 80px;
}

.botoes a {
    display: block;
    padding: 0.75rem 1rem;
    background-color: var(--amarelo-principal);
    color: var(--preto);
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: var(--border-radius);
    text-align: center;
    transition: all var(--transition-normal);
}

.botoes a:hover,
.botoes a:active {
    background-color: var(--amarelo-escuro);
    transform: scale(1.02);
}

/* ============================================
   MAIN CONTAINER
   ============================================ */

main {
    min-height: calc(100vh - 200px);
    width: 100%;
}

section {
    padding: 2rem 1rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

section h2 {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
    color: var(--preto);
    margin-bottom: 1.5rem;
    text-align: center;
    position: relative;
    padding-bottom: 1rem;
}

section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--amarelo-principal), var(--amarelo-escuro));
    border-radius: 2px;
}

/* ============================================
   HERO / WELCOME SECTION - MOBILE FIRST
   ============================================ */

.welcome {
    background: linear-gradient(135deg, var(--preto) 0%, var(--cinza-escuro) 100%);
    padding: 3rem 1rem;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    width: 100%;
}

.welcome::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, var(--amarelo-principal) 0%, transparent 70%);
    opacity: 0.1;
}

.image-welcome {
    text-align: center;
    position: relative;
    z-index: 1;
    max-width: 100%;
    padding: 0 1rem;
}

.image-welcome h1 {
    font-size: clamp(1.5rem, 7vw, 3.5rem);
    color: var(--branco);
    margin-bottom: 1rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
    line-height: 1.2;
    word-wrap: break-word;
}

.image-welcome p {
    font-size: clamp(1rem, 4vw, 1.5rem);
    color: var(--amarelo-claro);
    font-weight: 300;
}

/* ============================================
   CARDS DE PRODUTOS - TOTALMENTE RESPONSIVO
   ============================================ */

.products-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
    width: 100%;
}

.cardproduct {
    background-color: var(--branco);
    border-radius: var(--border-radius-lg);
    padding: 1rem;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    border: 2px solid transparent;
    width: 100%;
    max-width: 100%;
}

.cardproduct:hover,
.cardproduct:active {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--amarelo-principal);
}

.cardproduct img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
    background-color: var(--cinza-claro);
}

.cardproduct h3,
.cardproduct h2 {
    font-size: clamp(1.1rem, 3vw, 1.25rem);
    color: var(--preto);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.cardproduct p {
    color: var(--cinza-medio);
    margin-bottom: 1rem;
    flex-grow: 1;
    font-size: 0.95rem;
}

.price {
    font-size: clamp(1.25rem, 4vw, 1.5rem);
    font-weight: 700;
    color: var(--preto);
    margin: 0.75rem 0;
}

.price.promo {
    color: var(--amarelo-escuro);
    position: relative;
}

.price.promo::before {
    content: '🔥';
    margin-right: 0.5rem;
}

.categoria {
    display: inline-block;
    background-color: var(--cinza-claro);
    color: var(--cinza-medio);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

/* ============================================
   BOTÕES - RESPONSIVOS
   ============================================ */

.btn {
    display: block;
    padding: 1rem 1.5rem;
    background-color: var(--amarelo-principal);
    color: var(--preto);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--border-radius);
    text-align: center;
    transition: all var(--transition-normal);
    border: 2px solid var(--amarelo-principal);
    cursor: pointer;
    margin: 0.5rem 0;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn:hover,
.btn:active {
    background-color: var(--amarelo-escuro);
    border-color: var(--amarelo-escuro);
    transform: scale(1.02);
}

.cardproduct .btn:last-of-type {
    background-color: transparent;
    color: var(--amarelo-escuro);
    border: 2px solid var(--amarelo-escuro);
}

.cardproduct .btn:last-of-type:hover,
.cardproduct .btn:last-of-type:active {
    background-color: var(--amarelo-escuro);
    color: var(--branco);
}

/* ============================================
   SEÇÕES ESPECÍFICAS
   ============================================ */

.products-principal,
.promotions {
    background-color: var(--cinza-claro);
}

.products-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    width: 100%;
}

.empty {
    text-align: center;
    color: var(--cinza-medio);
    font-size: 1rem;
    padding: 2rem 1rem;
    background-color: var(--branco);
    border-radius: var(--border-radius);
}

/* ============================================
   FILTROS - MOBILE FIRST
   ============================================ */

.filters {
    background-color: var(--branco);
    padding: 1.5rem 1rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
    width: 100%;
}

.filters form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
}

.filters label {
    font-weight: 600;
    color: var(--preto);
    margin-bottom: 0.5rem;
    display: block;
    font-size: 0.95rem;
}

.filters select {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--cinza-claro);
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-family: inherit;
    background-color: var(--branco);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.filters select:focus {
    outline: none;
    border-color: var(--amarelo-principal);
}

.filters button {
    width: 100%;
    padding: 1rem 1.5rem;
    background-color: var(--amarelo-principal);
    color: var(--preto);
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
}

.filters button:hover,
.filters button:active {
    background-color: var(--amarelo-escuro);
    transform: scale(1.02);
}

/* ============================================
   DETALHE DO PRODUTO
   ============================================ */

.product-detail {
    display: flex;
    justify-content: center;
    padding: 2rem 1rem;
    width: 100%;
}

.product-detail .cardproduct {
    max-width: 600px;
    width: 100%;
}

.product-detail .cardproduct img {
    height: 300px;
}

.product-detail h2 {
    font-size: clamp(1.5rem, 5vw, 2rem);
    text-align: left;
    margin-bottom: 1rem;
}

.product-detail h2::after {
    display: none;
}

/* ============================================
   CONTATO - MOBILE FIRST
   ============================================ */

.contact {
    background-color: var(--cinza-claro);
    width: 100%;
}

.social {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
    width: 100%;
}

.social ul {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    width: 100%;
}

.social a {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--amarelo-principal);
    color: var(--preto);
    font-weight: 600;
    border-radius: var(--border-radius);
    transition: all var(--transition-normal);
    font-size: 1rem;
}

.social a:hover,
.social a:active {
    background-color: var(--amarelo-escuro);
    transform: scale(1.05);
}

.location {
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    max-width: 100%;
    margin: 0 auto;
}

.location iframe {
    width: 100%;
    height: 300px;
    border: none;
    display: block;
}

/* ============================================
   PÁGINA 404
   ============================================ */

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

.mt-3 {
    margin-top: 2rem;
    padding: 3rem 1rem;
}

.mt-3 h1 {
    font-size: clamp(3rem, 15vw, 8rem);
    color: var(--amarelo-principal);
    margin-bottom: 1rem;
}

.mt-3 p {
    font-size: clamp(1.1rem, 4vw, 1.5rem);
    color: var(--cinza-medio);
    margin-bottom: 1.5rem;
}

/* ============================================
   FOOTER
   ============================================ */

footer {
    background-color: var(--preto);
    color: var(--branco);
    padding: 1.5rem 1rem;
    margin-top: 3rem;
    width: 100%;
}

.rodape {
    text-align: center;
    max-width: 1400px;
    margin: 0 auto;
}

.rodape p {
    font-size: 0.95rem;
    color: var(--amarelo-claro);
}

/* ============================================
   MEDIA QUERIES - TABLET (768px+)
   ============================================ */

@media (min-width: 768px) {
    .header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 2rem;
    }
    
    .logo {
        margin-bottom: 0;
    }
    
    .logo img {
        max-height: 50px;
    }
    
    .botoes ul {
        justify-content: flex-end;
    }
    
    .botoes li {
        flex: 0 1 auto;
    }
    
    .botoes a {
        font-size: 1rem;
        padding: 0.75rem 1.5rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .products-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .cardproduct img {
        height: 220px;
    }
    
    .welcome {
        min-height: 400px;
        padding: 4rem 2rem;
    }
    
    section {
        padding: 3rem 2rem;
    }
    
    .filters form {
        flex-direction: row;
        align-items: flex-end;
    }
    
    .filters button {
        width: auto;
        padding: 1rem 2rem;
    }
    
    .location iframe {
        height: 400px;
    }
    
    .product-detail .cardproduct img {
        height: 350px;
    }
}

/* ============================================
   MEDIA QUERIES - DESKTOP (1024px+)
   ============================================ */

@media (min-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    .products-list {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    .cardproduct img {
        height: 240px;
    }
    
    .cardproduct:hover {
        transform: translateY(-8px);
    }
    
    .welcome {
        min-height: 500px;
    }
    
    .location iframe {
        height: 450px;
    }
    
    .product-detail .cardproduct img {
        height: 400px;
    }
}

/* ============================================
   MEDIA QUERIES - LARGE DESKTOP (1280px+)
   ============================================ */

@media (min-width: 1280px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2.5rem;
    }
    
    .products-list {
        grid-template-columns: repeat(4, 1fr);
        gap: 2.5rem;
    }
    
    .cardproduct img {
        height: 260px;
    }
    
    .welcome {
        min-height: 600px;
        padding: 5rem 3rem;
    }
    
    section {
        padding: 4rem 3rem;
    }
}

/* ============================================
   ANIMAÇÕES (apenas em telas maiores)
   ============================================ */

@media (min-width: 768px) and (prefers-reduced-motion: no-preference) {
    .welcome::before {
        animation: pulse 8s ease-in-out infinite;
    }
    
    @keyframes pulse {
        0%, 100% { transform: scale(1); opacity: 0.1; }
        50% { transform: scale(1.2); opacity: 0.15; }
    }
}

/* Acessibilidade */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles para acessibilidade */
a:focus-visible,
button:focus-visible,
select:focus-visible {
    outline: 3px solid var(--amarelo-principal);
    outline-offset: 2px;
}

/* Touch targets mínimos (44x44px) */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .botoes a,
    .social a,
    .filters button {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Print styles */
@media print {
    .header,
    .botoes,
    .filters,
    footer,
    .btn {
        display: none;
    }
    
    .cardproduct {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid var(--cinza-claro);
    }
    
    body {
        background: white;
    }
}