/* AIJ Store - vitrine de afiliados. Visual alinhado à página principal da AIJ Sistem. */

:root {
  --navy-900: #111111;
  --navy-800: #1c1c1c;
  --primary: #D71920;
  --primary-dark: #B71920;
  --primary-light: #FFF0F1;
  --text: #1F2937;
  --muted: #5D6878;
  --border: #E1E7EF;
  --bg-soft: #F5F8FC;
  --white: #fff;
  --whatsapp: #25D366;
  --shadow: 0 16px 45px rgba(0, 0, 0, .09);
  --radius: 16px;
  --header-height: 82px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-height) + 16px); }
body { margin: 0; color: var(--text); background: var(--bg-soft); font-family: Inter, Arial, Helvetica, sans-serif; font-size: 16px; line-height: 1.6; }
h1, h2, h3, h4 { margin: 0 0 .6em; color: var(--navy-900); font-family: Sora, Inter, Arial, sans-serif; line-height: 1.2; }
p { margin: 0 0 1rem; }
a { color: inherit; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Botões */
.btn, .btn-red, .btn-ghost, .button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 12px 20px; border: 1px solid transparent; border-radius: 12px; font-size: .95rem; font-weight: 700; line-height: 1.2; text-decoration: none; transition: transform .2s, box-shadow .2s, background .2s; }
.btn:hover, .btn-red:hover, .button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px #11111122; }
.btn-red, .button-primary { background: var(--primary); color: #fff; }
.btn-red:hover, .button-primary:hover { background: var(--primary-dark); }
.button-outline { border-color: #cbd6e6; background: #fff; color: var(--navy-900); }
.button-whatsapp { background: #fff; color: #11653a; }
.btn-ghost { background: transparent; border: 1px solid var(--navy-900); color: var(--navy-900); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

/* Barra superior */
.topbar { height: 36px; background: var(--navy-900); color: #dce6f4; font-size: .76rem; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; width: min(1180px, calc(100% - 40px)); height: 100%; margin: 0 auto; }
.top-contact { display: flex; align-items: center; gap: 24px; }
.top-contact a { color: #dce6f4; text-decoration: none; }
.top-contact a:hover { color: #fff; }
.top-links { display: flex; align-items: center; gap: 18px; }
.top-links a { color: #dce6f4; text-decoration: none; }
.top-links a:hover { color: #fff; }

/* Cabeçalho */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .96); border-bottom: 1px solid transparent; box-shadow: 0 7px 24px #11111114; }
.header-top { display: flex; align-items: center; gap: 20px; min-height: var(--header-height); max-width: 1180px; margin: 0 auto; padding: 12px 20px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--navy-900); text-decoration: none; min-width: 170px; }
.brand-logo { width: 78px; height: auto; border-radius: 5px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: Sora, Inter, sans-serif; font-size: 1.35rem; font-weight: 700; letter-spacing: -.03em; }
.brand-name span { color: var(--primary); }
.brand-sub { margin-top: 4px; color: var(--muted); font-size: .6rem; letter-spacing: .04em; }
.search { flex: 1; display: flex; min-width: 240px; max-width: 760px; }
.search input { flex: 1; height: 46px; border: 1px solid var(--border); border-right: 0; border-radius: 12px 0 0 12px; padding: 0 16px; font-size: 15px; background: #f6f8fb; }
.search button { width: 56px; height: 46px; border: 0; border-radius: 0 12px 12px 0; background: var(--primary); color: #fff; font-size: 18px; }
.search button:hover { background: var(--primary-dark); }
.header-links { display: flex; gap: 22px; flex-wrap: wrap; }
.header-links a { color: #344054; font-size: .9rem; font-weight: 600; text-decoration: none; }
.header-links a:hover { color: var(--primary); }
.nav-cats { background: var(--navy-900); }
.nav-cats ul { display: flex; gap: 22px; list-style: none; max-width: 1180px; margin: 0 auto; padding: 12px 20px; overflow-x: auto; white-space: nowrap; }
.nav-cats a { color: #e9eef5; font-size: .88rem; text-decoration: none; }
.nav-cats a:hover { color: var(--primary); }

@media (min-width: 1101px) { .nav-cats ul { justify-content: center; } }

/* Destaque (mesma composição da página principal: texto à esquerda, imagem à direita) */
.hero { position: relative; overflow: hidden; color: #e6edf8; background: linear-gradient(120deg, #111111 0%, #211012 62%, #111111 100%); padding: 72px 40px 96px; }
.hero::before { content: ""; position: absolute; right: -180px; top: -280px; width: 600px; height: 600px; border: 1px solid #ffffff0d; border-radius: 50%; box-shadow: 0 0 0 65px #ffffff05, 0 0 0 140px #ffffff03; pointer-events: none; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.03fr .97fr; align-items: center; gap: 42px; max-width: 1180px; margin: 0 auto; }
.eyebrow { margin: 0 0 15px; color: #FFE2E2; font-size: .75rem; font-weight: 700; letter-spacing: .14em; line-height: 1.4; }
.hero h1 { max-width: 650px; color: #fff; font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -.035em; }
.hero-lead { max-width: 640px; margin: 0 0 26px; color: #cfdbeb; font-size: 1.03rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-visual { position: relative; display: grid; place-items: center; }
.hero-logo { width: min(100%, 440px); height: auto; border-radius: 18px; box-shadow: 0 28px 80px #0007; border: 1px solid #ffffff22; }
.trust-points { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 24px; color: #d4dfef; font-size: .8rem; }

/* Layout principal da vitrine */
.layout { display: grid; grid-template-columns: 260px 1fr; gap: 28px; max-width: 1180px; margin: 0 auto; padding: 36px 40px 56px; align-items: start; }
.section-title { font-size: 1.7rem; color: var(--navy-900); margin: 0 0 6px; }
.section-sub { color: var(--muted); margin: 0 0 18px; font-size: .9rem; }

/* Filtros */
.filters { position: sticky; top: 190px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.filters h2 { font-size: 1.15rem; margin: 0 0 12px; }
.filters label { display: block; margin: 16px 0 6px; font-size: .85rem; font-weight: 700; }
.filters select, .filters input[type="number"] { width: 100%; height: 42px; border: 1px solid #cfd6e2; border-radius: 10px; padding: 0 10px; font-size: .95rem; background: #fff; }
.price-row { display: flex; gap: 8px; }
.filters .btn-ghost { width: 100%; margin-top: 16px; }
.toggle-favs { width: 100%; margin-top: 18px; min-height: 46px; border: 0; border-radius: 12px; background: var(--navy-900); color: #fff; font-weight: 700; }
.toggle-favs[aria-pressed="true"] { background: var(--primary); }

/* Barra de resultados */
.results-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.result-count { font-weight: 700; color: var(--navy-900); }
.status { min-height: 24px; color: var(--muted); }

/* Cards de produto: moldura fixa, imagem inteira e centralizada */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; list-style: none; margin: 0; padding: 0; }
.card { position: relative; display: flex; flex-direction: column; overflow: hidden; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 2px 10px rgba(0, 0, 0, .05); transition: transform .2s, box-shadow .2s; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card-img { position: relative; width: 100%; aspect-ratio: 1 / 1; overflow: hidden; background: #fff; border-bottom: 1px solid var(--border); }
.card-img img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: contain; object-position: center; padding: 16px; }
.card-noimg { display: flex; align-items: center; justify-content: center; height: 100%; padding: 20px; color: #999; font-size: 14px; text-align: center; }
.card-body { display: flex; flex: 1; flex-direction: column; gap: 6px; padding: 16px; }
.card-cat { margin: 0; color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.card-title { min-height: 2.6em; margin: 0; color: var(--navy-900); font-family: Inter, Arial, sans-serif; font-size: 15px; font-weight: 600; line-height: 1.35; }
.card-rating { margin: 0; color: var(--text); font-size: 13px; }
.card-price { margin: 4px 0 0; color: var(--navy-900); font-size: 24px; font-weight: 800; }
.card-note { margin: 0; color: var(--muted); font-size: 12px; }
.card .btn-red { margin-top: auto; padding: 12px; font-size: 15px; }
.share { margin-top: 2px; color: var(--navy-900); font-size: 13px; text-align: center; text-decoration: underline; text-underline-offset: 3px; }
.fav { position: absolute; top: 10px; right: 10px; z-index: 2; width: 36px; height: 36px; border: 1px solid var(--border); border-radius: 50%; background: #fff; color: #999; font-size: 18px; }
.fav.on { color: var(--primary); border-color: var(--primary); }

.back-to-top { position: fixed; right: 24px; bottom: 24px; z-index: 30; width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--primary); color: #fff; font-size: 22px; box-shadow: var(--shadow); }
.back-to-top[hidden] { display: none; }

/* Faixa de credibilidade */
.trust { background: #fff; border-top: 1px solid var(--border); padding: 36px 40px; }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; max-width: 1180px; margin: 0 auto; }
.trust h3 { margin: 0 0 6px; font-size: 1.05rem; }
.trust h3::before { content: ""; display: block; width: 40px; height: 3px; margin-bottom: 10px; background: var(--primary); }
.trust p { margin: 0; color: var(--text); font-size: .92rem; }

/* Rodapé */
.site-footer { padding: 56px 40px 24px; background: #080808; color: #c1cbd9; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; max-width: 1180px; margin: 0 auto; }
.site-footer h4 { margin: 0 0 12px; color: #fff; font-size: 1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #c9d5e5; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer p { color: #b5c1d0; font-size: .85rem; }
.footer-brand .brand-logo { width: 82px; }
.footer-brand .brand-name { color: #fff; }
.footer-store { color: #ff5c64 !important; font-weight: 700; }
.disclosure { max-width: 1180px; margin: 28px auto 0; padding-top: 18px; border-top: 1px solid #303030; color: #aaa; font-size: 13px; }

/* Páginas institucionais */
.page { max-width: 860px; margin: 48px auto; padding: 0 24px; color: var(--text); line-height: 1.65; }
.page h1 { margin: 0 0 8px; font-size: 2.1rem; color: var(--navy-900); }
.page h1::after { content: ""; display: block; width: 60px; height: 4px; margin-top: 10px; background: var(--primary); }
.page h2 { margin: 32px 0 8px; font-size: 1.3rem; color: var(--navy-900); }
.page p, .page li { font-size: 16px; }
.page ul { padding-left: 22px; }
.page a { color: var(--primary); }
.page .draft { padding: 12px 16px; border-left: 4px solid var(--primary); border-radius: 6px; background: var(--primary-light); font-size: 14px; }
.page .placeholder { padding: 0 4px; border-radius: 3px; background: #fff7cc; }

/* Responsivo */
@media (max-width: 1050px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; padding: 24px 20px 40px; }
  .filters { position: static; }
  .hero { padding: 48px 20px 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .topbar { display: none; }
  .header-top { padding: 12px 20px; }
  .header-links { display: none; }
  .nav-cats ul { padding: 12px 20px; }
  .site-header { --header-height: auto; }
}
@media (max-width: 560px) {
  .hero h1 { font-size: 2rem; }
  .hero-actions { display: grid; grid-template-columns: 1fr; }
  .hero-actions .button { width: 100%; }
  .brand { min-width: 0; }
  .brand-logo { width: 62px; }
  .search { min-width: 0; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-title { font-size: 14px; }
  .card-price { font-size: 20px; }
  .trust { padding: 28px 20px; }
  .trust-grid { grid-template-columns: 1fr; gap: 18px; }
  .footer-grid { grid-template-columns: 1fr; }
  .site-footer { padding: 40px 20px 24px; }
  .page h1 { font-size: 1.7rem; }
}
