:root {
    --primary-color: #FF9AA2; /* Rosa Pastel */
    --secondary-color: #FFDAC1; /* Pêssego */
    --accent-color: #FF6F61; /* Coral Vibrante */
    --text-color: #4A4A4A;
    --bg-color: #FFF5F5; /* Fundo Rosado Claro */
    --card-bg: #FFFFFF;
    --font-heading: 'VT323', monospace; /* Fonte Retro/Zine */
    --font-body: 'Quicksand', sans-serif; /* Fonte Fofa */
}

html { scroll-behavior: smooth; }
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* Header */
header {
    background-color: #fff;
    padding: 1rem 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 3px solid var(--text-color); /* Borda estilo cartoon */
}

.logo {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: var(--accent-color);
    text-shadow: 2px 2px 0px var(--secondary-color);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 25px;
}

nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
    transition: color 0.3s;
    font-size: 1.1rem;
}

nav a:hover { color: var(--accent-color); }

.group-link {
    background: var(--secondary-color);
    padding: 5px 10px;
    border-radius: 15px;
    border: 1px solid var(--text-color);
}

/* Hero */
.hero {
    background: linear-gradient(rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.6)), url('https://images.unsplash.com/photo-1550614000-4b9519e02a48?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-color);
    border-bottom: 3px solid var(--text-color);
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    margin-bottom: 1rem;
    line-height: 1;
    text-shadow: 3px 3px 0px #fff;
}

.btn-cta {
    background-color: var(--accent-color);
    color: white;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
    border: 2px solid var(--text-color);
    box-shadow: 4px 4px 0px var(--text-color); /* Sombra dura */
    transition: transform 0.2s, background 0.2s;
    display: inline-block;
    margin-top: 20px;
}

.btn-cta:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px var(--text-color);
}

/* Info Bar */
.infos-bar {
    display: flex;
    justify-content: space-around;
    background-color: var(--secondary-color);
    padding: 1.5rem;
    border-bottom: 3px solid var(--text-color);
    flex-wrap: wrap;
    gap: 10px;
}

.info-item {
    text-align: center;
    font-weight: bold;
    font-family: var(--font-heading);
    font-size: 1.2rem;
}

.info-item span {
    display: block;
    font-size: 1.5rem;
    margin-bottom: 5px;
}

/* Shop & Grid */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.filters {
    text-align: center;
    margin-bottom: 3rem;
}

.search-bar {
    padding: 8px 15px;
    border: 2px solid var(--text-color);
    border-radius: 20px;
    font-family: var(--font-body);
    width: 100%;
    max-width: 300px;
    margin-bottom: 15px;
    outline: none;
    display: block; /* Fica em linha própria no mobile */
    margin: 0 auto 15px auto; /* Centralizado */
}

.filter-btn {
    background: #fff;
    border: 2px solid var(--text-color);
    color: var(--text-color);
    padding: 8px 20px;
    margin: 0 5px;
    cursor: pointer;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    box-shadow: 3px 3px 0px var(--secondary-color);
    transition: all 0.3s;
}

.filter-btn.active, .filter-btn:hover {
    background-color: var(--primary-color);
    transform: translate(1px, 1px);
    box-shadow: 2px 2px 0px var(--text-color);
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
}

.product-grid {
    display: flex; /* Mudança para carrossel no mobile */
    flex-wrap: nowrap;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 2.5rem;
    padding-bottom: 20px; /* Espaço para scrollbar */
}

/* Scrollbar fofa */
.product-grid::-webkit-scrollbar {
    height: 8px;
}
.product-grid::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

