/* =========================================================
   AVIX Engineering — sistema de diseño v4
   Precisión electromecánica y editorial industrial.
   Dos versiones del mismo sitio (interruptor en la barra superior):
     data-theme="mixto"  → secciones nieve / salvia alternadas con bloques carbón
     data-theme="oscuro" → todo carbón, según tokens del brandbook
   ========================================================= */

@font-face { font-family: "Teko"; src: url("../fonts/teko-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Teko"; src: url("../fonts/teko-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Teko"; src: url("../fonts/teko-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-var.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }

:root {
  /* Tokens oficiales */
  --bg-primary: #181816;
  --bg-surface: #20201D;
  --bg-surface-hover: #272723;
  --accent: #EA4A2A;
  --accent-hover: #D63F21;
  --text-primary: #F8F8F8;
  --text-secondary: #A6A6A6;
  --surface-light: #DCE5E2;
  --border-subtle: rgba(220, 229, 226, 0.12);
  --border-strong: rgba(220, 229, 226, 0.24);
  /* Derivados */
  --ink-2: #4A4A47;
  --accent-ink: #B5351A;                 /* naranja para texto pequeño sobre fondos claros (AA) */
  --r: 3px; --r2: 6px;
  --wrap: 1240px; --gutter: clamp(20px, 4vw, 40px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --display: "Teko", "Arial Narrow", sans-serif;
  --text: "Neue Haas Grotesk Display", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  /* Tono de trabajo (cada sección lo redefine) */
  --bg: #FFFFFF; --fg: var(--bg-primary); --fg2: var(--ink-2); --card: #F8F8F8; --card-h: #F1F3F2;
  --line: rgba(24, 24, 22, 0.12); --line2: rgba(24, 24, 22, 0.3); --ink: var(--accent-ink);
}

/* ---------- Tonos de sección ---------- */
.t-white { --bg: #FFFFFF; --fg: #181816; --fg2: #4A4A47; --card: #F8F8F8; --card-h: #F1F3F2; --line: rgba(24,24,22,.12); --line2: rgba(24,24,22,.3); --ink: var(--accent-ink); }
.t-snow  { --bg: #F8F8F8; --fg: #181816; --fg2: #4A4A47; --card: #FFFFFF; --card-h: #FFFFFF; --line: rgba(24,24,22,.12); --line2: rgba(24,24,22,.3); --ink: var(--accent-ink); }
.t-sage  { --bg: #DCE5E2; --fg: #181816; --fg2: #3D3D3A; --card: #F8F8F8; --card-h: #FFFFFF; --line: rgba(24,24,22,.16); --line2: rgba(24,24,22,.36); --ink: #A83018; }
.t-dark, [data-theme="oscuro"] .t-white, [data-theme="oscuro"] .t-snow {
  --bg: var(--bg-primary); --fg: var(--text-primary); --fg2: var(--text-secondary); --card: var(--bg-surface); --card-h: var(--bg-surface-hover);
  --line: var(--border-subtle); --line2: var(--border-strong); --ink: var(--accent); }
[data-theme="oscuro"] .t-sage {
  --bg: var(--bg-surface); --fg: var(--text-primary); --fg2: var(--text-secondary); --card: var(--bg-primary); --card-h: var(--bg-surface-hover);
  --line: var(--border-subtle); --line2: var(--border-strong); --ink: var(--accent); }
.t-white, .t-snow, .t-sage, .t-dark { background: var(--bg); color: var(--fg); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 96px; }
body { margin: 0; background: var(--bg-primary); color: var(--fg); font-family: var(--text); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol, dl, dd, figure, fieldset { margin: 0; padding: 0; border: 0; }
ul, ol { list-style: none; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
[hidden] { display: none !important; }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--accent); color: #181816; padding: 8px 14px; border-radius: var(--r); z-index: 200; font-weight: 600; }
.skip:focus { left: 16px; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.num { font-variant-numeric: tabular-nums; }

h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; text-transform: uppercase; letter-spacing: .02em; line-height: .98; margin: 0; }
h1 { font-size: clamp(46px, 6.4vw, 92px); }
h2 { font-size: clamp(36px, 4.2vw, 58px); }
h3 { font-size: clamp(26px, 2.4vw, 32px); font-weight: 500; line-height: 1.02; }
h4 { font-size: 30px; font-weight: 500; line-height: 1; }
h1 em { font-style: normal; color: var(--accent); }
.lead { font-size: clamp(17px, 1.4vw, 19px); line-height: 1.55; color: var(--fg2); max-width: 58ch; }
.note { font-size: 13px; line-height: 1.55; color: var(--fg2); max-width: 86ch; }
.ulink { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line2); transition: text-decoration-color .2s; }
.ulink:hover { text-decoration-color: var(--accent); }

/* Etiqueta técnica: 01 / ACADEMIA */
.kicker, .tile-n { display: flex; align-items: center; gap: 10px; font-size: 12px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--fg2); margin-bottom: 18px; }
.kicker::before { content: ""; width: 28px; height: 2px; background: var(--accent); flex: none; }
.kicker b, .tile-n b { color: var(--ink); font-variant-numeric: tabular-nums; font-weight: 700; }
.kicker i, .tile-n i, .crumbs i, .creds dt i { font-style: normal; opacity: .45; }
.bar { font-style: normal; color: var(--accent); font-weight: 500; }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 12px 22px; border-radius: var(--r); border: 1px solid transparent; font-weight: 600; font-size: 15px; line-height: 1.2; cursor: pointer; transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease); }
.btn svg { width: 16px; height: 16px; flex: none; transition: transform .35s var(--ease); }
.btn:hover svg:last-child { transform: translateX(3px); }
.btn-primary { background: var(--accent); color: #181816; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { border-color: var(--border-strong); color: var(--text-primary); }
.btn-ghost:hover { border-color: var(--text-primary); }
.btn-dark { background: var(--fg); color: var(--bg); }
.btn-dark:hover { background: var(--accent); color: #181816; }
.btn-line { border-color: var(--line2); color: var(--fg); }
.btn-line:hover { border-color: var(--fg); }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: 14px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.more { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; border-bottom: 1px solid var(--line2); padding-bottom: 4px; transition: border-color .25s var(--ease); }
.more svg { width: 16px; height: 16px; color: var(--ink); transition: transform .35s var(--ease); }
a.more:hover, a:hover > .more { border-color: var(--accent); }
a.more:hover svg, a:hover > .more svg { transform: translateX(4px); }

/* ---------- Barra utilitaria y encabezado (siempre carbón: logo blanco con V naranja) ---------- */
.utilbar { background: #121211; color: var(--text-secondary); font-size: 12px; border-bottom: 1px solid var(--border-subtle); }
.utilbar .wrap { display: flex; justify-content: space-between; align-items: center; min-height: 36px; gap: 16px; }
.util-left { display: flex; gap: 20px; letter-spacing: .02em; }
.util-left a:hover, .socials a:hover { color: var(--text-primary); }
.util-right { display: flex; align-items: center; gap: 16px; }
.socials { display: flex; gap: 2px; }
.socials a { display: grid; place-items: center; width: 28px; height: 28px; transition: color .2s; }
.socials svg { width: 14px; height: 14px; }
.socials.big { gap: 8px; }
.socials.big a { width: 44px; height: 44px; border: 1px solid var(--line); border-radius: var(--r); color: var(--fg2); transition: border-color .25s var(--ease), color .25s; }
.socials.big a:hover { border-color: var(--accent); color: var(--fg); }
.socials.big svg { width: 18px; height: 18px; }
.theme-toggle { display: inline-flex; align-items: center; gap: 6px; background: none; border: 1px solid var(--border-strong); border-radius: var(--r); padding: 3px 9px; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-secondary); cursor: pointer; transition: color .2s, border-color .2s; }
.theme-toggle:hover { color: var(--text-primary); border-color: var(--text-primary); }
.theme-toggle b { color: var(--text-primary); font-weight: 600; }
.theme-toggle svg { width: 13px; height: 13px; }
[data-theme="mixto"] .theme-toggle svg:nth-of-type(2), [data-theme="oscuro"] .theme-toggle svg:nth-of-type(1) { display: none; }
.lang { display: flex; border: 1px solid var(--border-strong); border-radius: var(--r); overflow: hidden; font-size: 11px; font-weight: 600; letter-spacing: .08em; }
.lang a, .lang span { display: block; padding: 3px 9px; }
.lang a:hover { color: var(--text-primary); }
.lang span { background: var(--text-primary); color: #181816; }

.site-header { position: sticky; top: 0; z-index: 50; background: rgba(24, 24, 22, 0.86); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); color: var(--text-primary); border-bottom: 1px solid var(--border-subtle); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 24px; }
.brand img { height: 38px; width: auto; }
.nav ul { display: flex; gap: clamp(18px, 2.6vw, 36px); }
.nav a { position: relative; display: block; padding: 8px 0; font-size: 14px; font-weight: 500; letter-spacing: .02em; color: var(--text-secondary); transition: color .2s; }
.nav a::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text-primary); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav-extra { display: none; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.menu-toggle { display: none; width: 40px; height: 40px; background: none; border: 1px solid var(--border-strong); border-radius: var(--r); cursor: pointer; }
.menu-toggle span { display: block; width: 18px; height: 2px; background: var(--text-primary); margin: 5px auto; transition: transform .3s var(--ease); }
.menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

/* ---------- Espacios fotográficos ---------- */
.slot { position: relative; overflow: hidden; background: var(--bg-surface); border-radius: var(--r2); border: 1px solid var(--line); }
.slot.r16x9 { aspect-ratio: 16 / 9; } .slot.r4x3 { aspect-ratio: 4 / 3; } .slot.r4x5 { aspect-ratio: 4 / 5; }
.slot.r1x1 { aspect-ratio: 1 / 1; } .slot.r21x9 { aspect-ratio: 21 / 9; }
.slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
a:hover .slot img, .cat:hover .slot img { transform: scale(1.03); }
.slot-ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--text-primary);
  background-image: linear-gradient(var(--border-subtle) 1px, transparent 1px), linear-gradient(90deg, var(--border-subtle) 1px, transparent 1px); background-size: 32px 32px; }
.slot-ph svg { width: 26%; max-width: 160px; opacity: .22; }
.slot-ph span { position: absolute; left: 14px; bottom: 12px; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-secondary); }

/* ---------- Portada de inicio (full-bleed 16:9) ---------- */
.hero { position: relative; min-height: clamp(520px, 56.25vw, calc(100vh - 104px)); width: 100%; display: flex; align-items: flex-end; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; aspect-ratio: auto !important; border: 0; border-radius: 0; }
.hero-bg img { object-position: 62% 35%; }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(24,24,22,.94) 0%, rgba(24,24,22,.82) 36%, rgba(24,24,22,.3) 70%, rgba(24,24,22,.45) 100%), linear-gradient(0deg, rgba(24,24,22,.7) 0%, transparent 38%); }
.hero .wrap { position: relative; display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; padding-top: 64px; padding-bottom: clamp(40px, 6vw, 80px); }
.hero-copy { max-width: 760px; }
.hero h1 { font-size: clamp(38px, min(4.8vw, 8.6vh), 76px); margin-bottom: 20px; max-width: 19ch; }
.hero .wrap { padding-top: 40px; }
.hero .actions { margin-top: 26px; }
.hero .lead { color: #D2D4D3; }
.floors { display: grid; gap: 0; font-family: var(--display); font-size: 20px; letter-spacing: .08em; color: var(--text-secondary); border-left: 1px solid var(--border-strong); }
.floors li { padding: 14px 0 14px 18px; position: relative; line-height: 1; font-variant-numeric: tabular-nums; }
.floors li::before { content: ""; position: absolute; left: -1px; top: 50%; width: 10px; height: 1px; background: var(--border-strong); }
.floors .on { color: var(--text-primary); }
.floors .on::before { width: 3px; height: 100%; top: 0; background: var(--accent); }

/* ---------- Credenciales ---------- */
.creds dl { display: grid; grid-template-columns: repeat(4, 1fr); }
.creds dl > div { padding: 36px 28px; border-left: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.creds dl > div:last-child { border-right: 1px solid var(--line); }
.creds dt { font-family: var(--display); font-weight: 600; font-size: clamp(40px, 4.4vw, 60px); line-height: .95; letter-spacing: .02em; text-transform: uppercase; white-space: nowrap; }
.creds dt i { color: var(--accent); opacity: 1; font-weight: 500; }
.creds dd { margin-top: 10px; font-size: 14px; color: var(--fg2); max-width: 26ch; }

/* ---------- Secciones ---------- */
.section { padding: clamp(72px, 9vw, 128px) 0; }
.sec-head { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: end; margin-bottom: clamp(36px, 5vw, 64px); padding-bottom: clamp(24px, 3vw, 36px); border-bottom: 1px solid var(--line); }
.sec-head .lead { justify-self: end; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 88px); align-items: center; }
.split.top { align-items: start; }
.lead + .note { margin-top: 18px; }
.split.rev > :first-child { order: 2; }
.split h2, .narrative h2 { margin-bottom: 20px; }
.after { margin-top: 32px; }
.sec-head + .note, .finder + .note, .courses + .note, .figures + .note { margin-top: 24px; }
.track + .note { margin-top: 32px; }

/* Listas técnicas */
.ticks { display: grid; gap: 12px; margin-top: 24px; }
.ticks li { position: relative; padding-left: 26px; color: var(--fg2); font-size: 15px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .72em; width: 14px; height: 2px; background: var(--accent); }
.lines { margin-top: 28px; border-top: 1px solid var(--line); }
.lines > div { display: grid; grid-template-columns: 180px 1fr; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.lines dt { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--fg2); padding-top: 3px; }
.lines dd { font-size: 15px; }
.lines dd b { font-family: var(--display); font-size: 26px; font-weight: 600; letter-spacing: .02em; line-height: 1; }
.specs { display: grid; margin-top: auto; border-top: 1px solid var(--line); }
.specs li { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.specs span { color: var(--fg2); }
.specs b { font-weight: 600; text-align: right; }

/* ---------- Servicios (bento) ---------- */
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; }
.tile { position: relative; display: flex; flex-direction: column; gap: 16px; padding: clamp(24px, 3vw, 40px); background: var(--card); border: 1px solid var(--line); border-radius: var(--r2); transition: border-color .35s var(--ease), background .35s var(--ease); }
.tile::after { content: ""; position: absolute; left: -1px; top: -1px; width: 0; height: 2px; background: var(--accent); transition: width .6s var(--ease); }
.tile:hover { border-color: var(--line2); background: var(--card-h); }
.tile:hover::after { width: calc(100% + 2px); }
.tile p:not(.tile-n) { color: var(--fg2); font-size: 15px; max-width: 54ch; }
.tile .tile-n { margin-bottom: 8px; }
.tile .more { align-self: flex-start; margin-top: 12px; }
.tile-a { grid-column: span 7; min-height: 440px; }
.tile-b { grid-column: span 5; --card: var(--bg-primary); --card-h: var(--bg-surface); --fg: var(--text-primary); --fg2: var(--text-secondary); --line: var(--border-subtle); --line2: var(--border-strong); --ink: var(--accent); color: var(--fg); }
[data-theme="oscuro"] .tile-b { --card: var(--bg-surface-hover); }
.tile-c { grid-column: span 12; flex-direction: row; align-items: center; justify-content: space-between; gap: 32px; }
.tile-c .tile-n { margin: 0; flex: none; }
.tile-c > div { flex: 1; display: grid; grid-template-columns: 1fr 1.2fr; gap: 32px; align-items: center; }
.tile-c .more { margin: 0; flex: none; }

/* ---------- Averixia ---------- */
.caps { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 28px; border: 1px solid var(--line); border-radius: var(--r2); }
.caps li { display: grid; justify-items: center; gap: 8px; padding: 18px 8px; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--fg2); }
.caps li + li { border-left: 1px solid var(--line); }
.caps svg { width: 22px; height: 22px; color: var(--ink); }
.duo { position: relative; padding: 0 0 56px 12%; }
.duo .chat { position: absolute; left: 0; bottom: 0; width: 76%; }
.chat { display: grid; gap: 10px; padding: 18px; background: #121211; color: var(--text-primary); border: 1px solid var(--border-strong); border-radius: var(--r2); font-size: 13.5px; line-height: 1.5; }
.chat-head { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--border-subtle); font-size: 12px; letter-spacing: .06em; color: var(--text-secondary); }
.chat-head .dot { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #181816; font-weight: 700; font-size: 12px; }
.bubble { padding: 10px 12px; border-radius: var(--r); max-width: 92%; }
.bubble.user { justify-self: end; background: var(--surface-light); color: #181816; }
.bubble.bot { background: var(--bg-surface-hover); border-left: 2px solid var(--accent); }
.bubble.bot b { color: var(--accent); font-weight: 600; }
.figures { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.figures > div { padding: 28px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--card); }
.figures dt { font-family: var(--display); font-weight: 600; font-size: 64px; line-height: .9; }
.figures dd { margin-top: 8px; font-size: 14px; color: var(--fg2); }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); border-left: 1px solid var(--line); border-top: 1px solid var(--line); }
.plan { position: relative; display: grid; gap: 8px; align-content: start; padding: 32px 28px 36px; background: var(--card); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.plan::before { content: ""; position: absolute; left: 0; top: 0; width: 100%; height: 4px; background: var(--surface-light); }
.plan.pro::before { background: var(--text-secondary); }
.plan.max::before { background: var(--accent); }
.plan.ultra::before { background: var(--fg); }
.plan .k, .panel .k, .price-card .k { font-size: 11px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--fg2); }
.plan h3 { font-size: 46px; font-weight: 600; }
.plan .meta { font-size: 13px; font-weight: 600; letter-spacing: .04em; }
.plan p:last-child { font-size: 14px; color: var(--fg2); }
.callout { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-top: 24px; padding: 20px 24px; border: 1px solid var(--line2); border-left: 3px solid var(--accent); border-radius: var(--r); }
.callout p { font-weight: 500; }
.panel { display: grid; gap: 14px; align-content: start; padding: clamp(24px, 3vw, 40px); background: var(--card); border: 1px solid var(--line); border-radius: var(--r2); }
.panel p:not(.k) { color: var(--fg2); font-size: 15px; }
.panel .actions { margin-top: 12px; }

/* ---------- Portadas internas ---------- */
.page-hero { position: relative; border-bottom: 1px solid var(--line); overflow: hidden; }
.page-hero::before { content: ""; position: absolute; inset: 0; pointer-events: none; background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 64px 64px; opacity: .55; -webkit-mask-image: linear-gradient(90deg, transparent 30%, #000); mask-image: linear-gradient(90deg, transparent 30%, #000); }
.page-hero .wrap { position: relative; display: grid; grid-template-columns: 1.3fr .7fr; gap: 48px; align-items: end; padding-top: clamp(48px, 7vw, 96px); padding-bottom: clamp(48px, 6vw, 80px); }
.page-hero h1 { font-size: clamp(42px, 5.4vw, 76px); margin-bottom: 20px; }
.crumbs { display: flex; gap: 8px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--fg2); margin-bottom: 28px; }
.crumbs a:hover { color: var(--fg); }
.price-card { display: grid; gap: 12px; padding: 28px; background: var(--bg-primary); color: var(--text-primary); border-radius: var(--r2); border-top: 3px solid var(--accent); --fg2: var(--text-secondary); }
.price-card .big { font-family: var(--display); font-weight: 600; font-size: 76px; line-height: .85; letter-spacing: .02em; }
.price-card p:not(.k):not(.big):not(.avx) { font-size: 14px; color: var(--text-secondary); }
.price-card .btn { margin-top: 6px; }
.avx { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 600; font-size: 52px; line-height: .9; letter-spacing: .02em; }
.avx span { font-family: var(--text); font-size: 13px; font-weight: 700; letter-spacing: .06em; padding: 3px 7px; border-radius: var(--r); background: var(--accent); color: #181816; }
.hero-side { align-self: end; width: 100%; min-width: 0; }

/* ---------- Academia: catálogo ---------- */
.track + .track { margin-top: clamp(48px, 6vw, 80px); }
.track-head { display: grid; grid-template-columns: 1fr minmax(240px, 380px); gap: 40px; align-items: end; margin-bottom: 24px; }
.track-head h3 { font-size: clamp(30px, 3vw, 42px); font-weight: 600; }
.courses { border-top: 1px solid var(--line2); }
.course { display: grid; grid-template-columns: 44px minmax(190px, 250px) 1fr auto auto; gap: 24px; align-items: center; padding: 22px 16px 22px 0; border-bottom: 1px solid var(--line); transition: background .35s var(--ease), padding .35s var(--ease); }
.course:hover { background: var(--card); padding-left: 16px; }
.course-n { font-family: var(--display); font-size: 20px; color: var(--fg2); font-variant-numeric: tabular-nums; letter-spacing: .06em; }
.course .tag { display: block; font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--ink); margin-bottom: 4px; }
.course-d { font-size: 14.5px; color: var(--fg2); max-width: 60ch; }
.course-p { text-align: right; line-height: 1.1; }
.course-p b { display: block; font-family: var(--display); font-size: 30px; font-weight: 600; letter-spacing: .02em; }
.course-p span { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--fg2); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); counter-reset: step; border-top: 1px solid var(--line2); }
.steps li { counter-increment: step; padding: 28px 28px 8px 0; }
.steps li + li { padding-left: 28px; border-left: 1px solid var(--line); }
.steps li::before { content: "0" counter(step); display: block; font-family: var(--display); font-size: 20px; letter-spacing: .08em; color: var(--ink); margin-bottom: 20px; font-variant-numeric: tabular-nums; }
.steps h3 { margin-bottom: 10px; }
.steps p { font-size: 15px; color: var(--fg2); }
.steps.col { grid-template-columns: 1fr; border-top: 0; }
.steps.col li { display: grid; grid-template-columns: 56px 1fr; column-gap: 8px; padding: 24px 0; border-left: 0; border-top: 1px solid var(--line); }
.steps.col li::before { grid-row: span 2; margin: 4px 0 0; }

/* ---------- Repuestos ---------- */
.finder { display: grid; grid-template-columns: auto minmax(200px, 260px) 1fr; gap: 20px 24px; align-items: end; padding: clamp(20px, 3vw, 32px); background: var(--card); border: 1px solid var(--line); border-radius: var(--r2); }
.finder legend, .field label { display: block; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--fg2); margin-bottom: 8px; padding: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span { display: block; padding: 0 14px; line-height: 46px; border: 1px solid var(--line2); border-radius: var(--r); font-size: 14px; font-weight: 500; cursor: pointer; transition: background .25s var(--ease), color .25s, border-color .25s; }
.chip input:checked + span { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 3px; }
.finder-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 12px; padding-top: 20px; border-top: 1px solid var(--line); }
.cats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--r2); overflow: hidden; }
.cat .slot { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; aspect-ratio: 4 / 3; }
.cat .tile-n { margin: 24px 24px 10px; }
.cat h3 { margin: 0 24px; }
.cat .ticks { margin: 18px 24px 24px; }
.cat .more { margin: auto 24px 28px; align-self: flex-start; }

