/* ==========================================================================
   ÁREA VITRINE GERAL (Componentes Reutilizáveis)
   ========================================================================== */

/* --- 1. RESET E TIPOGRAFIA BASE --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    max-width: 100vw;
    overflow-x: clip; 
    background-color: #F4EBE1; 
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.15'/%3E%3C/svg%3E");
    color: #3E2723; 
    font-family: 'Cause', serif; 
    line-height: 1.6;
}

h1, h2, h3, .logo span {
    font-family: 'Cause', serif;
    font-weight: 700;
    color: #2D1A11;
}

/* --- 2. BOTÕES (Estrutura Base) --- 
   Usado em: Catálogo, Produto, Carrinho, Login, Cadastro, Biblioteca, Sucesso */
.btn-primary, 
.btn-add-cart, 
.btn-checkout, 
.auth-btn, 
.btn-download, 
.btn-success-action {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    border: none;
    font-family: 'Cause', serif;
    font-weight: bold;
    font-size: 1.1rem;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

/* Cores Padrão dos Botões Principais */
.btn-primary, 
.auth-btn, 
.btn-add-cart,
.btn-download { 
    background-color: #B26B68; 
    color: #FFFFFF !important; /* Força o branco contra o roxo de link visitado */
}

.btn-primary:hover, 
.auth-btn:hover, 
.btn-add-cart:hover { 
    background-color: #8C524F; 
}

/* --- 3. CARTÕES E CONTAINERS --- 
   Usado em: Produtos, Auth, Biblioteca, Carrinho, Sucesso */
.product-card, 
.auth-container, 
.library-card, 
.cart-item, 
.cart-summary, 
.success-order-box {
    background-color: #FFFFFF;
    border: 1px solid #E0D4C8;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

/* --- 4. CAMPOS DE DIGITAÇÃO E SELEÇÃO (Inputs) --- 
   Usado em: Login, Cadastro, Reset, Carrinho (Cupom) */
.input-group input, 
.coupon-input {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #D7CCC8;
    border-radius: 8px;
    font-family: 'Cause', serif;
    font-size: 1rem;
    background-color: #F8F5EE;
    color: #3E2723;
    transition: border-color 0.3s;
    box-sizing: border-box;
    outline: none;
}

.input-group input:focus, 
.coupon-input:focus {
    border-color: #B26B68;
    background-color: #FFFFFF;
}

/* --- 5. ALERTAS E MENSAGENS FLASH --- 
   Usado em: Carrinho, Login, Cadastro */
.flash-message, 
.auth-alert {
    padding: 12px 15px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.msg-success, 
.alert-success { 
    background-color: #e8f5e9; 
    color: #2e7d32; 
    border: 1px solid rgba(46, 125, 50, 0.25); 
}

.msg-error, 
.alert-error { 
    background-color: #ffebee; 
    color: #c62828; 
    border: 1px solid rgba(198, 40, 40, 0.25); 
}

/* --- 6. ÍCONES DE CABEÇALHO (Headers Ilustrados) --- 
   Usado em: Login, Cadastro, Reset, Políticas */
.auth-header-icon, 
.policies-header-icon {
    font-size: 3rem;
    color: #B26B68;
    margin-bottom: 10px;
    display: inline-block;
}

/* --- 7. ESTADOS VAZIOS (Empty States) --- 
   Usado em: Biblioteca, Carrinho, Busca */
.library-empty, 
.cart-empty-container, 
.empty-search-container {
    text-align: center;
    padding: 4rem 2rem;
    background: #fcf8f2;
    border-radius: 12px;
    border: 1px dashed #D7CCC8;
    margin: 20px auto;
    grid-column: 1/-1; /* Garante que ocupe todo o espaço caso esteja num Grid */
}

/* ==========================================================================
   CABEÇALHO, MENU E RODAPÉ (base.html)
   ========================================================================== */

/* --- 1. LAYOUT GERAL DA PÁGINA E SCROLLBAR --- */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; 
    margin: 0;
}

main { 
    flex: 1; 
}

::-webkit-scrollbar { width: 12px; }
::-webkit-scrollbar-track { background: #F1EBE0; border-left: 1px solid #D7CCC8; }
::-webkit-scrollbar-thumb { background-color: #B26B68; border-radius: 10px; border: 3px solid #F1EBE0; }
::-webkit-scrollbar-thumb:hover { background-color: #8C524F; }

/* --- 2. CABEÇALHO PRINCIPAL --- */
.main-header {
    display: grid;
    grid-template-columns: 1fr 1.5fr 1fr;
    align-items: center;
    gap: 20px;
    padding: 0.8rem 5%;
    background-color: #F4EBE1;
    border-bottom: 1px solid #e0d8c3;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-left { display: flex; align-items: center; }
.header-search { width: 100%; }
.header-right { 
    display: flex; 
    align-items: center; 
    justify-content: flex-end; 
    gap: 20px; 
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    text-decoration: none;
}

.header-logo-img {
    max-height: 100px;
}

/* --- 3. BARRA DE BUSCA --- */
.search-form {
    display: flex;
    background: white;
    border: 2px solid #D7CCC8;
    border-radius: 25px; 
    overflow: hidden;
    max-width: 450px;
    margin: 0 auto;
    transition: border-color 0.3s;
}

.search-form:focus-within { border-color: #B26B68; }

.search-form input {
    border: none;
    padding: 8px 15px;
    flex-grow: 1;
    font-family: 'Cause', serif;
    outline: none;
    font-size: 0.9rem;
}

.search-form button {
    background: none;
    border: none;
    padding: 0 15px;
    color: #B26B68;
    cursor: pointer;
    font-size: 1.1rem;
}

/* --- 4. NAVEGAÇÃO E AÇÕES DO USUÁRIO --- */
.header-nav { 
    display: flex; 
    gap: 20px; 
}

.header-nav a, 
.header-user-actions > a {
    text-decoration: none;
    color: #5D4037;
    font-weight: 600;
    transition: color 0.3s;
}

.header-nav a:hover,
.header-user-actions > a:hover {
    color: #A1887F; /* Transiciona para o marrom suave idêntico aos outros links */
}

.header-user-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cart-icon {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* --- 5. MENU DO USUÁRIO (Dropdown) --- */
.user-dropdown {
    position: relative;
    cursor: pointer;
    padding: 5px 0;
}

.user-name {
    font-weight: 600;
    color: #5D4037;
    font-size: 0.9rem;
}

.user-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid #e0d8c3;
    border-radius: 8px;
    min-width: 160px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    z-index: 1001;
    padding: 10px 0;
}

.user-dropdown:hover .user-menu { display: block; }

.user-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    text-decoration: none;
    color: #5D4037;
    font-size: 0.85rem;
    transition: background 0.2s;
}

.user-menu a:hover { background: #F4EBE1; color: #B26B68; }

/* --- 6. MENU CATÁLOGO EM CASCATA --- */
.menu-catalogo-container {
    display: inline-block;
    position: relative; 
}

.btn-catalogo {
    align-items: center;
    display: inline-flex;
    gap: 4px;
}

.icon-caret-down { font-size: 0.8rem; margin-left: 2px; }
.icon-caret-right { font-size: 0.7rem; margin-left: auto; }

/* Dropdown Nível 1 (Pastas Pai) */
.dropdown-pai {
    background-color: #ffffff;
    border: 1px solid #D7CCC8;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(93, 64, 55, 0.12);
    display: none; 
    left: 0;
    list-style: none;
    margin: 0;
    min-width: 220px;
    padding: 8px 0;
    position: absolute;
    top: 100%; 
    z-index: 1000;
}

.item-pai { position: relative; }

.dropdown-pai a {
    align-items: center;
    color: #5D4037 !important; 
    display: flex;
    font-family: 'Cause', serif;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 10px 20px;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.dropdown-pai a:hover {
    background-color: #F1EBE0; 
    color: #B26B68 !important; 
}

/* Dropdown Nível 2 (Subpastas) */
.dropdown-filho {
    background-color: #ffffff;
    border: 1px solid #D7CCC8;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(93, 64, 55, 0.12);
    display: none; 
    left: 100%; 
    list-style: none;
    margin: 0;
    min-width: 200px;
    padding: 8px 0;
    position: absolute;
    top: -8px; 
    z-index: 1001;
}

.dropdown-filho.invertido {
    left: auto; 
    right: 100%; 
}

/* Gatilhos do Menu em Cascata */
.menu-catalogo-container:hover .dropdown-pai { display: block; }
.item-pai:hover .dropdown-filho { display: block; }

/* --- 7. RODAPÉ (FOOTER) --- */
footer {
    margin-top: auto;
    text-align: center;
    padding: 2rem;
    background-color: #F1EBE0;
    color: #795548;
    border-top: 1px solid #D7CCC8;
    font-size: 0.9rem;
}

.footer-policy-link {
    color: inherit;
    text-decoration: underline;
}

/* --- 8. RESPONSIVIDADE DO CABEÇALHO (Celulares e Tablets) --- */
@media (max-width: 900px) {
    .main-header {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 15px;
        padding: 15px 20px;
        position: relative;
    }

    .header-left {
        width: 100%;
        justify-content: center;
        order: 1; 
    }

    .header-right {
        width: 100%;
        justify-content: center;
        order: 2; 
    }

    .header-search {
        width: 100%;
        order: 3; 
    }

    .header-nav { 
        display: flex; 
        gap: 15px; 
    } 
}

/* ==========================================================================
   PÁGINA INICIAL E VITRINE (index.html)
   ========================================================================== */

/* --- 1. HERO E TÍTULOS DE SEÇÃO --- */
.hero {
    text-align: center;
    padding: 5rem 2rem;
    background-color: transparent; 
    border-bottom: 1px dashed #D7CCC8; 
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.hero p {
    font-size: 1.2rem;
    color: #5D4037;
    max-width: 600px;
    margin: 0 auto;
}

.catalog-preview {
    padding: 4rem 5%;
    text-align: center;
}

.catalog-preview h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
}

.catalog-preview h2::before,
.catalog-preview h2::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40px;
    height: 1px;
    background-color: #D7CCC8;
}

.catalog-preview h2::before { left: -50px; }
.catalog-preview h2::after { right: -50px; }

/* --- 2. CARROSSEL DE BANNERS --- */
.banner-carousel-container {
    max-width: 1200px;
    margin: 2rem auto 4rem auto; 
    padding: 0 5%; 
    position: relative;
}

.banner-slider {
    position: relative;
    width: 100%;
    height: 500px; 
    border-radius: 16px; 
    border: 4px solid #ffffff;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(93, 64, 55, 0.15); 
}

.banner-track {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.banner-slide {
    min-width: 100%; 
    height: 100%;
}

.banner-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
}

/* Setas do Banner */
.banner-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.85);
    color: #5D4037;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10;
    transition: background 0.3s, transform 0.2s, color 0.3s;
    box-shadow: 0 4px 10px rgba(93, 64, 55, 0.1);
}

.banner-nav:hover {
    background: #B26B68;
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.banner-nav.prev { left: 3%; } 
.banner-nav.next { right: 3%; }

/* Bolinhas de Navegação */
.banner-dots {
    text-align: center;
    margin-top: 15px;
}

.banner-dots .dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin: 0 5px;
    background-color: #D7CCC8; 
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.banner-dots .dot.active {
    background-color: #B26B68; 
    transform: scale(1.3); 
}

/* --- 3. GRID DE PRODUTOS E CARDS --- */
.grid-produtos {
    display: flex;
    flex-wrap: wrap; 
    justify-content: center; 
    gap: 2rem;
    margin-top: 2rem;
}

/* --- AJUSTE DE PREÇOS E ALINHAMENTO DO CARD --- */
.price-container {
    display: flex;
    align-items: center; 
    justify-content: center; /* Mágica que centraliza os dois preços juntos no meio! */
    gap: 10px;          
    margin-bottom: 1.2rem;
}

.price-old {
    text-decoration: line-through !important; /* Garante o risco do preço anterior */
    color: #999 !important;                   /* Pinta com o cinza discreto de oferta */
    font-size: 0.9rem;
}

.product-price {
    font-size: 1.2rem;
    font-weight: bold;
    color: #3E2723;
    margin-bottom: 0 !important; /* Zera a margem padrão do navegador que estava quebrando o alinhamento! */
}

/* Base do card + Animações de Hover */
.product-card {
    overflow: hidden; 
    flex: 1 1 280px; 
    max-width: 320px; 
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-8px); 
    box-shadow: 0 15px 30px rgba(93, 64, 55, 0.15);
}

.product-image-link {
    display: block;
    overflow: hidden;
    border-radius: 8px 8px 0 0;
}

.product-image {
    width: 100%;
    height: 250px;
    object-fit: cover; 
    border-bottom: 1px solid #E0D4C8; 
    transition: transform 0.4s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05); 
}

.product-info {
    padding: 1.5rem; 
    text-align: center; /* Mudado de left para center para alinhar o título! */
}

.product-title-link {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

.product-info h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #2D1A11;
}

.product-card .product-info h3 a:hover {
    color: #B26B68;
}

.product-details {
    font-size: 0.8rem;
    color: #795548;
    margin-bottom: 1rem;
}

.product-price {
    font-size: 1.2rem;
    font-weight: bold;
    color: #3E2723;
    margin-bottom: 1.5rem;
}

.product-action-container {
    display: flex;
    gap: 10px;
}

.btn-full-width {
    width: 100%; /* A mágica que força o botão inline-flex a esticar e ocupar o card todo */
    flex: 1;
    text-align: center;
}

/* --- 4. RESPONSIVIDADE INDEX (Celulares) --- */
@media (max-width: 900px) {
    .hero h1 { font-size: 2rem; }
    .catalog-preview h2::before, .catalog-preview h2::after { display: none; }
    
    .banner-slider { height: 250px; border-radius: 12px; border-width: 3px; }
    .banner-nav { width: 35px; height: 35px; font-size: 1.2rem; }
    .banner-nav.prev { left: 1%; }
    .banner-nav.next { right: 1%; }
    
    .product-image { height: 300px; }
}

@media (max-width: 768px) {
    .grid-produtos {
        padding: 0 15px;
    }
}

/* ==========================================================================
   CATÁLOGO E PASTAS (catalogo.html e catalogo_itens.html)
   ========================================================================== */

/* --- 1. CABEÇALHOS E BREADCRUMBS --- */
.catalogo-header {
    text-align: center;
    margin-top: 40px;
}

.catalog-breadcrumb {
    padding: 20px 40px;
    background: #F1EBE0;
}

.breadcrumb-link {
    color: #b26b68;
    text-decoration: none;
}

.catalog-title {
    font-family: 'Cause', serif;
    text-align: center;
    margin-bottom: 30px;
}

.products-list {
    padding: 40px;
}

/* --- 2. GRID DE PASTAS E SUBPASTAS --- */
.grid-pastas {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    padding: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.subfolders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto 40px auto;
    border-bottom: 1px solid #ddd;
    padding-bottom: 30px;
}

/* --- 3. A ENGENHARIA DA PASTA MÁGICA (Desenho via CSS) --- */
.folder-card, 
.subfolder-card {
    text-decoration: none;
    color: inherit;
    text-align: center;
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.subfolder-card {
    background: transparent;
    padding: 10px;
}

.folder-wrapper {
    position: relative;
    width: 220px; 
    height: 160px; 
    margin: 0 auto 20px auto;
}

.subfolder-wrapper {
    width: 180px;
    height: 130px;
}

.folder-tab {
    position: absolute;
    top: -15px;
    left: 0;
    width: 80px;
    height: 25px;
    background: linear-gradient(90deg, #5D4037 0%, #B26B68 100%);
    border-radius: 8px 15px 0 0; 
    z-index: 1;
}

.subfolder-tab {
    width: 60px;
    height: 20px;
    top: -12px;
}

.folder-body {
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: #E0D4C8; 
    border-radius: 0 12px 12px 12px;
    overflow: hidden; 
    border: 2px solid #5D4037;
    z-index: 2;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.folder-body::after {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.05), transparent);
    pointer-events: none;
}

.folder-custom-art {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
}

.folder-empty-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 50px;
    color: #B26B68;
}

.subfolder-icon-container {
    font-size: 40px; /* Ícone levemente menor para subpastas */
}

/* Textos da Pasta */
.folder-title, 
.subfolder-title {
    font-family: 'Cause', serif;
}

.subfolder-title { margin: 10px 0 0 0; }

.folder-subtitle {
    font-size: 0.9rem;
    color: #8c7365;
}

.folder-empty-message, 
.empty-catalog-message {
    grid-column: 1/-1;
    text-align: center;
    color: #795548;
}

/* Hover Effects das Pastas */
.folder-card:hover { transform: translateY(-10px); }
.subfolder-card:hover { transform: translateY(-5px); }

.folder-card:hover .folder-icon, 
.subfolder-card:hover .folder-icon { 
    color: #5d4037; 
}

/* --- 4. PAGINAÇÃO --- */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 40px;
    font-family: 'Cause', serif;
}

.page-link {
    text-decoration: none;
    padding: 8px 16px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.page-link-disabled {
    color: #ccc;
    padding: 8px 16px;
    border: 1px dashed #D7CCC8;
    border-radius: 6px;
    cursor: not-allowed;
    font-weight: bold;
    opacity: 0.6;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.page-current {
    color: #5D4037;
    font-weight: bold;
    background: #F1EBE0;
    padding: 8px 16px;
    border-radius: 6px;
}

/* ==========================================================================
   PÁGINA DO PRODUTO (produto.html)
   ========================================================================== */

.product-page {
    padding: 4rem 5%;
    max-width: 1200px;
    margin: 0 auto; 
}

.product-breadcrumb {
    margin-bottom: 1rem;
    text-align: center;
}

.product-header-highlight {
    text-align: center;
    margin-bottom: 3rem;
}

.product-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); 
    gap: 4rem;
    align-items: start;
}

/* --- 1. TÍTULO MÁGICO (Efeito Adesivo) --- */
.sticker-effect {
    font-family: 'Chewy', cursive; 
    font-size: 3.5rem; 
    color: #B26B68; 
    text-align: center;
    letter-spacing: 2px;
    text-shadow: 
        -4px -4px 0 #fff,  
         4px -4px 0 #fff,
        -4px  4px 0 #fff,
         4px  4px 0 #fff,
         0px  8px 15px rgba(93, 64, 55, 0.15); 
}
.product-main-title { margin-bottom: 1rem; }

/* --- 2. BILHETE VINTAGE DE PREÇO E ANIMAÇÃO --- */
.vintage-ticket-price {
    display: inline-block;
    background-color: #FCF8F2;
    border: 2px dashed #D7CCC8;
    border-radius: 12px;
    padding: 1.5rem 2.5rem;
    box-shadow: 0 4px 15px rgba(93, 64, 55, 0.08);
    margin-top: 0.5rem;
}

.ticket-badges {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 8px;
}

.badge-promo {
    background: #5D4037;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.badge-discount {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
}

.ticket-values {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 15px;
}

.price-original { font-size: 1.1rem; color: #999; text-decoration: line-through; }
.price-promo, .price-normal { color: #B26B68; font-weight: bold; font-size: 2.2rem; }

@keyframes pulse-anim {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(93, 64, 55, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 0 10px 0 rgba(93, 64, 55, 0.1); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(93, 64, 55, 0); }
}
.pulse-magic { animation: pulse-anim 2s infinite ease-in-out; }

/* --- 3. GALERIA DE IMAGENS E ZOOM --- */
.product-image-wrapper { width: 100%; }

.main-image-box {
    position: relative;
    cursor: pointer;
    background: #fafaf8;
    border-radius: 12px;
    border: 1px solid #e0d8c3;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 350px;
}

.product-main-image-display {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.3s ease;
}

.zoom-icon-overlay {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(93, 64, 55, 0.8);
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    pointer-events: none;
}

.product-placeholder-icon { font-size: 4rem; color: #B26B68; }

.product-thumbnails-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 12px;
    margin-top: 15px;
}

.thumb-item {
    border: 2px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.thumb-item.active { border-color: #5D4037; }
.thumb-item:hover { border-color: #B26B68 !important; transform: translateY(-2px); }
.thumb-image { width: 100%; height: 100%; object-fit: cover; display: block; }

/* --- 4. LIGHTBOX DE ZOOM (FULLSCREEN) --- */
.lightbox-overlay {
    display: none;
    position: fixed;
    z-index: 9999;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(30, 21, 18, 0.95);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.btn-lightbox-close {
    position: absolute;
    top: 20px; right: 20px;
    background: none; border: none;
    color: #fff; font-size: 2.5rem;
    cursor: pointer; transition: transform 0.2s;
}
.btn-lightbox-close:hover { transform: scale(1.2); }

.btn-lightbox-nav {
    position: absolute;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    width: 50px; height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s;
}
.btn-lightbox-nav:hover { background: #B26B68 !important; }
.btn-lightbox-prev { left: 20px; }
.btn-lightbox-next { right: 20px; }

.lightbox-img-content {
    max-width: 85%; max-height: 85%;
    object-fit: contain; border-radius: 6px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5); user-select: none;
}

/* --- 5. DESCRIÇÃO, BOTÃO E SELOS DE CONFIANÇA --- */
.product-info-wrapper { width: 100%; }

.product-description {
    background-color: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(5px); 
    border: 1px solid rgba(224, 216, 195, 0.4); 
    border-radius: 8px; 
    margin-top: 0; 
    padding: 20px; 
    color: #5D4037;
    font-size: 1.1rem;
}

.product-description ul { list-style-type: none; margin-top: 1rem; padding-left: 0; }
.product-description li { margin-bottom: 0.8rem; }

.product-action { margin-top: 2.5rem; }

/* Modificadores do Botão de Carrinho que sobraram da Área Geral */
.btn-add-cart { width: 100%; padding: 1.2rem; font-size: 1.2rem; }
.btn-add-cart:hover { box-shadow: 0 8px 20px rgba(178, 107, 104, 0.2); }
.btn-add-cart:active { transform: scale(0.98); }

.product-trust-badges {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem; 
    margin-top: 2rem; 
    padding-top: 1.5rem; 
    border-top: 1px dashed #e0d8c3; 
}

.badge-item {
    display: flex; align-items: center; gap: 10px; 
    color: #795548; font-size: 0.95rem; font-weight: 500;
}
.badge-item i { color: #B26B68; font-size: 1.3rem; }

/* --- 6. RESPONSIVIDADE (Celular) --- */
@media (max-width: 900px) {
    .product-container {
        grid-template-columns: 1fr !important;
        gap: 2rem;
    }
}

/* ==========================================================================
   CARRINHO E BIBLIOTECA (carrinho.html e biblioteca.html)
   ========================================================================== */

/* --- 1. ESTRUTURA DO CARRINHO --- */
.cart-page {
    padding: 4rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.cart-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #D7CCC8;
    padding-bottom: 1rem;
}

.cart-container {
    display: grid;
    grid-template-columns: 2fr 1fr; 
    gap: 3rem;
    align-items: start;
}

/* Itens do Carrinho */
.cart-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.cart-item-image-link { display: block; }

.cart-item img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #E0D4C8;
}

.item-info { flex-grow: 1; }

.item-info h3 {
    font-size: 1.2rem;
    color: #2D1A11;
    margin-bottom: 0.3rem;
}

.cart-item-title-link {
    text-decoration: none;
    color: inherit;
}

.item-price {
    font-weight: bold;
    font-size: 1.2rem;
    color: #3E2723;
}

.cart-item-old-price {
    text-decoration: line-through;
    font-size: 0.8rem;
    color: #999;
    display: block;
}

.btn-remove {
    background: none;
    border: none;
    color: #B26B68;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s;
}
.btn-remove:hover { color: #8C524F; }

/* Resumo do Pedido e Cupons */
.cart-summary {
    padding: 2rem;
}

.cart-summary h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #D7CCC8;
    padding-bottom: 0.5rem;
}

.coupon-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed #D7CCC8;
}

.coupon-applied-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #e8f5e9;
    padding: 10px;
    border-radius: 8px;
}

.coupon-applied-text { color: #2e7d32; font-weight: bold; }
.coupon-remove-link { color: #d32f2f; text-decoration: none; font-size: 0.8rem; font-weight: bold; }
.coupon-form { display: flex; gap: 8px; }

.btn-apply-coupon {
    background: #5D4037;
    color: white;
    border: none;
    padding: 0 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
}

.summary-line {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.summary-line-discount { color: #B26B68; font-weight: bold; }
.summary-line-coupon { color: #2e7d32; font-weight: bold; }

.summary-line.total {
    font-weight: bold;
    font-size: 1.5rem;
    border-top: 1px solid #D7CCC8;
    padding-top: 1rem;
    margin-top: 1rem;
    color: #B26B68;
}

.btn-checkout { width: 100%; padding: 1rem; background-color: #5D4037; color: white; margin-top: 1.5rem; }
.btn-checkout:hover { background-color: #3E2723; }
.secure-payment-text { font-size: 0.8rem; color: #795548; margin-top: 1rem; text-align: center; }

/* Transições e Animações do Carrinho */
.cart-page .cart-item img,
.cart-page .cart-item .item-info h3 a {
    transition: all 0.3s ease-in-out;
}

.cart-page .cart-item a:has(img):hover img {
    transform: translateY(-5px) scale(1.04);
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}

.cart-page .cart-item .item-info h3 a:hover {
    color: #B26B68;
    transform: scale(1.02);
    display: inline-block;
}

@keyframes girar {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.icone-girando { display: inline-block; animation: girar 1s linear infinite; }


/* --- 2. ESTRUTURA DA BIBLIOTECA --- */
.library-page {
    padding: 3rem 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.library-header { text-align: center; margin-bottom: 3rem; }
.library-header h1 { font-size: 2.5rem; margin-bottom: 0.5rem; }
.library-header p { color: #666; font-size: 1.1rem; }

/* Alerta de Senha do PDF */
.library-password-alert {
    background-color: #fcf8f2;
    border-left: 4px solid #B26B68;
    padding: 20px;
    margin: 0 auto 30px auto;
    border-radius: 8px;
    max-width: 1200px;
    text-align: left;
    box-shadow: 0 2px 8px rgba(93, 64, 55, 0.05);
}

.library-password-title {
    color: #B26B68;
    margin-top: 0; margin-bottom: 8px;
    font-family: 'Cause', serif;
    display: flex; align-items: center; gap: 8px; font-size: 1.2rem;
}

.library-password-icon { font-size: 1.4rem; }
.library-password-text { margin: 0; font-size: 0.95rem; color: #5D4037; line-height: 1.6; }

/* Grid e Cards de Download */
.library-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; 
    gap: 2rem;
}

.library-card {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    text-align: center;
    width: 300px; 
    transition: transform 0.2s;
}
.library-card:hover { transform: translateY(-5px); }

.library-image-container { margin-bottom: 1.5rem; border-radius: 8px; overflow: hidden; background: #f9f9f9; }

.library-product-image {
    width: 100%; height: auto; display: block; object-fit: cover; aspect-ratio: 1 / 1; 
}

.library-info h3 { font-family: 'Cause', serif; color: #2D1A11; margin: 0 0 0.5rem 0; font-size: 1.3rem; }
.library-category { font-size: 0.9rem; color: #888; margin-bottom: 1.5rem; }
.library-order-info { font-size: 0.8rem; color: #999; margin-bottom: 10px; font-weight: 500; font-family: monospace; }
.library-download-info { font-size: 0.8rem; color: #795548; margin-bottom: 15px; font-weight: 600; }

/* Modificadores do Botão de Download */
.btn-download { width: 100%; margin-top: 15px; }
.btn-download:hover { background-color: #9c5c59; }

.btn-download-disabled { background-color: #ccc; border-color: #ccc; cursor: not-allowed; opacity: 0.8; margin-bottom: 5px; }
.library-limit-text { font-size: 0.75rem; color: #B26B68; font-weight: bold; display: block; margin-top: 5px; }
.btn-download-cooldown { background-color: #E67E22; cursor: wait; }

.library-empty-icon { font-size: 4rem; color: #B26B68; }
.btn-empty-library { display: inline-block; margin-top: 20px; text-decoration: none; }

@keyframes ph-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.ph-spin { animation: ph-spin 2s infinite linear; }


/* --- 3. RESPONSIVIDADE EM CONTEXTO DE COMPRA --- */
@media (max-width: 900px) {
    .cart-container {
        grid-template-columns: 1fr !important;
        gap: 2rem;
    }

    .cart-item {
        flex-direction: column; 
        text-align: center;
        padding: 1.5rem;
        position: relative;
    }

    .cart-item img {
        width: 120px;
        height: 120px;
        margin-bottom: 1rem;
    }

    .btn-remove {
        position: absolute;
        top: 10px; right: 10px;
        background: #fff;
        border-radius: 50%;
        width: 35px; height: 35px;
        display: flex; align-items: center; justify-content: center;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }
    
    .library-page { padding: 2rem 15px; }
}

/* ==========================================================================
   CONTATO, AUTENTICAÇÃO, POLÍTICAS E SUCESSO
   ========================================================================== */

/* --- 1. PÁGINA DE CONTATO (contato.html) --- */
.contact-page-section {
    max-width: 900px;
    margin: 60px auto;
    padding: 0 20px;
    text-align: center;
}

.contact-page-title {
    font-family: 'Cause', serif;
    color: #5D4037;
    font-size: 2.5rem;
}

.contact-page-subtitle {
    color: #8c7365;
    margin-bottom: 40px;
}

.contact-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.contact-card {
    text-decoration: none;
    color: inherit;
    padding: 30px;
    background: #fafaf8;
    border-radius: 15px;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-card:hover { 
    transform: translateY(-5px); 
    box-shadow: 0 10px 20px rgba(93, 64, 55, 0.08);
    background: #ffffff !important; 
}

.contact-card-icon { width: 55px; height: 55px; object-fit: contain; }
.contact-card-title { margin: 15px 0 5px 0; font-family: 'Cause', serif; color: #5D4037; }
.contact-card-desc { font-size: 0.9rem; color: #8c7365; margin: 0; }

/* FAQ de Dúvidas Frequentes */
.faq-container {
    text-align: left;
    background: #F1EBE0;
    padding: 40px;
    border-radius: 20px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.faq-main-title { font-family: 'Cause', serif; color: #5D4037; margin-bottom: 20px; text-align: center; }
.faq-item-bordered { margin-bottom: 20px; border-bottom: 1px dashed #D7CCC8; padding-bottom: 15px; }
.faq-item-last { margin-bottom: 10px; }
.faq-question { color: #5D4037; display: block; margin-bottom: 5px; }
.faq-answer { color: #795548; font-size: 0.95rem; margin: 0; line-height: 1.5; }


/* --- 2. PÁGINAS DE AUTENTICAÇÃO (Login, Cadastro, Esqueci e Reset) --- */
.auth-page {
    padding: 4rem 5%;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70vh; 
}

.auth-container {
    padding: 3rem;
    width: 100%;
    max-width: 450px; 
}

.auth-header { text-align: center; margin-bottom: 2rem; }
.auth-header h2 { font-size: 2rem; margin-top: 1rem; color: #2D1A11; }
.auth-header p { color: #795548; font-size: 1rem; }
.auth-form { display: flex; flex-direction: column; gap: 1.5rem; }
.input-group { display: flex; flex-direction: column; gap: 0.5rem; }
.input-group label { font-weight: 600; color: #5D4037; font-size: 0.95rem; }

.auth-btn { margin-top: 1rem; padding: 1rem; font-size: 1.1rem; }
.auth-footer { margin-top: 2rem; text-align: center; font-size: 0.95rem; color: #5D4037; border-top: 1px solid #E0D4C8; padding-top: 1.5rem; }
.auth-footer a { color: #B26B68; font-weight: bold; text-decoration: none; transition: color 0.3s; }
.auth-footer a:hover { color: #8C524F; text-decoration: underline; }

.forgot-password-container { text-align: center; margin-top: 15px; }
.forgot-link { font-size: 0.9rem; color: #B26B68; text-decoration: none; font-weight: 600; }
.forgot-link:hover { opacity: 0.8; text-decoration: underline; }


/* --- 3. PÁGINA DE POLÍTICAS (politicas.html) --- */
.policies-page { padding: 3rem 5%; max-width: 900px; margin: 0 auto; }

.policies-container {
    background-color: rgba(255, 255, 255, 0.5); 
    backdrop-filter: blur(5px);
    border: 1px solid #e0d8c3;
    border-radius: 12px;
    padding: 3rem;
    box-shadow: 0 8px 30px rgba(93, 64, 55, 0.05);
}

.policies-header { text-align: center; margin-bottom: 3rem; }
.policies-header h1 { font-family: 'Cause', serif; color: #5D4037; font-size: 2.8rem; margin: 1rem 0 0.5rem 0; }
.policies-header p { color: #795548; font-size: 1.1rem; }
.policies-content { display: flex; flex-direction: column; gap: 2.5rem; }
.policy-section { border-bottom: 1px dashed rgba(224, 216, 195, 0.6); padding-bottom: 2rem; }
.policy-section:last-child { border-bottom: none; padding-bottom: 0; }
.policy-section h2 { font-family: 'Cause', serif; color: #5D4037; font-size: 1.4rem; margin-bottom: 1rem; }
.policy-section p { color: #5d4037e0; line-height: 1.7; font-size: 1.05rem; margin-bottom: 1rem; }
.policy-section ul { list-style-type: none; padding-left: 0; }
.policy-section li { position: relative; padding-left: 25px; color: #5D4037; line-height: 1.6; font-size: 1rem; margin-bottom: 0.8rem; }

/* Detalhe do marcador de estrela */
.policy-section li::before {
    content: "✦"; 
    position: absolute; left: 0; top: 2px;
    color: #B26B68; font-size: 0.8rem;
}


/* --- 4. TELA DE SUCESSO (sucesso.html) --- */
.success-page-section { max-width: 600px; margin: 60px auto; padding: 0 20px; text-align: center; }
.success-icon-wrapper { margin-bottom: 25px; }

.success-icon-sparkles {
    font-size: 4.5rem; color: #B26B68;
    display: inline-block;
    animation: flutuar 3s ease-in-out infinite;
}

.success-title { font-family: 'Cause', serif; color: #5D4037; font-size: 2.5rem; margin-bottom: 10px; }
.success-subtitle { color: #8c7365; font-size: 1.1rem; margin-bottom: 30px; }

.success-order-box {
    padding: 15px; margin-bottom: 30px;
    font-family: monospace; font-size: 1.1rem; color: #5D4037;
    display: inline-block;
}

.success-summary-box { text-align: left; background: #F1EBE0; padding: 30px; border-radius: 15px; margin-bottom: 40px; box-shadow: 0 4px 10px rgba(0,0,0,0.02); }
.success-summary-title { font-family: 'Cause', serif; color: #5D4037; margin-top: 0; margin-bottom: 20px; border-bottom: 1px solid #D7CCC8; padding-bottom: 10px; font-size: 1.3rem; }
.success-summary-item { display: flex; justify-content: space-between; margin-bottom: 12px; border-bottom: 1px dashed #E0D4C8; padding-bottom: 8px; font-size: 0.95rem; }
.success-item-name { color: #5D4037; font-weight: 500; }
.success-item-price { color: #3E2723; }
.success-total-row { display: flex; justify-content: space-between; margin-top: 25px; font-size: 1.3rem; font-weight: bold; color: #B26B68; }
.success-reminder-text { font-size: 0.9rem; color: #8c7365; margin-bottom: 25px; }

.btn-success-action { padding: 15px 40px; font-size: 1.1rem; font-weight: bold; box-shadow: 0 4px 15px rgba(178, 107, 104, 0.3); }

@keyframes flutuar {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}