.product-card {
    min-width: 280px; /* Tamanho fixo para carrossel */
    scroll-snap-align: center;
    background: var(--card-bg);
    border-radius: 15px;
    border: 2px solid var(--text-color);
    overflow: hidden;
    position: relative; /* Para posicionar o badge de vendido */
    box-shadow: 5px 5px 0px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.product-card:hover { transform: translateY(-3px); }

.image-container {
    position: relative;
    width: 100%;
    height: 280px;
    overflow: hidden;
    border-bottom: 2px solid var(--text-color);
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0; /* Oculta todas por padrão */
    transition: opacity 0.4s ease-in-out; /* Efeito de fade suave */
}

.product-image.active {
    opacity: 1; /* Mostra apenas a ativa */
    z-index: 2; /* Garante que a imagem ativa fique por cima dos outros elementos, mas abaixo dos botões */
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid var(--text-color);
    cursor: pointer;
    color: var(--text-color);
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    transition: all 0.2s;
    z-index: 5;
}

.slider-btn:hover { background: var(--accent-color); color: white; }
.slider-btn.prev { left: 10px; }
.slider-btn.next { right: 10px; }

.product-info { padding: 1.5rem; }
.product-title { font-family: var(--font-heading); font-size: 1.5rem; margin-bottom: 0.5rem; }
.product-price { color: var(--accent-color); font-weight: bold; font-size: 1.1rem; }

/* --- Estilos de Produto Vendido --- */
.product-card.sold .product-image {
    filter: grayscale(100%);
    opacity: 0.7;
}

.product-card.sold .product-title {
    text-decoration: line-through;
    color: #999;
}

.sold-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #ff4d4d;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    transform: rotate(15deg);
    box-shadow: 2px 2px 0px #333;
    z-index: 10;
}

/* Feedbacks */
.feedbacks-section {
    background-color: #fff;
    padding: 3rem 1.5rem;
    text-align: center;
    border-top: 3px solid var(--text-color);
}

.feedbacks-section h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.feedback-grid {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.feedback-card {
    background: var(--bg-color);
    padding: 1.5rem;
    border-radius: 15px;
    border: 2px dashed var(--primary-color);
    max-width: 300px;
    position: relative;
}

.feedback-card span {
    display: block;
    margin-top: 10px;
    font-weight: bold;
    color: var(--accent-color);
}

/* --- Instagram Highlights --- */
.instagram-highlights {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.highlight-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-color);
    width: 80px;
    transition: transform 0.2s;
}

.highlight-item:hover {
    transform: translateY(-5px);
}

.highlight-circle {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); /* Gradiente Insta */
    margin-bottom: 8px;
}

.highlight-circle img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 3px solid #fff;
    object-fit: cover;
}

/* --- Video Section --- */
.video-section {
    margin: 30px auto;
    text-align: center;
}

.styled-video {
    width: 100%;
    max-width: 320px; /* Largura próxima de um celular */
    border-radius: 15px;
    border: 3px solid var(--text-color);
    box-shadow: 6px 6px 0px var(--secondary-color);
}

footer {
    background-color: var(--text-color);
    color: var(--secondary-color);
    text-align: center;
    padding: 2rem;
    margin-top: 0;
}

/* Desktop Grid adjustment */
@media (min-width: 768px) {
    .product-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        overflow-x: visible;
    }
    .product-card {
        min-width: auto;
    }
}

/* --- Melhorias de Responsividade (Mobile) --- */
@media (max-width: 767px) {
    header {
        flex-direction: column;
        padding: 1rem;
        gap: 15px;
    }

    .logo {
        font-size: 1.8rem;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
        width: 100%;
    }

    .hero {
        height: 50vh; /* Altura menor para caber melhor em telas verticais */
    }

    .hero h1 {
        font-size: 2.8rem; /* Fonte menor para não quebrar */
    }

    /* Ajuste do Carrossel de Produtos */
    .product-grid {
        gap: 1rem; /* Menos espaço entre os cards */
        padding-left: 1rem; /* Margem para o primeiro item não colar na borda */
        padding-right: 1rem;
    }

    .product-card {
        min-width: 85vw; /* O card ocupa 85% da largura da tela */
    }

    /* Botões de filtro com espaço vertical caso quebrem linha */
    .filter-btn {
        margin-bottom: 10px;
    }

    /* Modal ocupando quase toda a tela */
    .modal-content {
        width: 95%;
        padding: 1.5rem;
        max-height: 80vh; /* Altura segura para não cortar botões no mobile */
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* Rolagem suave no iPhone */
    }

    /* Notificações centralizadas e mais altas (para não cobrir botão topo) */
    #toast-container {
        left: 10px;
        right: 10px;
        bottom: 80px;
    }

    /* Destaques do Instagram com rolagem horizontal */
    .instagram-highlights {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding: 0 10px 10px 10px;
    }
    
    .highlight-item {
        flex: 0 0 auto; /* Impede que os ícones encolham */
    }
}

