/* =========================================================
   MarvinApps — estilos globales
   Temas: [data-theme="dark"] (por defecto) y [data-theme="light"]
   ========================================================= */

/* Fuentes locales (variables, WOFF2): Manrope 400–800, Sora 600–800 */
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("../fonts/manrope-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("../fonts/manrope-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Sora"; font-style: normal; font-weight: 600 800; font-display: swap; src: url("../fonts/sora-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Sora"; font-style: normal; font-weight: 600 800; font-display: swap; src: url("../fonts/sora-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root,
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #022b31;
  --bg-alt: #05323a;
  --bg-header: rgba(1, 40, 46, 0.82);
  --surface: #03373f;
  --surface-2: #02303a;
  --surface-hover: #054049;
  --icon-bg: #04464d;
  --text: #f1f7f8;
  --text-muted: #a3bcc1;
  --text-soft: #7f9ca2;
  --primary: #03fffe;
  --primary-strong: #00e5e4;
  --on-primary: #012a30;
  --accent: #2fe7e6;
  --brand-apps: #7ed9de;
  --border: rgba(160, 230, 235, 0.10);
  --border-strong: rgba(160, 230, 235, 0.18);
  --input-bg: #022a32;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.55);
  --shadow-primary: 0 8px 28px -6px rgba(3, 255, 254, 0.45);
  --grid-line: rgba(130, 220, 225, 0.05);
  --glow-1: rgba(3, 160, 170, 0.32);
  --glow-2: rgba(3, 120, 130, 0.30);
  --cta-from: #0b4d55;
  --cta-to: #03343c;
  --logo-card: transparent;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f5f6f8;
  --bg-alt: #edf2f5;
  --bg-header: rgba(245, 246, 248, 0.85);
  --surface: #ffffff;
  --surface-2: #f7f9fa;
  --surface-hover: #f2f8f9;
  --icon-bg: #d3ecee;
  --text: #1c2226;
  --text-muted: #56636b;
  --text-soft: #7a868d;
  --primary: #0b7d87;
  --primary-strong: #096a73;
  --on-primary: #ffffff;
  --accent: #0b7d87;
  --brand-apps: #0b7d87;
  --border: #e2e8ec;
  --border-strong: #d3dbe0;
  --input-bg: #f5f7f8;
  --shadow: 0 10px 30px -14px rgba(16, 52, 60, 0.18);
  --shadow-primary: 0 10px 24px -8px rgba(11, 125, 135, 0.45);
  --grid-line: rgba(11, 90, 100, 0.045);
  --glow-1: rgba(120, 190, 200, 0.28);
  --glow-2: rgba(150, 205, 212, 0.30);
  --cta-from: #ffffff;
  --cta-to: #e6f1f3;
  --logo-card: transparent;
}