/* ---------- Formularios ---------- */
.form-card, .finder { --field: var(--card-h); }
[data-theme="oscuro"] .form-card, [data-theme="oscuro"] .finder, .t-dark .form-card { --field: var(--bg-surface-hover); }
.form-card { padding: clamp(24px, 3.4vw, 44px); background: var(--card); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--r2); }
.form-card > h2 { font-size: clamp(30px, 3vw, 40px); margin-bottom: 28px; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form .full { grid-column: 1 / -1; }
.input { width: 100%; min-height: 48px; padding: 12px 14px; background: var(--field, var(--bg)); color: var(--fg); border: 1px solid var(--line2); border-radius: var(--r); font-size: 15px; transition: border-color .2s; }
.input::placeholder { color: var(--fg2); opacity: .7; }
.input:hover { border-color: var(--fg2); }
.input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
select.input { appearance: none; -webkit-appearance: none; padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
textarea.input { min-height: 140px; resize: vertical; }
.input[aria-invalid="true"] { border-color: var(--accent); }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 13.5px; color: var(--fg2); cursor: pointer; }
.consent input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.consent a { text-decoration: underline; text-underline-offset: 3px; color: var(--fg); }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.form-status { flex: 1; min-width: 220px; padding: 12px 14px; border-radius: var(--r); font-size: 14px; border: 1px solid var(--line2); border-left: 3px solid var(--fg2); }
.form-status.ok { border-left-color: #2E8B57; }
.form-status.err { border-left-color: var(--accent); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Nosotros ---------- */
.narrative { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(36px, 6vw, 88px); align-items: start; }
.prose { display: grid; gap: 20px; font-size: clamp(17px, 1.35vw, 19px); line-height: 1.6; color: var(--fg2); }
.prose p:first-child { color: var(--fg); }
.places { display: grid; grid-template-columns: 1fr 1fr; margin-top: 24px; border: 1px solid var(--line); border-radius: var(--r2); background: var(--card); }
.places > div { padding: 28px; }
.places > div + div { border-left: 1px solid var(--line); }
.places dt { font-family: var(--display); font-size: 34px; font-weight: 600; text-transform: uppercase; letter-spacing: .02em; line-height: 1; margin-bottom: 10px; }
.places dd { color: var(--fg2); font-size: 15px; max-width: 46ch; }
.principles { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line2); }
.principles article { padding: 32px 32px 8px 0; }
.principles article + article { padding-left: 32px; border-left: 1px solid var(--line); }
.principles svg { width: 34px; height: 34px; color: var(--ink); margin-bottom: 28px; }
.principles h3 { margin-bottom: 12px; }
.principles p:last-child { color: var(--fg2); font-size: 15px; }
.principles .tile-n { margin-bottom: 10px; }

/* ---------- Contacto ---------- */
.contact { display: grid; grid-template-columns: 1.35fr .65fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.channels h2 { font-size: clamp(30px, 3vw, 40px); margin-bottom: 20px; }
.channels dl { border-top: 1px solid var(--line2); }
.channels dl > div { padding: 20px 0; border-bottom: 1px solid var(--line); }
.channels dt { display: flex; align-items: center; gap: 10px; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--fg2); margin-bottom: 8px; }
.channels dt svg { width: 16px; height: 16px; color: var(--ink); }
.channels dd { font-size: 16px; font-weight: 500; overflow-wrap: anywhere; }
.channels dd a { border-bottom: 1px solid var(--line2); transition: border-color .2s; }
.channels dd a:hover { border-color: var(--accent); }
.channels h3 { font-family: var(--text); font-size: 11px; font-weight: 600; letter-spacing: .14em; color: var(--fg2); margin: 24px 0 12px; }

/* ---------- Legal ---------- */
.legal { display: grid; grid-template-columns: 280px 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.legal-nav { position: sticky; top: 96px; }
.legal-nav ol { border-top: 1px solid var(--line2); margin-bottom: 20px; }
.legal-nav a { display: flex; gap: 14px; padding: 14px 0 14px 0; border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 500; color: var(--fg2); transition: color .2s, padding .35s var(--ease); }
.legal-nav a b { color: var(--ink); font-variant-numeric: tabular-nums; }
.legal-nav a:hover, .legal-nav a[aria-current="true"] { color: var(--fg); padding-left: 10px; }
.legal-nav a[aria-current="true"] { box-shadow: inset 2px 0 0 var(--accent); }
.legal-body { max-width: 760px; }
.legal-body article { padding-bottom: 56px; margin-bottom: 56px; border-bottom: 1px solid var(--line); outline: none; }
.legal-body article:last-child { border: 0; margin: 0; padding: 0; }
.legal-body h2 { font-size: clamp(30px, 3.2vw, 44px); margin-bottom: 8px; }
.legal-body h3 { font-family: var(--text); font-size: 16px; font-weight: 600; text-transform: none; letter-spacing: 0; line-height: 1.4; margin: 32px 0 10px; }
.legal-body p, .legal-body li { color: var(--fg2); font-size: 15.5px; }
.legal-body ul { display: grid; gap: 8px; padding-left: 20px; list-style: square; }
.legal-body ul + p { margin-top: 12px; }
.legal-body strong { color: var(--fg); font-weight: 600; }
.legal-body li::marker { color: var(--accent); }

/* ---------- Cierre ---------- */
.closing { position: relative; overflow: hidden; border-top: 1px solid var(--border-subtle); }
.closing-bg { position: absolute; inset: 0; aspect-ratio: auto !important; border: 0; border-radius: 0; background: var(--bg-primary); }
.closing-bg .slot-ph svg, .closing-bg .slot-ph span { display: none; }
.closing-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(24,24,22,.95) 0%, rgba(24,24,22,.82) 45%, rgba(24,24,22,.45) 100%); }
.closing .wrap { position: relative; display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; flex-wrap: wrap; padding-top: clamp(72px, 9vw, 120px); padding-bottom: clamp(72px, 9vw, 120px); }
.closing h2 { margin-bottom: 16px; max-width: 16ch; }
.closing .actions { margin: 0; }

/* ---------- Pie ---------- */
.site-footer { background: #121211; color: var(--text-secondary); font-size: 14px; border-top: 1px solid var(--border-subtle); padding: 72px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 48px; padding-bottom: 48px; }
.footer-brand img { height: 40px; width: auto; margin-bottom: 20px; }
.footer-brand p { max-width: 38ch; margin-bottom: 16px; }
.footer-brand .socials { margin-left: -7px; }
.site-footer h2 { font-family: var(--text); font-size: 11px; font-weight: 600; letter-spacing: .16em; color: var(--text-primary); margin-bottom: 18px; line-height: 1.4; }
.footer-grid li + li { margin-top: 10px; }
.footer-grid .socials li { margin: 0; }
.footer-grid a { transition: color .2s; }
.footer-grid a:hover, .footer-legal a:hover { color: var(--text-primary); }
.footer-legal { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-top: 24px; border-top: 1px solid var(--border-subtle); font-size: 12.5px; }
.footer-legal p:last-child { display: flex; gap: 20px; }

.wa-fab { position: fixed; right: 20px; bottom: 20px; z-index: 60; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: #1FA855; color: #fff; border: 2px solid #121211; transition: transform .35s var(--ease); }
.wa-fab:hover { transform: translateY(-3px); }
.wa-fab svg { width: 26px; height: 26px; }

/* ---------- Movimiento: revelado vertical ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0ms); }
.js [data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; transition-delay: 0ms !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
}

/* ---------- Responsivo ---------- */
@media (max-width: 1100px) {
  .course { grid-template-columns: 36px minmax(160px, 210px) 1fr auto; }
  .course-p { display: none; }
  .finder { grid-template-columns: 1fr 1fr; }
  .finder fieldset { grid-column: 1 / -1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .util-left span, .utilbar .socials, .theme-toggle span { display: none; }
  .nav { position: fixed; inset: 105px 0 0 0; display: none; flex-direction: column; justify-content: space-between; padding: 16px var(--gutter) 32px; background: var(--bg-primary); overflow-y: auto; }
  .nav.open { display: flex; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav a { padding: 18px 0; font-family: var(--display); font-size: 34px; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; line-height: 1; border-bottom: 1px solid var(--border-subtle); color: var(--text-primary); }
  .nav a::after { display: none; }
  .nav a[aria-current="page"] { color: var(--accent); }
  .nav-extra { display: block; }
  .nav-extra .socials { gap: 8px; }
  .nav-extra .socials a { width: 44px; height: 44px; border: 1px solid var(--border-strong); border-radius: var(--r); color: var(--text-secondary); }
  .nav-extra .socials svg { width: 18px; height: 18px; }
  .menu-toggle { display: block; }
  .hero { min-height: min(720px, calc(100vh - 104px)); }
  .hero h1 { font-size: clamp(38px, 10.5vw, 60px); }
  .hero-bg::after { background: linear-gradient(0deg, rgba(24,24,22,.96) 0%, rgba(24,24,22,.78) 48%, rgba(24,24,22,.35) 100%); }
  .floors { display: none; }
  .creds dl { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .creds dt { font-size: clamp(28px, 8.6vw, 44px); white-space: normal; }
  .creds dl > div:nth-child(2) { border-right: 1px solid var(--line); }
  .creds dl > div { padding: 24px 18px; }
  .sec-head, .split, .page-hero .wrap, .narrative, .contact, .legal, .track-head { grid-template-columns: 1fr; }
  .sec-head { gap: 20px; }
  .sec-head .lead { justify-self: start; }
  .split.rev > :first-child { order: 0; }
  .tile-a, .tile-b, .tile-c { grid-column: span 12; min-height: 0; }
  .tile-c, .tile-c > div { flex-direction: column; align-items: flex-start; grid-template-columns: 1fr; gap: 16px; }
  .figures, .plans { grid-template-columns: 1fr 1fr; }
  .cats, .principles, .steps { grid-template-columns: 1fr; }
  .steps li, .steps li + li { padding: 24px 0; border-left: 0; }
  .steps li + li { border-top: 1px solid var(--line); }
  .principles article, .principles article + article { padding: 28px 0; border-left: 0; }
  .principles article + article { border-top: 1px solid var(--line); }
  .course { grid-template-columns: 32px 1fr auto; row-gap: 8px; }
  .course-d { grid-column: 2 / -1; grid-row: 2; }
  .course:hover { padding-left: 0; background: none; }
  .legal-nav { position: static; }
  .duo { padding: 0 0 0 0; }
  .duo .chat { position: relative; width: auto; margin: -72px 16px 0; }
  .closing .wrap { align-items: flex-start; flex-direction: column; }
  .track-head .slot { max-width: 520px; }
}
@media (max-width: 560px) {
  .form, .places, .finder { grid-template-columns: 1fr; }
  .places > div + div { border-left: 0; border-top: 1px solid var(--line); }
  .lines > div { grid-template-columns: 1fr; gap: 4px; }
  .figures dt { font-size: 48px; }
  .plans { grid-template-columns: 1fr; }
  .caps li { font-size: 10px; letter-spacing: .08em; }
  .footer-grid { grid-template-columns: 1fr; gap: 36px; }
  .btn { width: 100%; }
  .header-actions .btn, .callout .btn, .course .btn, .btn-sm { width: auto; }
  .course { grid-template-columns: 1fr auto; }
  .course-n { display: none; }
  .course-d { grid-column: 1 / -1; }
  .actions { width: 100%; }
}

/* ---------- Marca Averixia (logos oficiales) ---------- */
.avx-logo { display: block; margin-bottom: 22px; }
.avx-logo img { height: 40px; width: auto; }
.avx-logo.sm img { height: 26px; }
.avx-logo.sm { margin-bottom: 4px; }
.avx-logo.md img { height: clamp(34px, 3.4vw, 46px); }
.avx-logo .on-dark, .t-dark .avx-logo .on-light, .tile-b .avx-logo .on-light,
[data-theme="oscuro"] .avx-logo .on-light { display: none; }
.t-dark .avx-logo .on-dark, .tile-b .avx-logo .on-dark, [data-theme="oscuro"] .avx-logo .on-dark { display: block; }
.avx-iso { width: 26px; height: 26px; border-radius: 6px; flex: none; }
.channels dt .avx-iso { width: 18px; height: 18px; border-radius: 4px; }
.avx-card { justify-items: stretch; }
.avx-vert { width: min(230px, 70%); height: auto; margin: 4px auto 10px; }
.plan h3 { line-height: 0; margin: 4px 0 6px; }
.plan h3 img { height: 46px; width: auto; }
