/* ===== Arkhe Consulting — sistema de diseño (estética Linear, acento de marca) ===== */

:root {
  /* superficies — grafito metálico (gris azulado frío, medio-oscuro) */
  --bg: #14161c;
  --panel: #181b21;
  --surface: #1e2128;
  --surface-2: #282c34;
  /* texto */
  --text-1: #f7f8f8;
  --text-2: #d0d6e0;
  --text-3: #9aa0a8;
  --text-4: #62666d;
  /* acento de marca (naranja Arkhé — único color cromático del sistema) */
  --accent: #f29000;
  --accent-hover: #ffab26;
  /* bordes */
  --border-subtle: rgba(255,255,255,0.07);
  --border: rgba(255,255,255,0.10);
  --border-solid: #2a2e37;
  /* tipografía */
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  font-feature-settings: "cv01", "ss03";
  background-color: #14161c;
  color: var(--text-1);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Fondo metálico con rejilla técnica — fijo, detrás de todo el contenido.
   Gradiente grafito + brillo superior (efecto metal) + retícula fina. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 95% 60% at 50% -10%, rgba(255,255,255,0.055), transparent 62%),
    linear-gradient(180deg, #1b1e26 0%, #14161c 55%, #0f1116 100%),
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: auto, auto, 52px 52px, 52px 52px;
}

/* Placa de circuito (PCB) naranja — <img> anclada al inicio de la página.
   Viaja con TODO el contenido (hero→servicios→método→stack); el JS la extiende
   hasta el final de #stack, así nunca llega a Contacto. */