/* Sin JavaScript: respetar la preferencia del sistema */
@media (prefers-color-scheme: light) {
  :root:not([data-theme]) {
    color-scheme: light;
    --bg: #f5f6f8; --bg-alt: #edf2f5; --bg-header: rgba(245,246,248,.85);
    --surface: #fff; --surface-2: #f7f9fa; --surface-hover: #f2f8f9; --icon-bg: #d3ecee;
    --text: #1c2226; --text-muted: #56636b; --text-soft: #7a868d;
    --primary: #0b7d87; --primary-strong: #096a73; --on-primary: #fff; --accent: #0b7d87; --brand-apps: #0b7d87;
    --border: #e2e8ec; --border-strong: #d3dbe0; --input-bg: #f5f7f8;
    --shadow: 0 10px 30px -14px rgba(16,52,60,.18); --shadow-primary: 0 10px 24px -8px rgba(11,125,135,.45);
    --grid-line: rgba(11,90,100,.045); --glow-1: rgba(120,190,200,.28); --glow-2: rgba(150,205,212,.30);
    --cta-from: #fff; --cta-to: #e6f1f3; --logo-card: transparent;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color .25s ease, color .25s ease;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 {
  font-family: "Sora", "Manrope", system-ui, sans-serif;
  line-height: 1.12;
  letter-spacing: -0.025em;
  margin: 0;
  font-weight: 700;
}
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 6px; }
.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-link { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--primary); color: var(--on-primary); padding: 10px 16px; border-radius: 10px; font-weight: 700; }
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.icon { width: 1em; height: 1em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg-header);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 24px; }
.brand { font-family: "Sora", sans-serif; font-weight: 700; font-size: 1.15rem; letter-spacing: -0.02em; }
.brand span { color: var(--brand-apps); }
.nav-links { display: flex; gap: 28px; }
.nav-links a { font-size: .92rem; font-weight: 500; color: var(--text-muted); transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-links a[aria-current="page"] { color: var(--accent); }
.header-actions { display: flex; align-items: center; gap: 14px; }
.lang-switch { display: flex; border: 1px solid var(--border-strong); border-radius: 999px; padding: 3px; gap: 2px; }
.lang-switch a { font-size: .74rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; color: var(--text-muted); letter-spacing: .02em; }
.lang-switch a[aria-current="true"] { background: var(--primary); color: var(--on-primary); }
.lang-switch a:not([aria-current="true"]):hover { color: var(--text); }
.icon-btn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; border: 0; background: transparent; cursor: pointer; color: var(--text); font-size: 18px; }
.icon-btn:hover { background: var(--surface-hover); }
.theme-toggle .i-moon { display: none; }
:root[data-theme="light"] .theme-toggle .i-sun { display: none; }
:root[data-theme="light"] .theme-toggle .i-moon { display: block; }
.menu-toggle { display: none; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 10px; font-weight: 700; font-size: .95rem;
  border: 1px solid transparent; cursor: pointer; transition: transform .15s ease, background-color .2s, box-shadow .2s, border-color .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--primary); color: var(--on-primary); box-shadow: var(--shadow-primary); }
.btn-primary:hover { background: var(--primary-strong); }
.btn-ghost { background: var(--surface-2); border-color: var(--border-strong); color: var(--text); }
.btn-ghost:hover { background: var(--surface-hover); border-color: var(--primary); box-shadow: 0 0 18px -4px color-mix(in srgb, var(--primary) 45%, transparent); }
.btn-block { width: 100%; padding: 15px 22px; font-size: 1.05rem; }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-weight: 700; font-size: .92rem; }
.link-arrow .icon { transition: transform .2s; }
.link-arrow:hover .icon { transform: translateX(3px); }

/* ---------- Secciones ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.eyebrow { display: block; font-size: .75rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head h2 { font-size: clamp(1.8rem, 3.4vw, 2.45rem); }
.section-head p { margin-top: 14px; color: var(--text-muted); }
.section-foot { text-align: center; margin-top: 40px; }

/* Fondo de héroe: rejilla + resplandor */
.hero-bg { position: relative; overflow: hidden; isolation: isolate; }
.hero-bg::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, #000 55%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent);
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0; z-index: -3;
  background:
    radial-gradient(60% 55% at 92% 0%, var(--glow-1), transparent 70%),
    radial-gradient(40% 45% at 0% 100%, var(--glow-2), transparent 70%);
}

/* Fondo animado (assets/js/hero-fx.js): red de nodos sobre el resplandor CSS */
.hero-fx { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; display: block; pointer-events: none; opacity: 0; transition: opacity 1.2s ease; }
.hero-bg.has-fx .hero-fx { opacity: 1; }

/* ---------- Héroe inicio ---------- */
.hero { padding: 88px 0 72px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.badge {
  display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 700;
  color: var(--accent); background: color-mix(in srgb, var(--primary) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent); padding: 5px 12px; border-radius: 999px;
}
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 20%, transparent); }
.hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.1rem); margin: 22px 0 22px; letter-spacing: -0.035em; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { color: var(--text-muted); font-size: 1.06rem; max-width: 560px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 32px; }
.hero-logo { justify-self: center; width: 100%; max-width: 380px; aspect-ratio: 1; display: grid; place-items: center; border-radius: 18px; background: var(--logo-card); padding: 16px; }
.hero-logo img { width: 100%; height: auto; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 72px; }
.stat { text-align: center; padding: 22px 16px; border-radius: 14px; background: color-mix(in srgb, var(--surface) 70%, transparent); border: 1px solid var(--border); }
.stat strong { display: block; font-family: "Sora", sans-serif; font-size: 2rem; line-height: 1.1; color: var(--accent); }
.stat span { font-size: .85rem; color: var(--text-muted); }