/* --- Admin Modal & Login --- */
.admin-trigger {
    cursor: pointer;
    text-decoration: underline;
    font-size: 0.8rem;
    opacity: 0.5;
}

.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    display: none; /* Oculto por padrão */
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: #fff;
    padding: 2rem;
    border-radius: 15px;
    border: 3px solid var(--text-color);
    box-shadow: 8px 8px 0px var(--primary-color);
    width: 90%;
    max-width: 400px;
    text-align: center;
}

.admin-form input, .admin-form select {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px solid var(--text-color);
    border-radius: 8px;
    font-family: var(--font-body);
}

.btn-admin {
    background: var(--secondary-color);
    border: 2px solid var(--text-color);
    padding: 8px 16px;
    cursor: pointer;
    font-weight: bold;
    border-radius: 8px;
    margin-top: 10px;
}

.btn-delete {
    background: #ff4d4d;
    color: white;
    border: none;
    padding: 5px;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 5px;
}

/* --- Cart Quantity Controls --- */
.cart-qty-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 5px;
}

.btn-qty {
    background: var(--secondary-color);
    border: 1px solid var(--text-color);
    width: 25px;
    height: 25px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.btn-qty:hover {
    background: var(--accent-color);
    color: white;
}

/* --- Toast Notifications --- */
#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: #fff;
    border: 2px solid var(--text-color);
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 4px 4px 0px var(--primary-color);
    font-family: var(--font-heading);
    font-size: 1.2rem;
    min-width: 250px;
    animation: slideIn 0.3s ease-out forwards;
}

.toast.success { border-color: #4CAF50; box-shadow: 4px 4px 0px #4CAF50; }
.toast.error { border-color: #ff4d4d; box-shadow: 4px 4px 0px #ff4d4d; }

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes fadeOut {
    to { opacity: 0; transform: translateY(10px); }
}

.btn-toggle-sold {
    background: #4CAF50; /* Verde Dinheiro */
    color: white;
    border: none;
    padding: 5px;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 5px;
}

/* --- Back to Top Button --- */
#back-to-top {
    position: fixed;
    bottom: 20px;
    left: 20px; /* Lado esquerdo para não atrapalhar o toast/whatsapp */
    background: var(--accent-color);
    color: white;
    border: 2px solid var(--text-color);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
    cursor: pointer;
    display: none; /* Oculto inicialmente */
    z-index: 990;
    box-shadow: 2px 2px 0px var(--text-color);
    transition: transform 0.2s;
}
#back-to-top:hover { transform: translateY(-3px); }

/* --- Cart Styles --- */
.cart-content {
    max-width: 500px; /* Um pouco mais largo que o login */
    text-align: left;
}

.cart-items-container {
    max-height: 300px;
    overflow-y: auto;
    margin: 20px 0;
    border-top: 2px dashed var(--secondary-color);
    border-bottom: 2px dashed var(--secondary-color);
    padding: 10px 0;
}

.cart-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    background: var(--bg-color);
    padding: 10px;
    border-radius: 8px;
}

.cart-item img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 15px;
    border: 1px solid var(--text-color);
}

.cart-item-info {
    flex-grow: 1;
}

.cart-item-title {
    font-weight: bold;
    font-size: 1rem;
}

.cart-item-price {
    color: var(--accent-color);
    font-size: 0.9rem;
}

.cart-total {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    text-align: right;
    color: var(--text-color);
    margin-bottom: 10px;
}
