/* ==========================================================================
   Vanguard-Lock · sitio público
   ========================================================================== */

:root {
  --brand: #0b9444;          /* verde del logo */
  --brand-strong: #07743a;   /* botones y texto verde sobre blanco (AA) */
  --brand-deep: #055a2d;
  --brand-soft: #e7f4ec;
  --brand-glow: rgba(11, 148, 68, .35);

  --ink: #131a16;
  --ink-2: #39443e;
  --muted: #5f6a64;
  --line: #e1e6e3;
  --line-strong: #cdd5d0;
  --bg: #ffffff;
  --bg-alt: #f4f7f5;
  --dark: #0d1310;
  --dark-2: #151d19;
  --wa: #1fa855;
  --wa-strong: #128c46;
  --danger: #b42318;
  --danger-soft: #fdecea;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 20, .06), 0 1px 3px rgba(16, 24, 20, .06);
  --shadow: 0 10px 30px -12px rgba(16, 24, 20, .22);
  --container: 1240px;
  --gutter: clamp(16px, 4vw, 32px);

  --font: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-head: "Barlow Semi Condensed", "Barlow", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-strong); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-deep); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1em; }

.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; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip:focus { left: 8px; }
.icon { width: 1.15em; height: 1.15em; flex-shrink: 0; vertical-align: -.2em; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }
.center { text-align: center; justify-content: center; }

/* Tipografía ------------------------------------------------------------- */
.h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.1rem); font-weight: 700; }
.h2 { font-size: clamp(1.65rem, 1.25rem + 1.6vw, 2.35rem); font-weight: 700; }
.h3 { font-size: 1.4rem; font-weight: 700; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .6em;
  font-family: var(--font-head); font-weight: 600; font-size: .85rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--brand-strong); margin-bottom: .75rem;
}
.eyebrow::before { content: ""; width: 26px; height: 2px; background: currentColor; }
.eyebrow-light { color: #7fdca5; }
.prose p:last-child { margin-bottom: 0; }
.code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .82rem; color: var(--muted); letter-spacing: .02em; }

