/* ==========================================================
   style.css – Tema Sani Estilo (design claro, minimalista)
   Para mudar as cores do site, altere só as variáveis em :root
   ========================================================== */
:root {
    --ink: #1c1c1c;          /* texto, botões escuros, rodapé */
    --ink-soft: #3a3a3a;
    --bg: #ffffff;
    --soft: #f4f1ec;         /* bege das faixas (marcas, newsletter) */
    --line: #e7e3dd;         /* linhas e bordas */
    --muted: #6f6b66;
    --ok: #2f7d57; --low: #b7791f; --out: #b42318;
    --radius: 6px;
    --container: 1240px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color: var(--ink); background: var(--bg); line-height: 1.6; font-size: 16px; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .6em; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); }
.container { width: min(var(--container), 92%); margin: 0 auto; }
.section { padding: 56px 0; }
.section-tight { padding: 28px 0 64px; }
.center { text-align: center; } .right { text-align: right; }
.muted { color: var(--muted); } .small { font-size: .85rem; }
.hidden { display: none; }
.hp { position: absolute; left: -9999px; }
.mt { margin-top: 2em; }
code { background: #eeebe6; padding: 1px 6px; border-radius: 4px; font-size: .9em; }
.icon { width: 20px; height: 20px; flex: none; }
.icon-cat { width: 44px; height: 44px; }
[hidden] { display: none !important; }

/* ---------- Barra superior ---------- */
.topbar { background: var(--ink); color: #d8d4ce; font-size: .76rem; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 36px; }
.topbar .icon { width: 15px; height: 15px; vertical-align: -3px; margin-right: 4px; }
.topbar a { color: #fff; text-decoration: none; }
.topbar-left, .topbar-center, .topbar-right { display: flex; align-items: center; gap: 6px; }
.topbar-right { gap: 16px; }
.topbar-social { display: inline-flex; }
.topbar-social .icon { margin: 0; }

/* ---------- Cabeçalho ---------- */
.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.logo { text-decoration: none; color: var(--ink); display: inline-flex; align-items: center; flex: none; }
.site-logo { display: block; width: auto; height: 44px; max-width: 210px; object-fit: contain; }
.footer-brand .site-logo { height: 42px; max-width: 220px; filter: brightness(0) invert(1); margin-bottom: 12px; }
.login-box .site-logo { height: 48px; max-width: 240px; margin: 0 auto 10px; }
.logo-word { font-weight: 500; letter-spacing: .22em; font-size: 1.3rem; white-space: nowrap; }
.main-nav { display: flex; gap: 6px; align-items: center; }
.main-nav a { text-decoration: none; padding: 8px 14px; font-size: .92rem; border-radius: 4px; display: inline-flex; align-items: center; gap: 4px; }
.main-nav a:hover, .main-nav a.active { background: var(--soft); }
.main-nav .icon { width: 14px; height: 14px; }
.nav-item { position: relative; }
.dropdown { position: absolute; top: 100%; left: 0; min-width: 230px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 14px 36px rgba(0, 0, 0, .12); padding: 8px; display: none; flex-direction: column; }
.has-dropdown:hover .dropdown, .has-dropdown:focus-within .dropdown { display: flex; }
.dropdown a { display: block; padding: 9px 12px; }
.dropdown .dropdown-all { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 12px; font-weight: 600; }
.header-actions { display: flex; align-items: center; gap: 6px; }
.icon-btn { background: none; border: 0; padding: 8px; cursor: pointer; color: var(--ink); position: relative; border-radius: 50%; display: inline-flex; }
.icon-btn:hover { background: var(--soft); }
.icon-btn .icon { width: 22px; height: 22px; }
.cart-count { position: absolute; top: 0; right: 0; background: var(--ink); color: #fff; font-size: .65rem; min-width: 17px; height: 17px; border-radius: 9px; display: grid; place-items: center; }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; flex-direction: column; gap: 5px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); }
.search-panel { border-top: 1px solid var(--line); background: var(--soft); padding: 14px 0; }
.search-form { display: flex; gap: 10px; }
.search-form input { flex: 1; }

/* ---------- Botões ---------- */
.btn { display: inline-flex; align-items: center; gap: 10px; background: var(--ink); color: #fff; border: 1px solid var(--ink); padding: 12px 24px; border-radius: 3px; font-weight: 600; font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; cursor: pointer; font-family: inherit; }
.btn:hover { background: #000; border-color: #000; }
.btn .icon { width: 18px; height: 18px; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--soft); color: var(--ink); border-color: var(--ink); }
.btn-danger { background: var(--out); border-color: var(--out); }
.btn-danger:hover { background: #8f1c12; border-color: #8f1c12; }
.btn-small { padding: 6px 13px; font-size: .75rem; letter-spacing: .03em; }

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; overflow: hidden; min-height: clamp(420px, 44vw, 580px); background-color: #8b8174; display: flex; align-items: center; color: #fff; }
.hero::before { content: ""; position: absolute; z-index: 0; inset: 0; background: linear-gradient(90deg, rgba(20, 16, 12, .62) 0%, rgba(20, 16, 12, .32) 42%, rgba(20, 16, 12, 0) 72%); }
.hero-background { position: absolute; z-index: -1; inset: -2%; background-size: cover; background-position: center; transform: translate3d(0, 0, 0) scale(1.03); transform-origin: center center; backface-visibility: hidden; }
/* A entrada usa uma transição entre dois estados CSS permanentes, em vez de
   uma keyframe que termina e pode provocar um pequeno salto de composição. */
.hero-home .hero-background { transition: transform 2.8s cubic-bezier(.2, .65, .3, 1); }
.hero-home .hero-background.is-revealed { transform: translate3d(0, 0, 0) scale(1.01); }
.hero-inner { position: relative; z-index: 1; }
.hero-text { max-width: 480px; }
.eyebrow { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; margin: 0 0 14px; opacity: .92; }
.hero h1 { color: #fff; font-size: clamp(2.2rem, 5vw, 3.4rem); font-weight: 600; margin-bottom: .35em; }
.hero .lead { font-size: 1rem; max-width: 40ch; opacity: .95; margin: 0 0 26px; }
.hero .btn { background: #1c1c1c; }
.hero-home .hero-text > * { opacity: 0; animation: hero-copy-reveal .75s cubic-bezier(.2, .7, .2, 1) forwards; }
.hero-home .hero-text > .eyebrow { animation-delay: .2s; }
.hero-home .hero-text > h1 { animation-delay: .34s; }
.hero-home .hero-text > .lead { animation-delay: .48s; }
.hero-home .hero-text > .btn { animation-delay: .62s; transition: background-color .2s ease, transform .2s ease, box-shadow .2s ease; }
.hero-home .hero-text > .btn:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(0, 0, 0, .18); }
.hero-home .eyebrow::before { content: ""; display: inline-block; width: 27px; height: 1px; margin: 0 10px 4px 0; background: currentColor; opacity: .85; }
@keyframes hero-copy-reveal {
    from { opacity: 0; transform: translate3d(0, 18px, 0); }
    to { opacity: 1; transform: translate3d(0, 0, 0); }
}
@media (prefers-reduced-motion: reduce) {
    .hero-home .hero-background { transition: none !important; transform: translate3d(0, 0, 0) scale(1.01) !important; }
    .hero-home .hero-text > * { animation: none !important; opacity: 1 !important; transform: none !important; filter: none !important; }
    .hero-home .hero-text > .btn { transition: none; }
}

/* ---------- Faixa de categorias ---------- */
.cat-strip { border-bottom: 1px solid var(--line); }
.cat-strip-inner { display: flex; justify-content: space-between; gap: 8px; padding: 26px 0; overflow-x: auto; scrollbar-width: none; }
.cat-strip-inner::-webkit-scrollbar { display: none; }
.cat-item { display: flex; flex-direction: column; align-items: center; gap: 10px; text-decoration: none; min-width: 96px; flex: 1; font-size: .85rem; color: var(--ink-soft); transition: color .15s, transform .15s; }
.cat-item:hover { color: #000; transform: translateY(-2px); }
.cat-item .icon-cat { stroke-width: 1.3; }

/* ---------- Cabeçalhos de secção ---------- */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 26px; }
.section-head h2 { margin: 0; }
.eyebrow-dark { font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.link-all { font-size: .75rem; font-weight: 600; letter-spacing: .08em; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.link-all:hover { text-decoration: underline; }
.link-all .icon { width: 16px; height: 16px; }
.related-head { margin-top: 60px; }
.page-head { background: var(--soft); padding: 44px 0 36px; }
.page-head h1 { margin: 0; }

/* ---------- Grelhas e cartões de produto ---------- */
.grid { display: grid; gap: 22px; }
.grid-4 { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.grid-brands { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.product-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: box-shadow .2s, transform .2s; }
.product-card:hover { box-shadow: 0 10px 28px rgba(0, 0, 0, .09); transform: translateY(-2px); }
.pc-media { position: relative; aspect-ratio: 1 / 1; background: #f3f1ee; }
.pc-media img { width: 100%; height: 100%; object-fit: cover; }
.pc-flag { position: absolute; top: 10px; left: 10px; background: #fff; font-size: .7rem; padding: 3px 10px; border-radius: 3px; border: 1px solid var(--line); }
.pc-info { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; padding: 14px 16px 16px; }
.pc-brand { display: block; font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.pc-brand a { text-decoration: none; }
.pc-info h3 { font-size: .98rem; font-weight: 600; margin: 0 0 6px; letter-spacing: 0; }
.pc-info h3 a { text-decoration: none; }
.pc-info h3 a:hover { text-decoration: underline; }
.pc-price { margin: 0; font-weight: 600; font-size: .95rem; }
.wish { background: none; border: 0; padding: 4px; cursor: pointer; color: var(--ink); border-radius: 50%; flex: none; }
.wish .icon { width: 20px; height: 20px; }
.wish:hover { color: #b42318; }
.wish.on { color: #b42318; }
.wish.on .icon { fill: currentColor; }

/* ---------- Marcas / parceiros ---------- */
.brands-band { background: var(--soft); padding: 26px 0 30px; margin: 20px 0; }
.brands-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.brands-heading .eyebrow-dark { margin: 0; }
.brands-view-all { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; text-decoration: none; font-size: .73rem; font-weight: 650; letter-spacing: .045em; text-transform: uppercase; }
.brands-view-all:hover { text-decoration: underline; }
.brands-view-all .icon { width: 15px; height: 15px; }
.brands-row { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); align-items: center; gap: 14px; }
.brand-item { width: 100%; min-width: 0; height: 54px; padding: 4px; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; opacity: .86; transition: opacity .15s; }
.brand-item:hover { opacity: 1; }
.brand-item img { display: block; width: 100%; height: 40px; max-width: 100%; max-height: 40px; object-fit: contain; filter: grayscale(1); }
.brand-item .brand-word { display: block; max-width: 100%; overflow-wrap: anywhere; text-align: center; font-size: clamp(.52rem, .8vw, .82rem); letter-spacing: .025em; line-height: 1.2; }
.brand-word { font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: 1.15rem; color: var(--ink); }
.brands-next { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: var(--ink); text-decoration: none; }
.brands-next:hover { background: #fff; }
.brand-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 18px; display: flex; flex-direction: column; align-items: center; gap: 14px; text-decoration: none; background: #fff; transition: box-shadow .2s; }
.brand-card:hover { box-shadow: 0 10px 28px rgba(0, 0, 0, .09); }
.brand-card-mark { width: 100%; height: 70px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.brand-card-mark img { display: block; width: auto; height: auto; max-width: min(100%, 190px); max-height: 52px; object-fit: contain; }
.brand-group { margin-top: 36px; }
.brand-group:first-of-type { margin-top: 0; }
.brand-group-title { margin: 0 0 20px; padding: 0 0 12px; border-bottom: 1px solid var(--line); font-size: 1.2rem; font-weight: 600; }
.brand-card-mark .brand-word { max-width: 100%; text-align: center; font-size: 1rem; letter-spacing: .08em; }

/* ---------- Projetos ---------- */
.carousel-wrap { position: relative; }
.carousel { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; scroll-behavior: smooth; }
.carousel::-webkit-scrollbar { display: none; }
.project-tile { flex: 0 0 calc((100% - 48px) / 4); min-width: 230px; aspect-ratio: 5 / 6; scroll-snap-align: start; border-radius: var(--radius); overflow: hidden; background: #eee; }
.project-tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.project-tile:hover img { transform: scale(1.04); }
.car-btn { position: absolute; bottom: 16px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: #fff; box-shadow: 0 4px 14px rgba(0, 0, 0, .18); cursor: pointer; display: grid; place-items: center; color: var(--ink); }
.car-btn:hover { background: var(--soft); }
.car-next { right: 14px; } .car-prev { right: 66px; }
.project-card { margin: 0; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #fff; }
.project-card img { width: 100%; aspect-ratio: 5 / 6; object-fit: cover; }
.project-card figcaption { padding: 12px 14px 16px; display: flex; flex-direction: column; font-size: .9rem; }
.project-card figcaption span { color: var(--muted); font-size: .82rem; }
.cta-line { margin-top: 40px; color: var(--muted); }

/* ---------- Vantagens ---------- */
.benefits { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 20px; }
.benefits-inner { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; padding: 26px 0; }
.benefit { display: flex; align-items: center; gap: 14px; }
.benefit .icon { width: 34px; height: 34px; stroke-width: 1.2; }
.benefit strong { display: block; font-size: .92rem; }
.benefit span { display: block; font-size: .8rem; color: var(--muted); line-height: 1.4; }

/* ---------- Newsletter ---------- */
.newsletter { background: var(--soft); padding: 34px 0; }
.newsletter-inner { display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.newsletter strong { display: block; font-size: 1rem; }
.newsletter p { margin: 2px 0 0; color: var(--muted); font-size: .9rem; }
.newsletter-form { flex: 1 1 420px; max-width: 560px; }
.nl-row { display: flex; gap: 10px; }
.nl-row input { flex: 1; }
.nl-consent { display: flex; gap: 8px; align-items: flex-start; font-size: .75rem; color: var(--muted); margin-top: 8px; }
.nl-consent input { margin-top: 3px; }
.nl-msg { font-size: .85rem; margin: 8px 0 0; }
.nl-success { color: var(--ok) !important; } .nl-error { color: var(--out) !important; }

/* ---------- Rodapé ---------- */
.site-footer { background: var(--ink); color: #b9b4ad; font-size: .88rem; }
.site-footer a { color: #e8e4de; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 36px; padding: 48px 0 36px; }
.footer-grid h4 { color: #fff; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 14px; font-weight: 600; }
.footer-grid > div > a { display: block; padding: 3px 0; }
.footer-grid p { margin: 0 0 6px; }
.footer-brand .logo-word { color: #fff; display: inline-block; margin-bottom: 12px; }
.footer-social { display: flex; gap: 10px; margin-top: 14px; }
.footer-social a { width: 36px; height: 36px; border: 1px solid #4a4640; border-radius: 50%; display: grid; place-items: center; }
.footer-social a:hover { background: #fff; color: var(--ink); }
.footer-hours { margin-top: 12px !important; font-size: .82rem; line-height: 1.7; }
.footer-bottom { border-top: 1px solid #36322e; padding: 16px 0; font-size: .78rem; }
.footer-bottom-inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ---------- Catálogo / produto ---------- */
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.filters input[type="search"] { flex: 1 1 260px; }
.filters select { width: auto; min-width: 190px; }
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 34px; flex-wrap: wrap; }
.pagination a { padding: 7px 14px; border: 1px solid var(--line); border-radius: 3px; text-decoration: none; background: #fff; }
.pagination a.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.breadcrumb { color: var(--muted); font-size: .85rem; margin: 0 0 22px; }
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.product-photo { background: #f3f1ee; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.product-photo img { width: 100%; }
/* A galeria mantém sempre a mesma área, mesmo quando as imagens têm proporções diferentes. */
.product-gallery { position: relative; aspect-ratio: 1 / 1; touch-action: pan-y; background: transparent; border-color: transparent; }
.product-gallery [data-gallery-image] {
    display: block; width: 100%; height: 100%; object-fit: contain;
    opacity: 1; transform: translateX(0);
    transition: opacity .22s ease, transform .22s cubic-bezier(.22,.61,.36,1);
    will-change: opacity, transform;
}
.product-gallery-arrow {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 40px; height: 40px; border: 0; border-radius: 50%;
    background: rgba(255,255,255,.9); color: var(--ink);
    font-size: 30px; line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 1px 5px rgba(0,0,0,.15);
}
.product-gallery-prev { left: 12px; }
.product-gallery-next { right: 12px; }
.product-gallery-count {
    position: absolute; right: 12px; bottom: 12px;
    padding: 4px 9px; border-radius: 20px;
    background: rgba(0,0,0,.62); color: #fff; font-size: .78rem;
}
.price-lg { font-size: 1.8rem; font-weight: 600; margin: .3em 0; }
.description { margin: 20px 0; color: var(--ink-soft); }
.badge { display: inline-block; font-size: .74rem; font-weight: 600; padding: 3px 11px; border-radius: 999px; color: #fff; }
.badge-ok { background: var(--ok); } .badge-low { background: var(--low); } .badge-out { background: var(--out); }
.two-col { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: start; }
.prose p { color: var(--ink-soft); }
.info-box { background: var(--soft); border-radius: var(--radius); padding: 26px; }
.info-box h3 { margin-top: 1em; font-size: 1rem; } .info-box h3:first-child { margin-top: 0; }
.info-box p { margin: .3em 0; }
.empty { background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); padding: 44px; text-align: center; color: var(--muted); }

/* ---------- Formulários ---------- */
input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], input[type="search"], input[type="url"], select, textarea {
    width: 100%; padding: 11px 13px; border: 1px solid #d6d1ca; border-radius: 3px; font: inherit; background: #fff; color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
input[type="file"] { font: inherit; font-size: .85rem; max-width: 100%; }
.form label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 14px; }
.form label input, .form label select, .form label textarea { margin-top: 5px; font-weight: 400; }
.form-narrow { max-width: 660px; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.check { display: flex !important; align-items: center; gap: 8px; font-weight: 400 !important; }
.check input { width: auto; margin: 0 !important; }
.inline-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline-form input[type="search"], .inline-form input[type="text"] { width: auto; min-width: 240px; }
.qty { width: 84px !important; }
.actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.alert { padding: 12px 16px; border-radius: 4px; margin: 12px 0; border: 1px solid; font-size: .92rem; }
.alert-success { background: #e8f5ee; border-color: #a6d5bc; color: #1d5b3a; }
.alert-error { background: #fdeceb; border-color: #f0b4af; color: #8a1f17; }
.alert-info { background: #eef3f8; border-color: #b9cde2; color: #214a73; }
.fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px 6px; margin: 0 0 20px; }
.fieldset legend { font-weight: 600; padding: 0 8px; font-size: .9rem; }

/* ---------- Tabelas ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); margin-bottom: 18px; }
.table th, .table td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.table th { background: var(--soft); font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.table tfoot td { background: #faf8f5; }
.row-off { opacity: .55; }
.thumb { width: 54px; height: 54px; object-fit: cover; border-radius: 4px; }
.brand-cell { min-width: 150px; }
.brand-cell img { display: block; width: auto; height: auto; max-width: 132px; max-height: 34px; object-fit: contain; }
.brand-cell .brand-word { font-size: .85rem; }

/* ---------- Administração ---------- */
body.admin { background: #f2f0ec; }
.admin-bar { background: var(--ink); color: #fff; padding: 10px 0; font-size: .9rem; }
.admin-bar-inner { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.admin-bar a { color: #fff; margin-left: 16px; }
.admin-layout { display: grid; grid-template-columns: 210px 1fr; gap: 28px; padding: 28px 0 60px; align-items: start; }
.admin-nav { display: flex; flex-direction: column; gap: 2px; background: #fff; padding: 10px; border-radius: var(--radius); border: 1px solid var(--line); }
.admin-nav a { padding: 9px 12px; border-radius: 4px; text-decoration: none; font-size: .92rem; }
.admin-nav a:hover { background: var(--soft); }
.admin-nav a.active { background: var(--ink); color: #fff; }
.admin-content h1 { margin-top: 0; font-size: 1.7rem; }
.admin-content h2 { margin-top: 1.6em; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-bottom: 20px; }
.stat { background: #fff; padding: 16px; border-radius: var(--radius); border: 1px solid var(--line); display: flex; flex-direction: column; color: var(--muted); font-size: .85rem; }
.stat-n { font-size: 2rem; font-weight: 700; color: var(--ink); line-height: 1.1; }
.preview-box { display: flex; gap: 16px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.preview-box img { width: 160px; height: 120px; object-fit: cover; border-radius: 4px; border: 1px solid var(--line); }
.preview-box img.wide { width: 300px; height: 130px; }
.msg { background: #fff; border-radius: var(--radius); padding: 14px 18px; margin-bottom: 12px; border: 1px solid var(--line); border-left: 4px solid var(--line); }
.msg.unread { border-left-color: var(--ink); }
.msg header { display: flex; gap: 6px; flex-wrap: wrap; }
.msg header .right { margin-left: auto; }
body.login-page { display: grid; place-items: center; min-height: 100vh; background: var(--soft); padding: 20px; }
.login-box { background: #fff; padding: 36px; border-radius: 8px; width: min(400px, 100%); border: 1px solid var(--line); box-shadow: 0 10px 40px rgba(0, 0, 0, .08); }
.login-box .logo-word { display: block; margin-bottom: 4px; }

/* ---------- Responsivo ---------- */
@media (max-width: 1000px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .project-tile { flex-basis: calc((100% - 16px) / 2); }
    .topbar-center { display: none; }
}
@media (max-width: 820px) {
    .nav-toggle { display: flex; }
    .main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 8px 4%; gap: 0; }
    .main-nav.open { display: flex; }
    .main-nav a { padding: 13px 4px; border-bottom: 1px solid var(--line); border-radius: 0; }
    .main-nav .icon, .dropdown { display: none !important; }
    .header-inner { min-height: 64px; }
    .logo-word { font-size: 1.1rem; letter-spacing: .16em; }
    .site-logo { height: 38px; max-width: 165px; }
    .topbar-left { display: none; }
    .topbar-inner { justify-content: center; }
    .topbar-social { display: none; }
    .two-col, .product-detail, .row-2 { grid-template-columns: 1fr; }
    .admin-layout { grid-template-columns: 1fr; }
    .admin-nav { flex-direction: row; flex-wrap: wrap; }
    .hero::before { background: linear-gradient(0deg, rgba(20, 16, 12, .62), rgba(20, 16, 12, .25)); }
    .hero { align-items: flex-end; padding-bottom: 36px; }
    .cat-strip-inner { justify-content: flex-start; }
    .nl-row { flex-direction: column; }
    .section-head { flex-direction: column; align-items: flex-start; }
    .car-btn { display: none; }
}
@media (max-width: 560px) {
    .footer-grid { grid-template-columns: 1fr; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .pc-info { padding: 10px 10px 12px; }
    .project-tile { flex-basis: 70%; }
    .brands-row { gap: 14px; }
}


/* ---------- Contas de cliente / encomendas online ---------- */
.account-panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 24px; }
.account-panel h2, .account-panel h3 { margin-top: 0; }
.account-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.check label, label.check { display: flex; align-items: center; gap: 9px; font-weight: 400; }
label.check input[type=checkbox] { width: auto; margin: 0; }
.form input, .form select, .form textarea { max-width: 100%; }
.site-logo { image-rendering: auto; }
@media (max-width: 520px) { .account-panel { padding: 16px; } .site-logo { height: 34px; max-width: 145px; } }

/* ---------- Chat de apoio ao cliente ---------- */
.sani-chat-widget { position: fixed; right: 22px; bottom: 22px; z-index: 1200; font-size: 14px; line-height: 1.45; }
.sani-chat-launcher { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--ink); color: #fff; font: inherit; font-weight: 650; cursor: pointer; box-shadow: 0 8px 26px rgba(0,0,0,.18); transition: transform .18s ease, box-shadow .18s ease; }
.sani-chat-launcher:hover { transform: translateY(-2px); box-shadow: 0 11px 30px rgba(0,0,0,.23); }
.sani-chat-launcher-icon { display: grid; place-items: center; width: 26px; height: 26px; border: 1px solid rgba(255,255,255,.45); border-radius: 50%; font-size: 22px; line-height: 1; }
.sani-chat-launcher-dot { display: block; width: 8px; height: 8px; border-radius: 50%; background: #b8b5b0; }
.sani-chat-launcher-dot.is-online { background: #55c58a; }
.sani-chat-panel { position: absolute; right: 0; bottom: 66px; display: flex; flex-direction: column; width: min(370px, calc(100vw - 28px)); max-height: min(640px, calc(100vh - 110px)); overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 55px rgba(0,0,0,.22); animation: sani-chat-enter .18s ease-out; }
@keyframes sani-chat-enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.sani-chat-header { display: flex; align-items: center; gap: 11px; padding: 16px; background: var(--ink); color: #fff; }
.sani-chat-header-mark { display: grid; place-items: center; width: 38px; height: 38px; flex: none; border: 1px solid rgba(255,255,255,.5); border-radius: 50%; font-family: Georgia, serif; font-size: 21px; }
.sani-chat-header-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; gap: 3px; }
.sani-chat-header-copy strong { font-size: .98rem; }
.sani-chat-header-copy span { color: #d8d4ce; font-size: .75rem; }
.sani-chat-header-copy span.is-online { color: #9fe2b8; }
.sani-chat-close { flex: none; border: 0; background: transparent; color: #fff; font: inherit; font-size: 27px; cursor: pointer; width: 32px; height: 32px; line-height: 1; border-radius: 4px; }
.sani-chat-close:hover { background: rgba(255,255,255,.12); }
.sani-chat-body { display: flex; flex-direction: column; min-height: 0; padding: 16px; overflow-y: auto; }
.sani-chat-welcome { margin: 0 0 14px; }
.sani-chat-welcome strong { display: block; margin-bottom: 4px; font-size: 1rem; }
.sani-chat-welcome p { margin: 0; color: var(--muted); font-size: .82rem; }
.sani-chat-form { display: grid; gap: 11px; }
.sani-chat-form label { display: grid; gap: 5px; margin: 0; font-size: .79rem; font-weight: 600; }
.sani-chat-form input, .sani-chat-form textarea, .sani-chat-reply-form textarea { width: 100%; max-width: 100%; min-width: 0; padding: 10px 11px; border: 1px solid #dcd7d0; border-radius: 5px; background: #fff; color: var(--ink); font: inherit; font-weight: 400; outline: none; }
.sani-chat-form input:focus, .sani-chat-form textarea:focus, .sani-chat-reply-form textarea:focus { border-color: #8d877f; box-shadow: 0 0 0 3px rgba(28,28,28,.07); }
.sani-chat-form input[readonly] { background: #f7f6f4; color: #67625c; }
.sani-chat-form textarea, .sani-chat-reply-form textarea { resize: vertical; }
.sani-chat-optional { color: var(--muted); font-weight: 400; }
.sani-chat-privacy { margin: 9px 0 0; color: var(--muted); font-size: .7rem; line-height: 1.45; }
.sani-chat-submit { justify-content: center; width: 100%; padding: 11px 16px; font-size: .75rem; }
.sani-chat-error { margin: 0 0 12px; padding: 9px 10px; border-radius: 5px; border: 1px solid #f0b4af; background: #fdeceb; color: #8a1f17; font-size: .8rem; }
.sani-chat-messages { display: flex; flex-direction: column; gap: 10px; min-height: 160px; max-height: 340px; overflow-y: auto; padding: 3px 2px 12px; }
.sani-chat-message { max-width: 88%; padding: 10px 12px; border-radius: 10px; overflow-wrap: anywhere; }
.sani-chat-message.is-visitor { align-self: flex-end; background: #f0ede8; border-bottom-right-radius: 3px; }
.sani-chat-message.is-admin { align-self: flex-start; background: #f8f8f7; border: 1px solid var(--line); border-bottom-left-radius: 3px; }
.sani-chat-message-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.sani-chat-message-meta { margin-top: 5px; color: var(--muted); font-size: .66rem; }
.sani-chat-reply-form { display: grid; gap: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.sani-chat-compose-label { font-weight: 600; font-size: .78rem; }
.sani-chat-reply-form .btn { justify-self: end; width: auto; }
.sani-chat-reply-form .btn:disabled, .sani-chat-form .btn:disabled { opacity: .6; cursor: wait; }

/* ---------- Chat online na administração ---------- */
.chat-admin-heading { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; }
.chat-admin-heading h1 { margin-bottom: 6px; }
.chat-admin-heading p { margin: 0; }
.chat-admin-presence { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 5px; background: #eef7f0; color: #276341; font-size: .75rem; }
.chat-admin-presence span { width: 8px; height: 8px; border-radius: 50%; background: #39a66a; }
.chat-admin-error { margin-bottom: 14px; padding: 11px 13px; background: #fdeceb; color: #8a1f17; border: 1px solid #f0b4af; border-radius: 4px; }
.chat-admin-shell { display: grid; grid-template-columns: minmax(270px, 340px) minmax(0, 1fr); min-height: 560px; max-height: 760px; overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.chat-admin-sidebar { display: flex; flex-direction: column; min-width: 0; border-right: 1px solid var(--line); }
.chat-admin-sidebar-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 15px; border-bottom: 1px solid var(--line); }
.chat-admin-sidebar-head strong { font-size: .98rem; }
.chat-admin-list { flex: 1; overflow-y: auto; }
.chat-admin-empty { padding: 22px 16px; margin: 0; text-align: center; }
.chat-admin-conversation-item { display: block; width: 100%; padding: 13px 14px; border: 0; border-bottom: 1px solid #f0ede8; background: #fff; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.chat-admin-conversation-item:hover { background: #faf9f7; }
.chat-admin-conversation-item.is-active { background: var(--soft); box-shadow: inset 3px 0 0 var(--ink); }
.chat-admin-item-top, .chat-admin-item-bottom { display: flex; align-items: center; justify-content: space-between; gap: 9px; }
.chat-admin-item-top strong { font-size: .87rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-admin-item-top small { color: var(--muted); flex: none; font-size: .65rem; }
.chat-admin-item-email { display: block; margin-top: 3px; color: var(--muted); font-size: .74rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-admin-item-bottom { align-items: flex-start; margin-top: 7px; }
.chat-admin-item-preview { flex: 1; min-width: 0; color: #514d47; font-size: .76rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-admin-item-markers { display: flex; align-items: center; gap: 5px; flex: none; }
.chat-admin-unread { display: inline-grid; place-items: center; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 999px; background: var(--ink); color: #fff; font-size: .66rem; font-weight: 700; }
.chat-admin-status-pill { padding: 2px 5px; border-radius: 3px; background: #eee; color: #666; font-size: .62rem; }
.chat-admin-status-pill.is-closed { background: #f4e8e4; color: #7a382c; }
.chat-admin-main { display: flex; min-width: 0; min-height: 0; flex-direction: column; }
.chat-admin-no-selection { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: center; padding: 30px; text-align: center; }
.chat-admin-empty-icon { display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 16px; border-radius: 50%; background: var(--soft); color: var(--ink); font-size: 25px; }
.chat-admin-no-selection h2 { font-size: 1.2rem; }
.chat-admin-no-selection p { max-width: 350px; margin: 0; }
.chat-admin-active { display: flex; min-height: 0; flex: 1; flex-direction: column; }
.chat-admin-conv-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 18px; border-bottom: 1px solid var(--line); }
.chat-admin-conv-head h2 { margin: 0 0 3px; font-size: 1rem; }
.chat-admin-conv-head p { margin: 0; color: var(--muted); font-size: .77rem; overflow-wrap: anywhere; }
.chat-admin-messages { display: flex; flex: 1; min-height: 220px; flex-direction: column; gap: 14px; padding: 18px; overflow-y: auto; background: #fbfaf8; }
.chat-admin-message { max-width: min(82%, 620px); }
.chat-admin-message.from-admin { align-self: flex-end; }
.chat-admin-message.from-visitor { align-self: flex-start; }
.chat-admin-message-meta { margin: 0 2px 5px; color: var(--muted); font-size: .68rem; }
.chat-admin-message.from-admin .chat-admin-message-meta { text-align: right; }
.chat-admin-message-body { padding: 11px 13px; border: 1px solid var(--line); border-radius: 9px; background: #fff; overflow-wrap: anywhere; white-space: pre-wrap; }
.chat-admin-message.from-admin .chat-admin-message-body { border-color: #ded8cf; background: #eee9e1; border-bottom-right-radius: 3px; }
.chat-admin-message.from-visitor .chat-admin-message-body { border-bottom-left-radius: 3px; }
.chat-admin-reply { display: flex; align-items: flex-end; gap: 10px; padding: 13px 16px 8px; background: #fff; border-top: 1px solid var(--line); }
.chat-admin-reply textarea { flex: 1; min-width: 0; resize: vertical; padding: 10px 12px; border: 1px solid #dcd7d0; border-radius: 5px; font: inherit; }
.chat-admin-reply textarea:focus { outline: 2px solid rgba(28,28,28,.12); border-color: #8d877f; }
.chat-admin-note { margin: 0; padding: 0 16px 13px; background: #fff; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 900px) {
    .chat-admin-shell { grid-template-columns: minmax(220px, 290px) minmax(0, 1fr); }
    .chat-admin-heading { display: block; }
    .chat-admin-presence { margin-top: 10px; }
}
@media (max-width: 640px) {
    .sani-chat-widget { right: 12px; bottom: 12px; }
    .sani-chat-launcher { min-height: 48px; padding: 0 15px; }
    .sani-chat-panel { right: -2px; bottom: 60px; width: min(370px, calc(100vw - 24px)); max-height: calc(100vh - 90px); }
    .chat-admin-shell { display: flex; min-height: 640px; max-height: none; flex-direction: column; }
    .chat-admin-sidebar { max-height: 260px; border-right: 0; border-bottom: 1px solid var(--line); }
    .chat-admin-list { max-height: 205px; }
    .chat-admin-main { min-height: 360px; flex: 1; }
    .chat-admin-messages { min-height: 210px; }
    .chat-admin-conv-head { align-items: flex-start; }
    .chat-admin-conv-head .btn { flex: none; }
    .chat-admin-reply { align-items: stretch; flex-direction: column; }
    .chat-admin-reply .btn { align-self: flex-end; }
    .chat-admin-message { max-width: 94%; }
}
@media (prefers-reduced-motion: reduce) {
    .sani-chat-panel, .sani-chat-launcher { animation: none; transition: none; }
}

@media (max-width: 720px) {
    .brand-item { width: 125px; flex-basis: 125px; }
    .brand-item img { max-width: 120px; max-height: 36px; }
    .brand-card-mark { height: 64px; }
    .brand-card-mark img { max-height: 44px; }
}


/* A faixa de parceiros mantém uma única linha; em ecrãs mais estreitos permite deslizar horizontalmente. */
@media (max-width: 1000px) {
    .brands-row { display: flex; flex-wrap: nowrap; gap: 18px; overflow-x: auto; padding: 2px 0 8px; scrollbar-width: thin; }
    .brand-item { width: 100px; flex: 0 0 100px; height: 54px; }
    .brand-item img { width: 100%; max-width: 100%; height: 40px; max-height: 40px; }
}
@media (max-width: 560px) {
    .brands-heading { align-items: flex-start; gap: 12px; }
    .brands-view-all { font-size: .65rem; }
    .brands-row { gap: 14px; }
    .brand-item { width: 88px; flex-basis: 88px; }
    .brand-item img { height: 36px; max-height: 36px; }
}
