/* Apexis Products hub: scoped to .apx-products, inside the theme's header
   and footer. Each brand card carries its own page's dark ground and accent. */

/* Let the page run full width inside Astra's container. */
body.apx-products-page .site-content > .ast-container { max-width: 100%; padding: 0; display: block; }
body.apx-products-page #primary, body.apx-products-page .site-main { margin: 0; padding: 0; width: 100%; }

.apx-products {
  --ink: #23272e;
  --accent: #cf2d22;
  --line: rgba(20, 24, 30, .12);
  --ease: cubic-bezier(.22, .61, .36, 1);
  width: 100%; max-width: 1180px; margin: 0 auto;
  padding: clamp(40px, 7vw, 88px) 24px clamp(56px, 8vw, 104px);
  color: var(--ink);
}
.apx-products *, .apx-products *::before, .apx-products *::after { box-sizing: border-box; }
.apx-products a { text-decoration: none; }
.apx-products h1, .apx-products h2, .apx-products h3 {
  font-family: 'Archivo Narrow', sans-serif; font-weight: 900; text-transform: uppercase; margin: 0;
}

.apx-products .intro { text-align: center; max-width: 820px; margin: 0 auto; }
.apx-products h1 {
  color: var(--ink); line-height: .92; letter-spacing: -.01em;
  font-size: clamp(2.5rem, 7vw, 5.4rem); text-wrap: balance;
}
.apx-products .rule { width: 68px; height: 3px; background: var(--accent); border-radius: 3px; margin: clamp(20px, 2.6vw, 28px) auto 0; }

/* quick menu: jumps to each card on the page */
html:has(body.apx-products-page) { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html:has(body.apx-products-page) { scroll-behavior: auto; } }
.apx-products .quick { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 10px; margin-top: clamp(20px, 3vw, 28px); }
.apx-products .quick a {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px;
  border: 1px solid var(--line); background: #fff; color: var(--ink);
  font-family: 'Archivo Narrow', sans-serif; font-weight: 700; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase;
  transition: border-color .2s, color .2s;
}
.apx-products .quick a::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--b-accent, var(--accent)); }
.apx-products .quick a:hover { border-color: var(--accent); color: var(--accent); }
.apx-products .quick a:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.apx-products .card, .apx-products .help { scroll-margin-top: 24px; }

/* brand cards */
.apx-products .grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2vw, 26px); margin-top: clamp(36px, 6vw, 64px); }
@media (max-width: 760px) { .apx-products .grid { grid-template-columns: 1fr; } }
.apx-products .card {
  position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: 24px; color: #fff;
  background: var(--b-bg); box-shadow: 0 18px 40px -26px rgba(15, 18, 24, .55);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.apx-products .card:hover { transform: translateY(-4px); box-shadow: 0 30px 60px -28px rgba(15, 18, 24, .6); color: #fff; }
.apx-products .card:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.apx-products .stage {
  position: relative; aspect-ratio: 16 / 10; overflow: hidden;
  background: radial-gradient(60% 70% at 50% 60%, color-mix(in srgb, var(--b-accent) 38%, transparent), transparent 70%);
}
.apx-products .stage img {
  position: absolute; left: 10%; top: 9%; width: 80%; height: 82%; max-width: none; object-fit: contain;
  filter: drop-shadow(0 20px 30px rgba(0, 0, 0, .45)); transition: transform .5s var(--ease);
}
.apx-products .stage img.wide { left: 6%; width: 88%; }
.apx-products .card:hover .stage img { transform: scale(1.04); }
.apx-products .body { display: flex; flex-direction: column; gap: 8px; padding: 0 clamp(20px, 2.4vw, 28px) clamp(20px, 2.4vw, 28px); flex: 1; }
.apx-products .brand {
  display: flex; align-items: center; gap: 10px; font-family: 'Archivo Narrow', sans-serif; font-weight: 800;
  font-size: 1.05rem; letter-spacing: .18em; text-transform: uppercase;
}
.apx-products .brand::before { content: ""; width: 22px; height: 3px; border-radius: 3px; background: var(--b-accent); }
.apx-products .kind { font-size: .8rem; letter-spacing: .06em; color: rgba(255, 255, 255, .65); }
.apx-products .card h2 { color: #fff; line-height: .98; font-size: clamp(1.6rem, 2.6vw, 2.2rem); margin-top: 3px; }
.apx-products .go {
  margin-top: auto; padding-top: 14px; display: inline-flex; align-items: center; gap: 8px;
  font-family: 'Archivo Narrow', sans-serif; font-weight: 800; font-size: .9rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--b-accent);
}
.apx-products .go span { transition: transform .25s var(--ease); }
.apx-products .card:hover .go span { transform: translateX(4px); }

/* help band */
.apx-products .help {
  margin-top: clamp(36px, 6vw, 64px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 22px;
  padding: clamp(22px, 3vw, 34px); border-radius: 24px; background: #f0f5fa; border: 1px solid var(--line);
}
.apx-products .help h3 { color: var(--ink); font-size: clamp(1.4rem, 2.4vw, 1.9rem); line-height: 1; }
.apx-products .actions { display: flex; flex-wrap: wrap; gap: 10px; }
.apx-products .btn {
  display: inline-flex; align-items: center; gap: 8px; font-family: 'Archivo Narrow', sans-serif; font-weight: 800;
  font-size: .95rem; letter-spacing: .1em; text-transform: uppercase; padding: 16px 26px; border-radius: 12px;
  white-space: nowrap; color: #fff; transition: transform .2s var(--ease), box-shadow .2s, filter .2s;
}
.apx-products .btn:hover { color: #fff; transform: translateY(-2px); filter: brightness(1.07); }
.apx-products .btn-primary { background: var(--accent); }
.apx-products .btn-primary:hover { box-shadow: 0 12px 30px rgba(207, 45, 34, .35); }
.apx-products .btn-wa { background: #1f9d55; }

@media (prefers-reduced-motion: reduce) {
  .apx-products .card, .apx-products .stage img, .apx-products .go span, .apx-products .btn { transition: none; }
}