.pcb-overlay {
  position: absolute;
  top: 0;
  right: 0;
  width: min(44vw, 600px);
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  object-fit: fill;
  opacity: 0.5;
  mask-image: linear-gradient(to left, black 50%, transparent 100%);
  -webkit-mask-image: linear-gradient(to left, black 50%, transparent 100%);
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { width: min(1160px, 92%); margin: 0 auto; }

/* acento para la palabra dinámica */
.accent { color: var(--accent); }
.cursor { color: var(--accent); font-weight: 400; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* ===== KICKER (label técnico mono) ===== */
.kicker {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

/* ===== BOTONES ===== */
.btn {
  display: inline-block;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  padding: 10px 20px;
  border-radius: 6px;
  border: 1px solid transparent;
  transition: background .2s, border-color .2s, transform .15s;
  cursor: pointer;
}
.btn-primary {
  background: var(--accent);
  color: #14140c;
  font-weight: 600;
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-ghost {
  background: rgba(255,255,255,0.02);
  border-color: rgb(36,40,44);
  color: var(--text-2);
}
.btn-ghost:hover { background: rgba(255,255,255,0.05); border-color: var(--border); color: var(--text-1); }
.btn-sm { padding: 7px 16px; font-size: 13px; }
.btn-block { width: 100%; text-align: center; }

/* ===== NAV ===== */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 24px 0;
  transition: background .3s, padding .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(20,22,28,0.85);
  border-bottom-color: var(--border-subtle);
  padding: 10px 0;
}
.nav.scrolled .brand-logo { height: 72px; }
.nav-inner { display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo { height: 240px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links > a:not(.btn) {
  font-size: 14px; font-weight: 500; color: var(--text-2);
  transition: color .2s;
}
.nav-links > a:not(.btn):hover { color: var(--text-1); }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 6px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text-1); margin: 5px 0; transition: .3s; border-radius: 1px; }

/* ===== HERO ===== */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; padding: 360px 0 90px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; }
.grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 45%, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 45%, black 20%, transparent 70%);
}
.hero-grid {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: 1.2fr 0.8fr;
  gap: 60px; align-items: center;
}
.hero h1 {
  font-size: clamp(2.6rem, 5.4vw, 4.2rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -1.8px;
  color: var(--text-1);
  margin-bottom: 24px;
}
.hero-sub {
  font-size: 18px; font-weight: 400; line-height: 1.65;
  color: var(--text-3);
  max-width: 540px;
  margin-bottom: 36px;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-visual { display: flex; align-items: center; justify-content: center; }
.logo-frame {
  width: min(620px, 100%);
  aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  box-shadow: rgba(0,0,0,0.2) 0px 0px 0px 1px, rgba(0,0,0,0.4) 0px 24px 48px -16px;
  transition: border-color .3s;
}
.logo-frame:hover { border-color: rgba(242,144,0,0.35); }
.hero-video {
  width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
}
.video-wrap { position: relative; width: 100%; }
.logo-overlay {
  position: absolute;
  left: 88.6%;
  top: 82.8%;
  width: 10%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  opacity: 1;
}

/* ===== SECCIONES ===== */
.section { padding: 120px 0; position: relative; }
.section-alt {
  background: rgba(255,255,255,0.02);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.section-head { max-width: 640px; margin-bottom: 64px; }
.section-head h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  font-weight: 500;
  letter-spacing: -1.1px;
  line-height: 1.1;
  margin-bottom: 16px;
}
.section-sub { font-size: 17px; color: var(--text-3); line-height: 1.65; max-width: 540px; }

/* ===== LISTA DE SERVICIOS (editorial, sin cards genéricas) ===== */
.services-list { display: flex; flex-direction: column; }
.service {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 28px;
  padding: 36px 8px;
  border-bottom: 1px solid var(--border-subtle);
  transition: background .2s, padding-left .3s;
}
.service:first-child { border-top: 1px solid var(--border-subtle); }
.service:hover { background: rgba(255,255,255,0.015); padding-left: 20px; }
.service-num {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-4);
  padding-top: 8px;
}
.service-body h3 {
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.24px;
  color: var(--text-1);
  margin-bottom: 8px;
}
.service-body p { font-size: 16px; color: var(--text-3); line-height: 1.65; max-width: 660px; }

/* ===== PASOS MÉTODO ===== */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.step {
  padding: 28px;
  border-radius: 8px;
  background: rgba(255,255,255,0.045);
  border: 1px solid var(--border-subtle);
  transition: background .2s, border-color .2s;
}
.step:hover { background: rgba(255,255,255,0.06); border-color: var(--border); }
.step-num {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--accent);
  display: block;
  margin-bottom: 20px;
}
.step h3 { font-size: 17px; font-weight: 500; letter-spacing: -0.2px; margin-bottom: 8px; }
.step p { font-size: 15px; color: var(--text-3); line-height: 1.65; }

/* ===== STACK ===== */
.chips { display: flex; flex-wrap: wrap; gap: 10px; max-width: 760px; }
.chip-tech {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  padding: 8px 14px;
  border-radius: 6px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  transition: border-color .2s, color .2s, background .2s;
}
.chip-tech:hover { border-color: rgba(242,144,0,0.4); color: var(--text-1); background: rgba(242,144,0,0.04); }