/* ---------- Héroe páginas internas ---------- */
.page-hero { padding: 96px 0 112px; text-align: center; }
.page-hero h1 { font-size: clamp(2.3rem, 5.4vw, 3.9rem); max-width: 860px; margin: 0 auto; letter-spacing: -0.035em; }
.page-hero p { color: var(--text-muted); font-size: 1.1rem; max-width: 640px; margin: 22px auto 0; }

/* ---------- Tarjetas ---------- */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  box-shadow: var(--shadow); transition: transform .2s ease, border-color .2s ease, box-shadow .25s ease;
}
.card:hover {
  border-color: color-mix(in srgb, var(--primary) 70%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--primary) 25%, transparent),
              0 8px 32px -6px color-mix(in srgb, var(--primary) 35%, transparent);
}
.icon-chip { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--icon-bg); color: var(--accent); font-size: 18px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.service-card { padding: 26px; }
.service-card h3 { font-size: 1.05rem; margin: 18px 0 10px; }
.service-card p { font-size: .9rem; color: var(--text-muted); }
.service-card.lg { padding: 32px; }
.service-card.lg h3 { font-size: 1.35rem; margin-top: 20px; }
.service-card.lg p { font-size: .98rem; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: .76rem; font-weight: 600; color: var(--text-muted); padding: 4px 11px; border: 1px solid var(--border-strong); border-radius: 999px; background: var(--surface-2); }
.tag .icon { color: var(--accent); font-size: 12px; stroke-width: 3; }

/* Productos */
.product-card { overflow: hidden; display: flex; flex-direction: column; }
.product-card:hover { transform: translateY(-3px); }
.product-media { aspect-ratio: 16 / 10; background: var(--media-bg, var(--surface-2)); overflow: hidden; display: grid; place-items: center; }
.product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.product-media.contain img { object-fit: contain; height: auto; }
.product-card:hover .product-media img { transform: scale(1.03); }
.product-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.product-cat { font-size: .7rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.product-body h3 { font-size: 1.3rem; margin: 6px 0 8px; letter-spacing: -0.01em; }
.product-body p { font-size: .88rem; color: var(--text-muted); flex: 1; }
.product-body .link-arrow { margin-top: 16px; }
.products-lg .product-body { padding: 24px 26px 28px; }
.products-lg .product-body h3 { font-size: 1.55rem; }
.products-lg .product-body p { font-size: .95rem; }

/* Detalle de proyecto */
.case-hero { padding: 72px 0 88px; }
.case-hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.case-hero-grid > * { min-width: 0; }
.case-back { display: inline-flex; align-items: center; gap: 6px; font-size: .9rem; color: var(--text-muted); margin-bottom: 18px; }
.case-back:hover { color: var(--accent); }
.case-hero h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); letter-spacing: -0.035em; line-height: 1.02; }
.case-tagline { font-size: clamp(1.1rem, 2vw, 1.3rem); font-weight: 600; margin-top: 16px; }
.case-desc { color: var(--text-muted); margin-top: 14px; max-width: 560px; }
.case-for { font-size: .92rem; margin-top: 14px; }
.case-hero .hero-actions { margin-top: 28px; }
.case-media { border-radius: 20px; overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow); background: var(--surface-2); aspect-ratio: 16 / 10; display: grid; place-items: center; }
.case-media img { width: 100%; height: 100%; object-fit: cover; }
.case-media.contain { background: #0f172a; padding: 8%; }
.case-media.contain img { height: auto; object-fit: contain; }
.case-highlights { padding: 48px 0 0; }
.highlights { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.highlights li { display: flex; align-items: center; gap: 12px; padding: 14px 18px; font-size: .9rem; font-weight: 600; line-height: 1.35; }
.highlights .icon { color: var(--accent); font-size: 20px; flex-shrink: 0; }
.case-title { font-size: clamp(1.7rem, 3vw, 2.2rem); margin-bottom: 32px; }
.case-feature { padding: 26px 28px; }
.case-feature h3 { font-size: 1.1rem; letter-spacing: -0.01em; margin-bottom: 12px; }
.case-feature ul { display: grid; gap: 8px; }
.case-feature li { position: relative; padding-left: 16px; font-size: .9rem; color: var(--text-muted); }
.case-feature li::before { content: ""; position: absolute; left: 0; top: .62em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.case-others { padding-top: 0; }

/* Por qué */
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.why-grid h2 { font-size: clamp(1.8rem, 3.2vw, 2.35rem); }
.why-grid .why-text > p { color: var(--text-muted); margin-top: 18px; }
.checklist { margin-top: 22px; display: grid; gap: 10px; }
.checklist li { display: flex; gap: 10px; align-items: center; font-size: .95rem; }
.checklist .icon { color: var(--accent); font-size: 18px; }
.feature-list { display: grid; gap: 14px; }
.feature { display: flex; gap: 16px; align-items: flex-start; padding: 18px 22px; }
.feature .icon { color: var(--accent); font-size: 20px; margin-top: 3px; }
.feature h3 { font-size: 1rem; letter-spacing: -0.01em; }
.feature p { font-size: .88rem; color: var(--text-muted); margin-top: 2px; }

/* Proceso */
.step { padding: 26px 24px; }
.step-num { font-family: "Sora", sans-serif; font-size: 2.2rem; font-weight: 800; color: var(--accent); line-height: 1; }
.step h3 { font-size: 1.1rem; margin: 14px 0 8px; }
.step p { font-size: .9rem; color: var(--text-muted); }

/* Industrias */
.industries { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.industry { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-radius: 12px; font-weight: 600; font-size: .95rem; box-shadow: none; }
.industry::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--primary); flex: none; }

/* Nosotros */
.bio { display: grid; grid-template-columns: 380px 1fr; gap: 72px; align-items: center; }
.bio-photo { border-radius: 20px; overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--border); aspect-ratio: 1; }
.bio-photo img { width: 100%; height: 100%; object-fit: cover; }
.bio h2 { font-size: clamp(1.7rem, 3vw, 2.2rem); margin-bottom: 18px; }
.bio p { color: var(--text-muted); margin-top: 14px; }

.timeline { max-width: 760px; margin: 0 auto; position: relative; padding-left: 36px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: color-mix(in srgb, var(--primary) 35%, transparent); border-radius: 2px; }
.timeline li { position: relative; padding-bottom: 30px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -34px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 22%, transparent); }
.tl-date { font-size: .78rem; font-weight: 800; letter-spacing: .1em; color: var(--accent); }
.timeline h3 { font-size: 1.2rem; margin: 4px 0 4px; letter-spacing: -0.01em; }
.timeline p { color: var(--text-muted); font-size: .92rem; }

