@import url("https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700&family=DM+Sans:wght@400;500;600;700&display=swap");

:root {
    --wine-900: #3a0b25;
    --wine-800: #51102f;
    --wine-700: #74134e;
    --wine-600: #86155c;
    --cream: #faf7f5;
    --soft-pink: #f8f0f4;
    --white: #ffffff;
    --gold: #d6af57;
    --gold-soft: #e6cf91;
    --text-primary: #30252c;
    --text-secondary: #675761;
    --border: #e9dde3;
    --success: #218447;
    --cor-principal: var(--wine-700);
    --cor-principal-escura: var(--wine-900);
    --cor-secundaria: var(--wine-600);
    --cor-rose: var(--soft-pink);
    --cor-destaque: var(--gold);
    --cor-fundo: var(--cream);
    --cor-branco: var(--white);
    --cor-texto: var(--text-primary);
    --cor-texto-suave: var(--text-secondary);
    --cor-borda: var(--border);
    --cor-sucesso: var(--success);
    --fonte-titulo: "Cormorant Garamond", Georgia, serif;
    --fonte-texto: "DM Sans", Arial, sans-serif;
    --shadow-xs: 0 1px 2px rgba(58, 11, 37, 0.04);
    --shadow-sm: 0 10px 30px rgba(58, 11, 37, 0.07);
    --shadow-md: 0 20px 50px rgba(58, 11, 37, 0.12);
    --sombra-suave: var(--shadow-sm);
    --sombra-media: var(--shadow-md);
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
    --header-height: 74px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-height) + 20px);
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
}

body {
    min-height: 100vh;
    font-family: var(--fonte-texto);
    background: var(--cream);
    color: var(--text-primary);
    font-size: 17px;
    line-height: 1.55;
    text-rendering: optimizeLegibility;
    overflow-x: clip;
}

body.menu-aberto { overflow: hidden; }
main { width: 100%; min-height: 48vh; }
img, video { max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button, input, textarea, select { font: inherit; }
button, a, [role="button"] { touch-action: manipulation; }
button, [role="button"], .botao-categoria, .categorias-catalogo a {
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
}
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
:focus-visible { outline: 3px solid rgba(214, 175, 87, 0.72); outline-offset: 3px; }
::selection { background: var(--gold-soft); color: var(--wine-900); }

.container { width: min(1220px, calc(100% - 48px)); margin-inline: auto; }

.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--wine-700);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}
.section-kicker::before { content: ""; width: 28px; height: 1px; background: var(--gold); }

.section-title, .page-title h1, .page-title h2 {
    font-family: var(--fonte-titulo);
    font-size: clamp(2.35rem, 4.8vw, 4.15rem);
    font-weight: 600;
    color: var(--wine-800);
    line-height: 0.98;
    letter-spacing: -0.025em;
}
.section-title::after {
    content: "";
    display: block;
    width: 58px;
    height: 2px;
    margin-top: 18px;
    background: var(--gold);
}
.texto-suave { color: var(--text-secondary); line-height: 1.75; }

.page-title { padding: 72px 0 38px; text-align: center; }
.page-title .section-title::after { margin-inline: auto; }
.page-title p { max-width: 720px; margin: 18px auto 0; }

