:root {
  color-scheme: light;
  --ink: #161616;
  --muted: #4a4a4a;
  --sand: #f4efe7;
  --stone: #e1d7c7;
  --clay: #c9b79f;
  --accent: #ef6b4b;
  --deep: #1f3c3b;
  --highlight: #ffd7b5;
  --radius-lg: 28px;
  --radius-md: 18px;
  --shadow: 0 30px 60px rgba(22, 22, 22, 0.12);
  --shadow-soft: 0 20px 45px rgba(31, 60, 59, 0.15);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

section[id] {
  scroll-margin-top: 160px;
}

body {
  font-family: "Archivo", "Segoe UI", sans-serif;
  background: linear-gradient(140deg, #f8f2ea 0%, #f5ede3 42%, #efe6da 100%);
  color: var(--ink);
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

main {
  display: flex;
  flex-direction: column;
  gap: 120px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #0b1030;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 32px;
  gap: 24px;
}

.logo {
  font-family: "IBM Plex Serif", serif;
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-left: -40px;
}

.logo img {
  height: 52px;
  width: auto;
  display: block;
  transform: scale(4);
  transform-origin: left center;
  max-width: 260px;
}

.nav-links {
  display: flex;
  gap: 18px;
  font-size: 0.95rem;
  color: #f7f7ff;
}

.nav-links a {
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: #ffd166;
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-cta {
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #f7f7ff;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.nav-cta:hover {
  background: #ffd166;
  color: #0b1030;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(31, 60, 59, 0.2);
  background: #fff;
  align-items: center;
  justify-content: center;
  gap: 6px;
  cursor: pointer;
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  background: var(--deep);
  display: block;
}

.intro {
  position: relative;
  padding: 80px 24px;
  color: #f7f7ff;
  background: #0b1030;
  overflow: hidden;
}

.intro-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.intro-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(11, 16, 48, 0.9), rgba(11, 16, 48, 0.55));
  z-index: 1;
}

.intro-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
}

.intro-content h1 {
  font-family: "IBM Plex Serif", serif;
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  line-height: 1.1;
  margin-bottom: 16px;
}

.lead {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 18px;
}

.intro .lead {
  color: rgba(247, 247, 255, 0.78);
}

.intro-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.intro-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.intro-metrics h3 {
  font-size: 1.05rem;
}

.intro-metrics p {
  color: rgba(247, 247, 255, 0.7);
  font-size: 0.85rem;
}

.intro-media {
  display: flex;
  justify-content: center;
  align-items: center;
}

.intro-carousel {
  position: relative;
  width: min(106%, 554px);
  aspect-ratio: 4 / 3;
}

.intro-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.6s ease;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.3));
  animation: float 7s ease-in-out infinite;
}

.intro-slide.erp-slide {
  border-radius: 24px;
  box-shadow: 0 0 28px rgba(255, 209, 102, 0.35), 0 0 60px rgba(255, 255, 255, 0.15);
}

.intro-slide.medida-slide {
  border-radius: 24px;
}

.intro-slide.is-active {
  opacity: 1;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 0.65rem;
  color: #ffd166;
  margin-bottom: 12px;
  font-weight: 600;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
}

.btn.primary {
  background: #ffd166;
  color: #0b1030;
  box-shadow: var(--shadow-soft);
}

.btn.ghost {
  border-color: rgba(255, 255, 255, 0.4);
  color: #f7f7ff;
  background: transparent;
}

.media-slot {
  width: 100%;
  min-height: 150px;
  border-radius: var(--radius-lg);
  border: 1px dashed rgba(31, 60, 59, 0.4);
  background: linear-gradient(135deg, #fff 0%, #f9f3eb 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  padding: 24px;
  color: var(--muted);
  box-shadow: var(--shadow);
}

.media-slot.image {
  border: none;
  background: transparent;
  padding: 0;
}

.media-slot.image img {
  width: 100%;
  height: 100%;
  min-height: 120px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  box-shadow: 0 28px 55px rgba(11, 16, 48, 0.25);
  transform: translateY(-6px);
  animation: float 7s ease-in-out infinite;
}

.media-slot.image.image-small img {
  min-height: 50px;
}

.media-slot span {
  font-weight: 600;
  color: var(--deep);
}

.media-slot small {
  font-size: 0.85rem;
}

.section {
  padding: 0 32px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  max-width: 680px;
  margin-bottom: 48px;
}

.section-header h2 {
  font-family: "IBM Plex Serif", serif;
  font-size: clamp(2rem, 3.4vw, 3rem);
  margin-bottom: 12px;
}

.section-header p {
  color: var(--muted);
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.about-card {
  padding: 24px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
}

.services {
  position: relative;
}

.services-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 28px;
}

.service-item {
  text-align: center;
}

.service-item h3 {
  margin-top: 36px;
}

.service-icon {
  width: clamp(130px, 14vw, 170px);
  height: clamp(130px, 14vw, 170px);
  margin: 0;
  object-fit: contain;
  margin-left: auto;
  margin-right: auto;
}

.service-icon-wrap {
  display: flex;
  justify-content: center;
  margin: -32px auto 12px;
}

.float-y {
  animation: float 6s ease-in-out infinite;
}

.service-icon--scaled {
  transform: translateY(-10px) scale(1.6);
  transform-origin: center top;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 22px;
}

.project-card {
  display: grid;
  gap: 16px;
  padding: 24px;
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow);
}

.project-card--text {
  align-content: start;
}

.project-card--text p {
  color: var(--muted);
}

.project-card img {
  width: 100%;
  height: 200px;
  border-radius: 16px;
  object-fit: cover;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.project-card img.image-contain {
  object-fit: contain;
  background: #f5f5f5;
}

.project-card:hover img {
  transform: scale(2);
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.18);
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 18px;
}