.value { text-align: center; padding: 28px 22px; }
.value h3 { color: var(--accent); font-size: 1.25rem; }
.value p { color: var(--text-muted); font-size: .9rem; margin-top: 8px; }

/* CTA */
.cta {
  position: relative; overflow: hidden; text-align: center; padding: 64px 32px; border-radius: 24px;
  background: linear-gradient(135deg, var(--cta-from), var(--cta-to)); border: 1px solid var(--border); box-shadow: var(--shadow);
  max-width: 960px; margin: 0 auto;
}
.cta h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); max-width: 640px; margin: 0 auto; }
.cta p { color: var(--text-muted); max-width: 560px; margin: 18px auto 0; }
.cta .hero-actions { justify-content: center; }

/* Contacto */
.contact-grid { display: grid; grid-template-columns: 0.72fr 1fr; gap: 40px; align-items: start; }
.contact-cards { display: grid; gap: 18px; }
.contact-card { display: flex; align-items: center; gap: 18px; padding: 22px 24px; }
.contact-card:hover { transform: translateY(-2px); }
.contact-card .icon-chip { width: 48px; height: 48px; font-size: 21px; border-radius: 12px; }
.contact-card strong { display: block; font-family: "Sora", sans-serif; font-size: 1.05rem; }
.contact-card span { color: var(--text-muted); font-size: .95rem; word-break: break-word; }
.contact-note { color: var(--text-muted); margin-top: 22px; display: flex; gap: 8px; align-items: center; font-size: .95rem; }
.form-card { padding: 36px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label { display: block; margin-bottom: 6px; font-size: .88rem; font-weight: 600; color: var(--text-muted); }
.field input, .field select, .field textarea {
  width: 100%; background: var(--input-bg); border: 1px solid var(--border-strong); border-radius: 12px;
  padding: 14px 16px; font-size: .98rem; transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--text-soft); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 22%, transparent); }