.page-hero {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 420px;
    display: grid;
    align-items: center;
    overflow: hidden;
    isolation: isolate;
    background: #eadbd4;
}
.page-hero__media {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    object-position: center;
}
.page-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(90deg, rgba(250, 247, 245, 0.97) 0%, rgba(250, 247, 245, 0.84) 30%, rgba(250, 247, 245, 0.18) 58%, rgba(250, 247, 245, 0) 78%);
    pointer-events: none;
}
.page-hero__content { width: min(1220px, calc(100% - 48px)); margin-inline: auto; padding-block: 54px; }
.page-hero__content > div { max-width: 590px; }
.page-hero h1, .page-hero h2 {
    max-width: 760px;
    font-family: var(--fonte-titulo);
    font-size: clamp(3.2rem, 7.4vw, 6.75rem);
    font-weight: 600;
    line-height: 0.88;
    letter-spacing: -0.045em;
    color: var(--wine-900);
}
.page-hero p {
    max-width: 520px;
    margin-top: 20px;
    color: var(--wine-800);
    font-size: clamp(1rem, 1.6vw, 1.24rem);
    line-height: 1.6;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.botao-primario, .botao-secundario, .botao-claro, .botao-comprar-agora, .botao-adicionar-carrinho {
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 13px 24px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    transition: transform 140ms var(--ease-out), background-color 180ms ease, color 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}
.botao-primario, .botao-comprar-agora {
    background: var(--wine-700);
    color: var(--white);
    box-shadow: 0 10px 22px rgba(116, 19, 78, 0.2);
}
.botao-secundario, .botao-adicionar-carrinho { background: var(--white); border-color: var(--wine-700); color: var(--wine-700); }
.botao-claro { background: var(--white); color: var(--wine-800); }
.botao-primario:active, .botao-secundario:active, .botao-claro:active, .botao-comprar-agora:active, .botao-adicionar-carrinho:active { transform: scale(0.97); }

.card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-xs); }
.grid-produtos { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.card-produto {
    min-width: 0;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-xs);
    transition: transform 220ms var(--ease-out), box-shadow 220ms ease, border-color 220ms ease;
}
.card-produto__imagem { width: 100%; aspect-ratio: 4 / 5; overflow: hidden; background: var(--soft-pink); }
.card-produto__imagem img, .card-produto__imagem video {
    width: 100%; height: 100%; display: block; object-fit: cover;
    transition: transform 260ms var(--ease-out);
}
.card-produto__imagem video { pointer-events: none; }
.card-produto__conteudo { flex: 1; display: flex; flex-direction: column; gap: 9px; padding: 15px 16px 17px; }
.card-produto__conteudo h3 {
    min-height: 42px;
    font-family: var(--fonte-titulo);
    font-size: 1.3rem;
    font-weight: 600;
    line-height: 1.12;
    color: var(--wine-800);
}
.precos-produto { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.preco-antigo { color: #81717b; font-size: 0.84rem; text-decoration: line-through; }
.preco-antigo:empty { display: none; }
.preco-atual { color: var(--wine-700); font-size: 1.2rem; font-weight: 700; }
.produto-entrega {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--success);
    font-size: 0.82rem;
    font-weight: 600;
}
.produto-entrega::before { content: ""; width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: currentColor; }

.estado-vazio { max-width: 680px; margin-inline: auto; padding: 42px 30px; text-align: center; }
.estado-vazio__icone {
    width: 62px; height: 62px; margin: 0 auto 18px; display: grid; place-items: center;
    border-radius: 50%; border: 1px solid var(--border); background: var(--soft-pink); color: var(--wine-700); font-size: 1.7rem;
}
.estado-vazio h3 { margin-bottom: 10px; font-family: var(--fonte-titulo); font-size: 1.8rem; color: var(--wine-800); }
.estado-vazio p { margin-bottom: 24px; }

.form-grid { display: grid; gap: 18px; }
.campo-formulario { display: grid; gap: 8px; }
.campo-formulario label, .form-preco label > span { color: var(--wine-800); font-size: 0.86rem; font-weight: 700; }
.campo-formulario input, .campo-formulario textarea, .campo-formulario select, .form-busca input, .form-preco input {
    width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 8px;
    background: var(--white); color: var(--text-primary); outline: none;
    transition: border-color 180ms ease, box-shadow 180ms ease;
}
.campo-formulario textarea { min-height: 128px; resize: vertical; }
.campo-formulario input:focus, .campo-formulario textarea:focus, .campo-formulario select:focus, .form-busca input:focus, .form-preco input:focus {
    border-color: var(--wine-700); box-shadow: 0 0 0 4px rgba(116, 19, 78, 0.09);
}
.mensagem-formulario { display: none; padding: 13px 15px; border: 1px solid var(--border); border-radius: 8px; background: var(--soft-pink); color: var(--text-primary); font-size: 0.94rem; }
.mensagem-formulario.ativo { display: block; }
.mensagem-formulario.sucesso { border-color: rgba(33, 132, 71, 0.35); background: rgba(33, 132, 71, 0.08); color: #155e35; }
.mensagem-formulario.erro { border-color: rgba(134, 21, 92, 0.28); background: rgba(134, 21, 92, 0.07); color: var(--wine-700); }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity 420ms var(--ease-out), transform 420ms var(--ease-out); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (hover: hover) and (pointer: fine) {
    .botao-primario:hover, .botao-comprar-agora:hover { background: var(--wine-600); box-shadow: 0 14px 30px rgba(116, 19, 78, 0.25); }
    .botao-secundario:hover, .botao-adicionar-carrinho:hover { background: var(--soft-pink); border-color: var(--wine-600); }
    .botao-claro:hover { background: var(--gold-soft); }
    .card-produto:hover { transform: translateY(-5px); border-color: rgba(116, 19, 78, 0.2); box-shadow: var(--shadow-md); }
    .card-produto:hover .card-produto__imagem img, .card-produto:hover .card-produto__imagem video { transform: scale(1.025); }
}

@media (max-width: 1024px) {
    .grid-produtos { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
    :root { --header-height: 66px; }
    .container, .page-hero__content { width: min(100% - 32px, 1220px); }
    .page-title { padding: 52px 0 28px; }
    .page-hero {
        aspect-ratio: auto;
        min-height: clamp(470px, 124vw, 560px);
        display: grid;
        background: #eadbd4;
    }
    .page-hero__media {
        position: absolute;
        inset: 0;
        z-index: -2;
        width: 100%;
        height: 100%;
        object-fit: cover;
        background: #eadbd4;
    }
    .page-hero::after {
        display: block;
        background: linear-gradient(90deg, rgba(250, 247, 245, 0.97) 0%, rgba(250, 247, 245, 0.9) 48%, rgba(250, 247, 245, 0.46) 100%);
    }
    .page-hero__content { padding-block: 48px; }
    .page-hero__content > div { max-width: min(480px, 88%); }
    .page-hero h1, .page-hero h2 { font-size: clamp(3.1rem, 14vw, 4.8rem); }
    .grid-produtos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}

@media (max-width: 480px) {
    .container, .page-hero__content { width: min(100% - 24px, 1220px); }
    .section-title { font-size: clamp(2.2rem, 11vw, 3rem); }
    .hero-actions > * { width: 100%; }
    .card-produto__conteudo { padding: 12px; }
    .card-produto__conteudo h3 { min-height: 40px; font-size: 1.12rem; }
    .precos-produto { display: block; }
    .preco-antigo { display: block; font-size: 0.78rem; }
    .preco-atual { font-size: 1.06rem; }
    .produto-entrega { font-size: 0.76rem; }
}

@media (max-width: 360px) { .grid-produtos { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
    .reveal { opacity: 1; transform: none; transition: opacity 160ms ease; }
}