.step {
  padding: 20px;
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow);
}

.step span {
  font-weight: 700;
  color: var(--accent);
}

.contact {
  background: linear-gradient(120deg, #fff 0%, #f5efe7 100%);
  border-radius: var(--radius-lg);
  padding: 48px 28px;
  box-shadow: var(--shadow);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  align-items: start;
}

.contact-form {
  display: grid;
  gap: 12px;
}

.form-status {
  min-height: 20px;
  font-size: 0.95rem;
  color: var(--muted);
}

.form-status[data-state="success"] {
  color: #0f766e;
}

.form-status[data-state="error"] {
  color: #b91c1c;
}

.btn.is-loading {
  opacity: 0.7;
  pointer-events: none;
}

.contact-form label {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}

.field-error {
  min-height: 16px;
  font-size: 0.85rem;
  color: #ffd166;
}

.contact-form input,
.contact-form textarea {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(31, 60, 59, 0.2);
  font-family: inherit;
}

.contact-form input.has-error,
.contact-form textarea.has-error {
  border-color: #ffd166;
  box-shadow: 0 0 0 2px rgba(255, 209, 102, 0.2);
}

.contact-panel {
  display: grid;
  gap: 12px;
}

.panel-item {
  padding: 14px;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(31, 60, 59, 0.1);
}

.privacy {
  padding-bottom: 120px;
}

.privacy-card {
  padding: 26px;
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow);
  max-width: 720px;
}

.footer {
  text-align: center;
  padding: 32px 24px 48px;
  color: var(--muted);
  font-size: 0.9rem;
}

.whatsapp-float {
  position: fixed;
  right: max(0px, env(safe-area-inset-right));
  bottom: 22px;
  width: 192px;
  height: 192px;
  border-radius: 16px;
  background: transparent;
  color: inherit;
  display: grid;
  place-items: center;
  box-shadow: none;
  z-index: 20;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-float:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: none;
}

.whatsapp-float img {
  width: 144px;
  height: 144px;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.2));
  animation: shake 3s infinite;
}

.robo-teaser {
  position: fixed;
  left: -139px;
  bottom: 120px;
  z-index: 30;
  transform: translateX(-120%);
  opacity: 0;
  transition: transform 0.6s ease, opacity 0.6s ease;
  pointer-events: auto;
}

.robo-teaser.is-visible {
  transform: translateX(0);
  opacity: 1;
}

.robo-teaser a {
  display: block;
}

.robo-teaser img {
  width: 462px;
  height: auto;
  display: block;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.25));
}

.robo-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 0;
  background: rgba(15, 23, 42, 0.8);
  color: #fff;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 960px) {
  .nav {
    align-items: center;
  }

  .nav-toggle {
    display: grid;
  }

  .nav-cta {
    display: none;
  }

  .nav-links {
    position: absolute;
    top: 72px;
    right: 32px;
    flex-direction: column;
    gap: 12px;
    padding: 18px;
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
  }

  .nav-links.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .intro-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  .intro-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .intro-media {
    order: 2;
  }

  .intro-carousel {
    width: min(119%, 449px);
  }

  .services-list {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  .process-steps {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 720px) {
  section[id] {
    scroll-margin-top: 110px;
  }

  .intro {
    padding: 36px 16px 28px;
  }

  .intro-inner {
    align-items: start;
  }

  .intro-content h1 {
    font-size: clamp(1.8rem, 8vw, 2.4rem);
  }

  .intro-actions {
    align-items: stretch;
  }

  .intro-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .intro-metrics h3 {
    font-size: 1rem;
  }

  .intro-metrics p {
    font-size: 0.8rem;
  }

  .intro-carousel {
    width: min(90%, 260px);
  }

  .services-list {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .service-icon {
    margin: 0;
  }

  .service-icon--scaled {
    transform: none;
    width: 230px;
    height: 230px;
    margin: 0;
  }

.service-icon--boost {
  width: 303px;
  height: 303px;
}

  .service-icon-wrap {
    margin: 0 auto 12px;
  }


  .process-steps {
    grid-template-columns: 1fr;
  }

  .site-header {
    position: sticky;
    background: #0b1030;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav {
    padding: 16px 20px;
  }

  .logo {
    color: #f7f7ff;
    margin-left: -12px;
  }

  .logo img {
    height: 42px;
    transform: scale(2.4);
    max-width: 200px;
  }

  .nav-toggle {
    border-color: rgba(255, 255, 255, 0.35);
    background: transparent;
  }

  .nav-toggle span {
    background: #f7f7ff;
  }

  .nav-links {
    left: 20px;
    right: 20px;
    background: #0f163b;
    color: #f7f7ff;
    border: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav-links a {
    color: inherit;
  }


  .contact {
    padding: 36px 20px;
  }

  .contact-grid {
    gap: 16px;
  }

  .contact-form {
    gap: 10px;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 9px 10px;
  }


  main {
    gap: 80px;
  }

  .whatsapp-float {
    width: 174px;
    height: 174px;
    right: max(0px, env(safe-area-inset-right));
    bottom: 16px;
  }

  .whatsapp-float img {
    width: 132px;
    height: 132px;
  }

  .robo-teaser {
    left: -130px;
    bottom: 140px;
  }

  .robo-teaser img {
    width: 432px;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(-6px);
  }
  50% {
    transform: translateY(6px);
  }
}

@keyframes shake {
  0%,
  88%,
  100% {
    transform: translateX(0);
  }
  90% {
    transform: translateX(-5px);
  }
  92% {
    transform: translateX(5px);
  }
  94% {
    transform: translateX(-4px);
  }
  96% {
    transform: translateX(4px);
  }
  98% {
    transform: translateX(0);
  }
}


@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