.form-hint { font-size: .8rem; color: var(--text-soft); margin-top: 12px; text-align: center; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; padding: 56px 0 48px; }
.footer-grid p { color: var(--text-muted); font-size: .92rem; margin-top: 14px; max-width: 340px; }
.footer-grid ul { display: grid; gap: 10px; }
.footer-grid a { color: var(--text-muted); font-size: .92rem; display: inline-flex; gap: 10px; align-items: center; }
.footer-grid a:hover { color: var(--accent); }
.footer-grid a.brand { display: inline; color: var(--text); font-size: 1.15rem; }
.footer-grid a.brand:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid var(--border); padding: 22px 0; text-align: center; font-size: .82rem; color: var(--text-soft); }
.footer-bottom a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.footer-bottom a:hover { color: var(--primary); }

/* Utilidades (reemplazan estilos inline para permitir una CSP estricta) */
.media-navy { --media-bg: #0f172a; }
.list-plain { list-style: none; margin: 0; padding: 0; }
.page-404 { min-height: 100vh; display: grid; place-items: center; text-align: center; }
.page-404 .brand { display: flex; justify-content: center; }
.page-404 .eyebrow { margin-top: 40px; }
.page-404 .hero-actions { justify-content: center; }

/* Texto legal */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.25rem; margin: 32px 0 10px; }
.prose h2:first-child { margin-top: 0; }
.prose p { color: var(--text-muted); line-height: 1.7; }
.prose a { color: var(--primary); }

/* Animación de entrada */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { transition-duration: 0s !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .bio { grid-template-columns: 300px 1fr; gap: 48px; }
}
@media (max-width: 880px) {
  .nav-links {
    position: fixed; inset: 64px 0 auto 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: 8px 24px 20px;
    transform: translateY(-8px); opacity: 0; visibility: hidden; transition: .2s ease;
  }
  .nav-links a { padding: 14px 0; font-size: 1.05rem; border-bottom: 1px solid var(--border); }
  .nav-open .nav-links { transform: none; opacity: 1; visibility: visible; }
  .menu-toggle { display: inline-grid; }
  .menu-toggle .i-x { display: none; }
  .nav-open .menu-toggle .i-x { display: block; }
  .nav-open .menu-toggle .i-menu { display: none; }
  .hero-grid, .why-grid, .contact-grid, .bio, .case-hero-grid { grid-template-columns: 1fr; }
  .case-hero-grid { gap: 36px; }
  .highlights { grid-template-columns: repeat(2, 1fr); }
  .hero-logo { max-width: 300px; order: -1; padding: 12px; }
  .grid-3, .industries { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
  .bio-photo { max-width: 360px; }
}
@media (max-width: 620px) {
  .container { padding: 0 18px; }
  .section { padding: 72px 0; }
  .hero { padding: 48px 0 56px; }
  .hero-logo { max-width: 180px; padding: 8px; border-radius: 14px; }
  .page-hero { padding: 64px 0 72px; }
  .grid-2, .grid-3, .grid-4, .industries, .stats, .form-row, .highlights { grid-template-columns: 1fr; }
  .case-hero { padding: 40px 0 56px; }
  .stats { margin-top: 48px; gap: 12px; }
  .hero-actions .btn { flex: 1 1 auto; }
  .cta { padding: 48px 22px; border-radius: 20px; }
  .form-card { padding: 24px 20px; }
  .footer-grid { grid-template-columns: 1fr; }
  .header-actions { gap: 6px; }
}

/* ---------- Logo (versión clara/oscura según tema) ---------- */
.brand img { height: 36px; width: auto; display: block; }
.footer-grid a.brand { display: inline-block; }
.brand-light, .brand img.brand-light, .hero-logo img.brand-light { display: none; }
:root[data-theme="light"] .brand-dark, :root[data-theme="light"] .brand img.brand-dark { display: none; }
:root[data-theme="light"] .brand-light { display: block; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme]) .brand-dark, :root:not([data-theme]) .brand img.brand-dark { display: none; }
  :root:not([data-theme]) .brand-light { display: block; }
}