/* Botones ---------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  padding: .72em 1.25em; border-radius: 999px; border: 2px solid transparent;
  font-family: var(--font-head); font-weight: 600; font-size: 1.02rem; letter-spacing: .02em;
  text-decoration: none; cursor: pointer; line-height: 1.2; white-space: nowrap;
  transition: background-color .18s, color .18s, border-color .18s, transform .18s, box-shadow .18s;
}
.btn:hover { transform: translateY(-1px); }
.btn > .icon:last-child:not(:first-child) { transition: transform .2s; }
.btn:hover > .icon:last-child:not(:first-child) { transform: translateX(3px); }
.btn:active { transform: none; }
.btn-sm { padding: .5em .95em; font-size: .92rem; }
.btn-lg { padding: .85em 1.5em; font-size: 1.08rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--brand-strong); color: #fff; box-shadow: 0 8px 20px -10px var(--brand-glow); }
.btn-primary:hover { background: var(--brand-deep); color: #fff; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #000; color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn-outline-light:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .06); }
.btn-wa { background: var(--wa-strong); color: #fff; }
.btn-wa:hover { background: #0d7a3c; color: #fff; }
.actions-row { display: flex; flex-wrap: wrap; gap: 12px; }
.link-arrow { display: inline-flex; align-items: center; gap: .4em; font-family: var(--font-head); font-weight: 600; text-decoration: none; }
.link-arrow .icon { transition: transform .18s; }
.link-arrow:hover .icon { transform: translateX(3px); }

/* Header ----------------------------------------------------------------- */
.topbar { background: var(--dark); color: #b9c4be; font-size: .85rem; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 36px; }
.topbar span, .topbar a { display: inline-flex; align-items: center; gap: .45em; }
.topbar a { color: #dfe7e2; text-decoration: none; }
.topbar a:hover { color: #fff; }
.topbar-links { display: flex; gap: 22px; }

.site-header { position: sticky; top: -36px; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); transition: box-shadow .3s; }
.site-header.is-scrolled { box-shadow: 0 8px 24px -16px rgba(16, 24, 20, .35); }
.header-inner { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.brand img { width: 196px; height: auto; }
.nav { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.nav ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
.nav ul a {
  display: block; padding: .5em .85em; border-radius: 8px; text-decoration: none;
  font-family: var(--font-head); font-weight: 600; font-size: 1.05rem; color: var(--ink); letter-spacing: .02em;
  position: relative;
}
.nav ul a:hover { color: var(--brand-strong); }
.nav ul a[aria-current="page"] { color: var(--brand-strong); }
.nav ul a[aria-current="page"]::after { content: ""; position: absolute; left: .85em; right: .85em; bottom: .1em; height: 2px; background: var(--brand); border-radius: 2px; }
.nav-search { position: relative; }
.nav-search input {
  width: 230px; padding: .55em 2.6em .55em 1em; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--bg-alt); font-size: .93rem;
  transition: border-color .18s, background .18s, width .2s;
}
.nav-search input:focus { outline: none; border-color: var(--brand); background: #fff; }
.nav-search button { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); border: 0; background: none; padding: 8px; color: var(--muted); cursor: pointer; display: grid; }
.nav-toggle { display: none; margin-left: auto; border: 1px solid var(--line-strong); background: #fff; border-radius: 10px; padding: 9px; cursor: pointer; color: var(--ink); }
.nav-toggle .icon { width: 24px; height: 24px; }
.nav-toggle .icon-close { display: none; }

/* Hero ------------------------------------------------------------------- */
.hero {
  position: relative; overflow: hidden; color: #d7e0db;
  background:
    radial-gradient(900px 500px at 85% 40%, rgba(11, 148, 68, .28), transparent 60%),
    radial-gradient(600px 400px at 0% 100%, rgba(11, 148, 68, .12), transparent 70%),
    linear-gradient(160deg, var(--dark-2), var(--dark));
  isolation: isolate;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .35;
  background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(circle at 70% 40%, #000 0, transparent 70%);
}
/* Logo animado: el anillo se dibuja, la llave entra desde abajo y cada tanto gira
   como en una cerradura, con un pulso al "abrir". Piezas: assets/img/logo-*.webp */
@property --he-draw { syntax: "<angle>"; inherits: false; initial-value: 372deg; }
.hero-emblem {
  position: absolute; right: max(-120px, calc(50% - 760px)); top: 50%; width: min(620px, 60vw); aspect-ratio: 1;
  transform: translateY(-50%) rotate(-8deg); opacity: .6; z-index: -1; pointer-events: none;
  translate: calc(var(--mx, 0) * 16px) calc(var(--my, 0) * 16px); transition: translate .9s cubic-bezier(.2, .7, .2, 1);
}
.he-float, .he-keyclip, .he-key, .he-key-turn { position: absolute; inset: 0; }
.he-float::before { content: ""; position: absolute; inset: -14%; border-radius: 50%; background: radial-gradient(closest-side, rgba(11, 148, 68, .4), transparent 72%); }
.he-ring, .he-key-turn img { position: absolute; inset: 0; width: 100%; height: 100%; }
.he-keyclip { clip-path: ellipse(38.4% 39.4% at 50.2% 49.6%); }   /* interior del anillo: la llave "entra" por abajo */
.he-key-turn { transform-origin: 50.2% 50%; }
.he-shine { position: absolute; inset: 0; overflow: hidden; -webkit-mask: url(../img/logo-llave.webp) center / 100% 100% no-repeat; mask: url(../img/logo-llave.webp) center / 100% 100% no-repeat; }
.he-shine::before { content: ""; position: absolute; top: 0; bottom: 0; left: 30%; width: 12%; background: linear-gradient(100deg, transparent 10%, rgba(255, 255, 255, .7) 50%, transparent 90%); transform: translateX(-100%); }
.he-pulse { position: absolute; inset: 1% 1.8% 1% 2%; border-radius: 50%; border: 3px solid var(--brand); opacity: 0; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.hero-has-img::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(10,15,12,.92) 0%, rgba(10,15,12,.7) 45%, rgba(10,15,12,.25) 100%); }
.hero-inner { padding-top: clamp(64px, 10vw, 128px); padding-bottom: clamp(64px, 10vw, 120px); max-width: var(--container); }
.hero-title { color: #fff; font-size: clamp(2.4rem, 1.5rem + 4vw, 4.4rem); font-weight: 700; max-width: 15ch; letter-spacing: -.02em; line-height: 1.02; }
.hero-lead { font-size: clamp(1.05rem, 1rem + .4vw, 1.25rem); max-width: 54ch; margin-bottom: 2rem; color: #c3cec8; }
.hero-search {
  margin-top: 2.25rem; display: flex; align-items: center; gap: 10px; max-width: 620px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); border-radius: 999px; padding: 6px 6px 6px 20px;
  backdrop-filter: blur(6px);
}
.hero-search > .icon { color: #9fb0a7; }
.hero-search input { flex: 1; min-width: 0; border: 0; background: transparent; color: #fff; padding: .6em 0; outline: none; }
.hero-search input::placeholder { color: #9fb0a7; }
.hero-search:focus-within { border-color: var(--brand); background: rgba(255,255,255,.12); }

/* Pilares ---------------------------------------------------------------- */
.values { background: #fff; border-bottom: 1px solid var(--line); }
.values-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.value { display: flex; gap: 16px; padding: 30px 22px; border-right: 1px solid var(--line); }
.value:first-child { padding-left: 0; }
.value:last-child { border-right: 0; padding-right: 0; }
.value-icon { width: 48px; height: 48px; border-radius: 12px; background: var(--brand-soft); color: var(--brand-strong); display: grid; place-items: center; flex-shrink: 0; }
.value-icon .icon { width: 24px; height: 24px; }
.value-title { font-size: 1.12rem; margin-bottom: .25em; }
.value p { font-size: .95rem; color: var(--muted); margin: 0; line-height: 1.5; }

/* Secciones -------------------------------------------------------------- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-tight { padding: clamp(28px, 4vw, 44px) 0 clamp(56px, 7vw, 88px); }
.section-alt { background: var(--bg-alt); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 32px; flex-wrap: wrap; }
.section-head .h2 { margin: 0; }

.page-hero { background: var(--bg-alt); border-bottom: 1px solid var(--line); padding: clamp(28px, 4vw, 44px) 0 clamp(36px, 5vw, 56px); position: relative; overflow: hidden; }
.page-hero::after { content: ""; position: absolute; right: -70px; top: -110px; width: 380px; height: 380px; background: url(../img/logo-completo.webp) center / contain no-repeat; opacity: .08; transform: rotate(-12deg); }
.page-hero-sm { padding-bottom: clamp(28px, 4vw, 40px); }
.page-hero .h1 { margin-bottom: .25em; }
.page-hero .lead { margin: 0; }

.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: .9rem; color: var(--muted); margin-bottom: 18px; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--brand-strong); text-decoration: underline; }
.breadcrumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* Categorías ------------------------------------------------------------- */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 14px;
  min-height: 190px; padding: 22px; border-radius: var(--radius); text-decoration: none; overflow: hidden;
  background: var(--bg-alt); border: 1px solid var(--line); color: var(--ink);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--brand); color: var(--ink); }
.cat-card-icon { position: absolute; top: 20px; left: 22px; width: 48px; height: 48px; border-radius: 50%; background: #fff; color: var(--brand); display: grid; place-items: center; box-shadow: var(--shadow-sm); }
.cat-card-icon .icon { width: 26px; height: 26px; }
.cat-card.has-img { color: #fff; border-color: transparent; min-height: 230px; }
.cat-card.has-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.cat-card.has-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(8, 12, 10, .82)); }
.cat-card.has-img:hover img { transform: scale(1.05); }
.cat-card.has-img:hover { color: #fff; }
.cat-card-body { position: relative; z-index: 1; display: flex; flex-direction: column; }
.cat-card-name { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; line-height: 1.15; }
.cat-card-count { font-size: .88rem; opacity: .75; }
.cat-card-arrow { position: absolute; z-index: 1; right: 20px; bottom: 22px; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-strong); color: #fff; transform: translateX(-6px); opacity: 0; transition: .2s; }
.cat-card:hover .cat-card-arrow { opacity: 1; transform: none; }

/* Productos -------------------------------------------------------------- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.product-grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-product { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: box-shadow .2s, transform .2s, border-color .2s; }
.card-product:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: var(--line-strong); }
.card-product-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; }
.card-product-media { aspect-ratio: 1; background: #fff; border-bottom: 1px solid var(--line); overflow: hidden; }
.card-product-media img { width: 100%; height: 100%; object-fit: contain; padding: 14px; transition: transform .35s; }
.card-product:hover .card-product-media img { transform: scale(1.04); }
.card-product-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card-product-cat { font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--brand-strong); font-weight: 600; }
.card-product-title { font-size: 1.12rem; margin: 0 0 auto; color: var(--ink); line-height: 1.22; padding-bottom: 8px; }
.card-product:hover .card-product-title { color: var(--brand-strong); }

/* Catálogo --------------------------------------------------------------- */
.catalog { display: grid; grid-template-columns: 270px 1fr; gap: 40px; align-items: start; }
.catalog-side { position: sticky; top: 100px; min-width: 0; }
.catalog-main { min-width: 0; }
.side-search { position: relative; margin-bottom: 26px; }
.side-search input { width: 100%; padding: .7em 2.8em .7em 1em; border-radius: 10px; border: 1px solid var(--line-strong); background: #fff; }
.side-search input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.side-search button { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; padding: 8px; color: var(--muted); cursor: pointer; display: grid; }
.side-title { font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.side-cats { list-style: none; margin: 0 0 26px; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.side-cats a { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: .55em .8em; border-radius: 8px; text-decoration: none; color: var(--ink-2); font-weight: 500; }
.side-cats a span { font-size: .8rem; color: var(--muted); background: var(--bg-alt); border-radius: 999px; padding: .1em .6em; min-width: 2em; text-align: center; }
.side-cats a:hover { background: var(--bg-alt); color: var(--ink); }
.side-cats a[aria-current="page"] { background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; }
.side-cats a[aria-current="page"] span { background: #fff; color: var(--brand-deep); }
.side-help { background: var(--dark); color: #c3cec8; border-radius: var(--radius); padding: 20px; font-size: .95rem; }
.side-help strong { color: #fff; font-family: var(--font-head); font-size: 1.1rem; }
.side-help p { margin-bottom: .5em; }
.side-help .btn { margin-top: 8px; }
.catalog-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; min-height: 32px; }
.catalog-count { margin: 0; color: var(--muted); font-size: .95rem; }
.catalog-count strong { color: var(--ink); }

.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 40px; }
.pagination a, .pagination span { min-width: 42px; height: 42px; display: grid; place-items: center; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-weight: 600; background: #fff; }
.pagination a:hover { border-color: var(--brand); color: var(--brand-strong); }
.pagination span[aria-current] { background: var(--brand-strong); border-color: var(--brand-strong); color: #fff; }
.pagination .dots { border: 0; background: none; }

.empty { text-align: center; padding: 64px 24px; border: 1px dashed var(--line-strong); border-radius: var(--radius); background: var(--bg-alt); }
.empty > .icon { width: 40px; height: 40px; color: var(--muted); margin: 0 auto 12px; }

/* Ficha de producto ------------------------------------------------------ */
.product { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.gallery { position: sticky; top: 100px; }
.gallery-main { aspect-ratio: 1; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; overflow: hidden; }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; padding: 24px; }
.gallery-thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; }
.gallery-thumb { flex: 0 0 84px; aspect-ratio: 1; border: 2px solid var(--line); border-radius: 10px; background: #fff; padding: 4px; cursor: pointer; transition: border-color .15s; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: contain; }
.gallery-thumb:hover { border-color: var(--line-strong); }
.gallery-thumb.is-active { border-color: var(--brand); }
.product-cat { display: inline-block; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; text-decoration: none; margin-bottom: 10px; }
.product-title { margin-bottom: .3em; }
.product-code { display: inline-flex; gap: .5em; align-items: center; background: var(--bg-alt); border: 1px solid var(--line); border-radius: 8px; padding: .3em .8em; font-size: .92rem; color: var(--muted); margin-bottom: 1.2rem; }
.product-code strong { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; color: var(--ink); letter-spacing: .03em; }
.spec-block { margin-top: 26px; }
.spec-title { font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { padding: .35em .9em; border-radius: 999px; border: 1px solid var(--line-strong); font-size: .93rem; font-weight: 500; color: var(--ink); background: #fff; }
.spec-table { width: 100%; border-collapse: collapse; font-size: .97rem; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.spec-table th, .spec-table td { text-align: left; padding: .7em 1em; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }
.spec-table th { width: 42%; font-weight: 600; color: var(--ink); background: var(--bg-alt); }
.product-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.product-desc { margin-top: clamp(40px, 6vw, 64px); padding-top: 32px; border-top: 1px solid var(--line); max-width: 820px; }

/* Bloques institucionales ------------------------------------------------ */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.split-media > img { border-radius: var(--radius); width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.checklist { list-style: none; padding: 0; margin: 1.4rem 0 1.8rem; display: grid; gap: 10px; }
.checklist li { display: flex; gap: 10px; align-items: center; font-weight: 500; color: var(--ink); }
.checklist .icon { color: #fff; background: var(--brand); border-radius: 50%; padding: 3px; width: 22px; height: 22px; stroke-width: 3; }
.am-levels { list-style: none; padding: 0; margin: 1.4rem 0 1.8rem; display: grid; gap: 10px; }
.am-levels a { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 12px; padding: 12px 16px; border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: var(--radius-sm); background: #fff; color: var(--ink); text-decoration: none; transition: border-color .2s, box-shadow .2s; }
.am-levels a:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); color: var(--ink); }
.am-levels strong { font-family: var(--font-head); font-size: 1.08rem; }
.am-levels span { grid-column: 1; color: var(--muted); font-size: .92rem; }
.am-levels .icon { grid-row: 1 / span 2; grid-column: 2; color: var(--brand-strong); transition: transform .2s; }
.am-levels a:hover .icon { transform: translateX(3px); }
.contact-map { width: 100%; aspect-ratio: 4 / 3; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-alt); }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pillar { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; scroll-margin-top: 110px; }
.pillar .value-icon { margin-bottom: 18px; }
.pillar .prose { color: var(--muted); }

/* Banda CTA -------------------------------------------------------------- */
.cta-band { background: linear-gradient(120deg, var(--brand-deep), #04381d 70%); color: #cfe9da; padding: clamp(44px, 6vw, 72px) 0; position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; width: 420px; height: 420px; background: url(../img/logo-completo.webp) center / contain no-repeat; filter: brightness(0) invert(1); opacity: .06; right: -90px; top: -150px; transform: rotate(-12deg); }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 28px; flex-wrap: wrap; position: relative; z-index: 1; }
.cta-band .h2 { color: #fff; margin-bottom: .25em; }
.cta-band p { margin: 0; max-width: 52ch; }
.cta-band .btn-primary { background: #fff; color: var(--brand-deep); }
.cta-band .btn-primary:hover { background: var(--brand-soft); }

/* Contacto --------------------------------------------------------------- */
.contact { display: grid; grid-template-columns: 380px 1fr; gap: clamp(28px, 5vw, 56px); align-items: start; }
.contact-info { display: grid; gap: 12px; }
.contact-card { display: flex; gap: 14px; align-items: center; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; text-decoration: none; color: var(--ink); transition: border-color .18s, box-shadow .18s; }
a.contact-card:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); color: var(--ink); }
.contact-card strong { display: block; font-weight: 600; line-height: 1.3; word-break: break-word; }
.contact-card small { color: var(--muted); font-size: .86rem; }
.contact-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-strong); flex-shrink: 0; }
.contact-card-wa { background: var(--wa-strong); border-color: var(--wa-strong); color: #fff; }
.contact-card-wa small { color: #d9f5e4; }
.contact-card-wa .contact-icon { background: rgba(255,255,255,.16); color: #fff; }
a.contact-card-wa:hover { color: #fff; border-color: var(--wa-strong); }
.contact-form { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 4vw, 40px); box-shadow: var(--shadow-sm); }
.form-product { background: var(--brand-soft); color: var(--brand-deep); border-radius: 10px; padding: .7em 1em; font-size: .95rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; margin-bottom: 22px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: .92rem; color: var(--ink); }
.field input, .field textarea, .field select { width: 100%; padding: .75em .9em; border: 1px solid var(--line-strong); border-radius: 10px; background: #fff; transition: border-color .15s, box-shadow .15s; }
.field textarea { resize: vertical; min-height: 140px; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.has-error input, .has-error textarea { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: .87rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 10px; margin-bottom: 20px; font-size: .97rem; }
.alert .icon { margin-top: 2px; }
.alert-ok { background: var(--brand-soft); color: var(--brand-deep); border: 1px solid #bfe3cd; }
.alert-error { background: var(--danger-soft); color: var(--danger); border: 1px solid #f5c2bd; }

/* Footer ----------------------------------------------------------------- */
.site-footer { background: var(--dark); color: #a9b6af; font-size: .95rem; padding-top: 64px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 48px; }
.footer-brand img { width: 210px; margin-bottom: 18px; }
.footer-brand p { max-width: 38ch; }
.footer-title { color: #fff; font-size: .82rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 16px; }
.footer-links, .footer-contact { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.site-footer a { color: #cdd7d1; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer-contact .icon { color: var(--brand); margin-top: 3px; }
.social { display: flex; gap: 10px; }
.social a { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.16); }
.social a:hover { background: var(--brand-strong); border-color: var(--brand-strong); text-decoration: none; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 22px; padding-bottom: 26px; border-top: 1px solid rgba(255,255,255,.08); font-size: .85rem; color: #85938b; }

.wa-float { position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 58px; height: 58px; border-radius: 50%; background: var(--wa); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 28px -6px rgba(18, 140, 70, .6); transition: transform .2s; }
.wa-float:hover { transform: scale(1.07); color: #fff; }
.wa-float .icon { width: 30px; height: 30px; }
.wa-float::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--wa); z-index: -1; opacity: 0; }

/* Responsive ------------------------------------------------------------- */
@media (max-width: 1180px) {
  .nav-search input { width: 180px; }
  .nav { gap: 14px; }
}
@media (max-width: 1080px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .product-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .values-grid { grid-template-columns: repeat(2, 1fr); }
  .value { border-right: 0; padding: 24px 12px 24px 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 980px) {
  .site-header { top: 0; }
  .topbar { display: none; }
  .nav-toggle { display: grid; }
  .nav {
    position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 14px;
    background: #fff; border-bottom: 1px solid var(--line); padding: 16px var(--gutter) 22px; box-shadow: var(--shadow);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav ul { flex-direction: column; }
  .nav ul a { padding: .7em .2em; font-size: 1.15rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav ul a[aria-current="page"]::after { display: none; }
  .nav-search input { width: 100%; padding-top: .75em; padding-bottom: .75em; }
  .site-header.menu-open .nav-toggle .icon-open { display: none; }
  .site-header.menu-open .nav-toggle .icon-close { display: block; }
  .catalog { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .catalog-side { position: static; }
  .side-search { margin-bottom: 14px; }
  .side-title, .side-help { display: none; }
  .side-cats { flex-direction: row; overflow-x: auto; gap: 8px; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 6px; scrollbar-width: none; }
  .side-cats::-webkit-scrollbar { display: none; }
  .side-cats a { white-space: nowrap; border: 1px solid var(--line-strong); border-radius: 999px; padding: .45em .9em; }
  .product { grid-template-columns: 1fr; }
  .gallery { position: static; }
  .split { grid-template-columns: 1fr; }
  .contact { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .brand img { width: 160px; }
  .header-inner { min-height: 66px; }
  .product-grid, .product-grid-3 { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-product-body { padding: 12px 12px 14px; }
  .card-product-title { font-size: 1rem; }
  .card-product-media img { padding: 8px; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .cat-card { min-height: 150px; padding: 16px; }
  .cat-card-icon { top: 16px; left: 16px; width: 40px; height: 40px; }
  .cat-card-name { font-size: 1.1rem; }
  .values-grid { grid-template-columns: 1fr; }
  .value { padding: 18px 0; border-bottom: 1px solid var(--line); }
  .value:last-child { border-bottom: 0; }
  .hero-emblem { width: 120vw; right: -55vw; opacity: .35; }
  .hero-search { border-radius: 16px; flex-wrap: wrap; padding: 8px 8px 8px 16px; }
  .hero-search .btn { width: 100%; }
  .hero .actions-row .btn { width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .product-cta .btn { width: 100%; }
  .cta-inner .actions-row, .cta-inner .actions-row .btn { width: 100%; }
  .wa-float { width: 54px; height: 54px; right: 14px; bottom: 14px; }
}

/* Animaciones ------------------------------------------------------------- */
/* Todo el movimiento decorativo vive acá: quien pidió "reducir movimiento" en su
   sistema ve el sitio quieto y completo. */
@media (prefers-reduced-motion: no-preference) {
  /* Entrada del texto del hero */
  .hero-inner > * { animation: fade-up .8s cubic-bezier(.2, .7, .2, 1) both; }
  .hero-inner > :nth-child(2) { animation-delay: .1s; }
  .hero-inner > :nth-child(3) { animation-delay: .2s; }
  .hero-inner > :nth-child(4) { animation-delay: .3s; }
  .hero-inner > :nth-child(5) { animation-delay: .4s; }

  /* Logo del hero: 0–2,2 s entrada; después un ciclo de 9 s (gira la llave, pulso, brillo) */
  .he-ring {
    -webkit-mask-image: conic-gradient(from 180deg, #000 calc(var(--he-draw) - 12deg), transparent var(--he-draw));
    mask-image: conic-gradient(from 180deg, #000 calc(var(--he-draw) - 12deg), transparent var(--he-draw));
    animation: he-draw 1.7s cubic-bezier(.65, 0, .35, 1) .1s both;
  }
  .he-float { animation: he-float 7s ease-in-out 2.4s infinite alternate; }
  .he-float::before { animation: he-glow 1.6s ease 1.2s both, he-breathe 5s ease-in-out 2.8s infinite alternate; }
  .he-key { animation: he-rise 1.1s cubic-bezier(.2, .9, .25, 1.12) 1.05s both; }
  .he-key-turn { animation: he-turn 9s ease-in-out 2.2s infinite; }
  .he-pulse { animation: he-pulse 9s ease-out 2.2s infinite; }
  .he-shine::before { animation: he-shine 9s ease-in-out 2.2s infinite; }

  /* Aparición al hacer scroll (la clase .reveal la pone site.js) */
  .reveal { opacity: 0; }
  .reveal.is-in { animation: fade-up .75s cubic-bezier(.2, .7, .2, 1) var(--rd, 0s) both; }

  /* Logo de fondo en páginas internas y banda de contacto */
  .page-hero::after, .cta-band::after { animation: sway 14s ease-in-out infinite alternate; }

  /* Botón flotante de WhatsApp: entra y "late" cada tanto */
  .wa-float { animation: pop-in .5s cubic-bezier(.2, .9, .3, 1.3) 1s both; }
  .wa-float::before { animation: wa-ping 4s cubic-bezier(0, 0, .2, 1) 3s infinite; }

  .value-icon, .cat-card-icon { transition: transform .3s cubic-bezier(.2, .9, .3, 1.4); }
  .value:hover .value-icon, .pillar:hover .value-icon, .cat-card:hover .cat-card-icon { transform: translateY(-3px) rotate(-6deg); }
}

@keyframes fade-up { from { opacity: 0; translate: 0 22px; } to { opacity: 1; translate: none; } }
@keyframes he-draw {
  from { --he-draw: 0deg; transform: rotate(-40deg) scale(.92); opacity: 0; }
  20% { opacity: 1; }
  to { --he-draw: 372deg; transform: none; opacity: 1; }
}
@keyframes he-rise { from { transform: translateY(62%); } to { transform: none; } }
@keyframes he-glow { from { opacity: 0; } }
@keyframes he-breathe { to { transform: scale(1.12); } }
@keyframes he-float { to { transform: translateY(-14px) rotate(2deg); } }
@keyframes he-turn {
  0%, 3% { transform: perspective(1400px) rotateY(0); }
  10%, 22% { transform: perspective(1400px) rotateY(72deg); }
  30%, 100% { transform: perspective(1400px) rotateY(0); }
}
@keyframes he-pulse {
  0%, 9% { opacity: 0; transform: scale(1); }
  10% { opacity: .8; transform: scale(1); }
  30%, 100% { opacity: 0; transform: scale(1.3); }
}
@keyframes he-shine { 0%, 42% { transform: translateX(-100%); } 56%, 100% { transform: translateX(320%); } }
@keyframes sway { from { transform: rotate(-16deg); } to { transform: rotate(-4deg) translateY(10px); } }
@keyframes pop-in { from { opacity: 0; scale: .4; } }
@keyframes wa-ping { 0% { opacity: .55; transform: scale(1); } 60%, 100% { opacity: 0; transform: scale(1.65); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

@media (max-width: 1180px) and (min-width: 641px) {
  .hero-emblem { opacity: .32; right: -18vw; }
}