/* ===== CONTACTO ===== */
.contact-section { position: relative; overflow: hidden; }
.contacto-glow {
  position: absolute;
  width: 560px; height: 560px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242,144,0,0.16) 0%, rgba(242,144,0,0.05) 45%, transparent 70%);
  top: 20%; right: -140px;
  pointer-events: none;
  filter: blur(40px);
  animation: float 10s ease-in-out infinite;
}
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; position: relative; z-index: 1; }
.contact-info h2 {
  font-size: clamp(1.9rem, 3.2vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -1.1px;
  line-height: 1.1;
  margin-bottom: 16px;
}
.contact-info .section-sub { margin-bottom: 28px; }
.contact-lines { display: flex; flex-direction: column; gap: 8px; margin-bottom: 28px; }
.contact-lines a {
  font-size: 15px; font-weight: 500; color: var(--text-2);
  border-bottom: 1px solid transparent;
  transition: color .2s, border-color .2s;
}
.contact-lines a:hover { color: var(--accent); border-color: rgba(242,144,0,0.4); }
.next-steps { margin-bottom: 30px; padding-top: 22px; border-top: 1px solid var(--border-subtle); }
.next-steps-title {
  font-family: var(--mono);
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-4);
  margin-bottom: 16px;
}
.next-step { display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-items: baseline; margin-bottom: 12px; }
.next-step-num { font-family: var(--mono); font-size: 12px; color: var(--accent); }
.next-step p { font-size: 14px; color: var(--text-3); line-height: 1.55; }
.next-step p strong { color: var(--text-1); font-weight: 500; }
.contact-logo { width: 360px; height: auto; opacity: 0.9; }
.contact-form {
  display: flex; flex-direction: column; gap: 18px;
  padding: 36px;
  border-radius: 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(242,144,0,0.25);
  box-shadow: rgba(0,0,0,0.2) 0px 0px 0px 1px, rgba(242,144,0,0.08) 0px 24px 60px -12px;
  transition: border-color .3s, box-shadow .3s;
}
.contact-form:hover {
  border-color: rgba(242,144,0,0.45);
  box-shadow: rgba(0,0,0,0.2) 0px 0px 0px 1px, rgba(242,144,0,0.14) 0px 24px 64px -12px;
}
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-size: 13px; font-weight: 500; color: var(--text-2); }
.field label .opt { color: var(--text-4); font-weight: 400; }
.field input, .field textarea {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 13px 14px;
  color: var(--text-2);
  font-family: var(--font);
  font-size: 15px;
  transition: border-color .2s, box-shadow .2s;
  resize: vertical;
}
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: rgba(0,0,0,0.1) 0px 4px 12px, rgba(242,144,0,0.2) 0px 0px 0px 3px;
}
.field input::placeholder, .field textarea::placeholder { color: var(--text-4); }
.btn-lg { padding: 15px 28px; font-size: 15px; font-weight: 600; }
.form-trust {
  font-size: 12.5px; color: var(--text-4); text-align: center;
  letter-spacing: 0.02em;
}
.form-msg { font-size: 13px; text-align: center; min-height: 1.2em; color: var(--text-3); }
.form-msg.ok { color: #27a644; }
.form-msg.err { color: #f87171; }

/* ===== FOOTER ===== */
.footer { padding: 64px 0 48px; border-top: 1px solid var(--border-subtle); }
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.footer-logo { height: 150px; width: auto; opacity: 0.85; }
.footer-tag { font-size: 14px; color: var(--text-3); }
.footer-copy { font-size: 12px; color: var(--text-4); }

/* ===== REVEAL ===== */
/* Por defecto TODO visible (aunque JS falle). Solo se ocultan
   los elementos cuando JS está activo (.js en <html>) */
.reveal { opacity: 1; transform: none; }
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.visible { opacity: 1; transform: none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; text-align: left; }
  .hero-visual { justify-content: flex-start; }
  .steps { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 48px; }
  .nav-links {
    position: fixed; top: 0; right: -100%; height: 100vh; width: min(320px, 80%);
    background: rgba(15,16,17,0.97);
    flex-direction: column; justify-content: center; gap: 28px; padding: 40px;
    transition: right .35s ease;
    border-left: 1px solid var(--border-subtle);
  }
  .nav-links.open { right: 0; }
  .nav-toggle { display: block; z-index: 110; }
}
@media (max-width: 640px) {
  .section { padding: 80px 0; }
  .service { grid-template-columns: 44px 1fr; gap: 16px; padding: 26px 4px; }
  .hero { padding-top: 260px; }
  .brand-logo { height: 170px; }
  .nav.scrolled .brand-logo { height: 60px; }
  .pcb-overlay { width: 80vw; opacity: 0.5; }
  .hero h1 { letter-spacing: -1.2px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}
