/* ============================================
   MEC SOLUCIONES — Design tokens
   ============================================ */
:root {
  --ink: #0b1523;
  --ink-soft: #3a4a5e;
  --paper: #ffffff;
  --paper-alt: #f4f7fa;
  --line: #e1e8ef;

  --brand: #0e6ba8;
  --brand-dark: #0a4d7a;
  --brand-light: #e8f2fa;
  --accent: #eb1c24;
  --accent-dark: #b3141b;

  --success: #1f9d55;

  --radius: 10px;
  --radius-lg: 18px;
  --shadow-sm: 0 1px 3px rgba(11, 21, 35, 0.08);
  --shadow-md: 0 8px 24px rgba(11, 21, 35, 0.10);
  --shadow-lg: 0 20px 48px rgba(11, 21, 35, 0.16);

  --container: 1180px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

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

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; }
p { margin: 0; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
  background: var(--brand-light);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.section {
  padding: 88px 0;
}
.section--alt { background: var(--paper-alt); }
.section--dark {
  background: linear-gradient(160deg, var(--ink) 0%, #142639 100%);
  color: #eef3f8;
}

.section-head {
  max-width: 640px;
  margin-bottom: 48px;
}
.section-head.center {
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.01em;
}
.section-head p {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: 1.05rem;
}
.section--dark .section-head p { color: #b9c6d4; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }

.btn--primary {
  background: var(--accent);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.btn--primary:hover { background: var(--accent-dark); box-shadow: var(--shadow-lg); }

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

.btn--outline {
  background: transparent;
  border-color: var(--brand);
  color: var(--brand);
}
.btn--outline:hover { background: var(--brand); color: #fff; }

.btn--sm { padding: 10px 20px; font-size: 0.85rem; }

/* ============================================
   Header / Nav
   ============================================ */
.topbar {
  background: var(--ink);
  color: #cfdbe6;
  font-size: 0.82rem;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  padding-bottom: 8px;
  flex-wrap: wrap;
  gap: 6px;
}
.topbar__contact { display: flex; gap: 20px; flex-wrap: wrap; }
.topbar__contact a { display: inline-flex; align-items: center; gap: 6px; color: #cfdbe6; }
.topbar__contact a:hover { color: #fff; }
.topbar__tag { color: #7f97ac; }

header.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.brand__logo {
  height: 40px;
  width: auto;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav__links a {
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink-soft);
  transition: background 0.15s ease, color 0.15s ease;
}
.nav__links a:hover { background: var(--brand-light); color: var(--brand-dark); }
.nav__links a.active { background: var(--brand); color: #fff; }

.nav__cta { display: flex; align-items: center; gap: 12px; }

.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
  transition: 0.2s;
}

/* ============================================
   Hero
   ============================================ */
.hero {
  position: relative;
  background-image: url("../assets/images/bg-para-mec.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(245, 166, 35, 0.16), transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(14, 107, 168, 0.35), transparent 45%),
    linear-gradient(160deg, rgba(11, 21, 35, 0.93) 0%, rgba(15, 40, 61, 0.90) 55%, rgba(10, 77, 122, 0.88) 100%);
  pointer-events: none;
}
.hero__grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  padding: 100px 0 80px;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 7px 16px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.2rem, 4.4vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.hero h1 span { color: var(--accent); }
.hero p.lead {
  margin-top: 20px;
  font-size: 1.12rem;
  color: #cdd9e4;
  max-width: 54ch;
}
.hero__actions {
  display: flex;
  gap: 14px;
  margin-top: 34px;
  flex-wrap: wrap;
}
.hero__stats {
  display: flex;
  gap: 36px;
  margin-top: 52px;
  flex-wrap: wrap;
}
.hero__stats div strong {
  display: block;
  font-size: 1.7rem;
  font-weight: 800;
  color: #fff;
}
.hero__stats div span {
  font-size: 0.82rem;
  color: #9fb2c4;
}

.hero__panel {
  position: relative;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: var(--radius-lg);
  padding: 28px;
  backdrop-filter: blur(6px);
}
.hero__panel h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 18px;
}
.hero__list { display: grid; gap: 12px; }
.hero__list li {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: 0.88rem;
  color: #dfe8f1;
}
.hero__list .ico {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  flex-shrink: 0;
  font-size: 0.8rem;
}

/* ============================================
   Service grid / cards
   ============================================ */
.grid {
  display: grid;
  gap: 24px;
}
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.card__icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--brand-light);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 18px;
}
.card h3 {
  font-size: 1.08rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.card p {
  color: var(--ink-soft);
  font-size: 0.94rem;
}

/* Service cards on services page — with numbering */
.svc-card {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  overflow: hidden;
}
.svc-card::before {
  content: attr(data-index);
  position: absolute;
  top: -6px;
  right: 6px;
  font-size: 3.6rem;
  font-weight: 900;
  color: var(--paper-alt);
  z-index: 0;
  line-height: 1;
}
.svc-card > * { position: relative; z-index: 1; }
.svc-card .card__icon { background: var(--brand); color: #fff; }
.svc-card:hover { border-color: var(--brand); box-shadow: var(--shadow-md); transform: translateY(-3px); transition: 0.18s ease; }

/* ============================================
   Work / projects
   ============================================ */
.work-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: 0.18s ease;
}
.work-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.work-card__top {
  height: 8px;
  background: linear-gradient(90deg, var(--brand), var(--accent));
}
.work-card__body { padding: 26px; }
.work-card__tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--brand);
  background: var(--brand-light);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.work-card h3 { font-size: 1.15rem; font-weight: 800; margin-bottom: 10px; }
.work-card p { color: var(--ink-soft); font-size: 0.94rem; }

/* ============================================
   Clients strip / logos
   ============================================ */
.logo-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
  align-items: center;
}
.logo-strip .logo-box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 96px;
  filter: grayscale(1);
  opacity: 0.75;
  transition: 0.2s ease;
}
.logo-strip .logo-box:hover { filter: grayscale(0); opacity: 1; box-shadow: var(--shadow-sm); }
.logo-strip img { max-height: 56px; width: auto; }

.client-list-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 40px;
}
.client-list-grid li {
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
  color: var(--ink-soft);
  font-size: 0.95rem;
  display: flex;
  gap: 10px;
}
.client-list-grid li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 8px;
  flex-shrink: 0;
}

/* ============================================
   Values / Mission (empresa page)
   ============================================ */
.value-card {
  background: var(--paper-alt);
  border-radius: var(--radius-lg);
  padding: 26px;
  border-left: 4px solid var(--brand);
}
.value-card h3 { font-size: 1.02rem; font-weight: 800; margin-bottom: 8px; color: var(--brand-dark); }
.value-card p { color: var(--ink-soft); font-size: 0.92rem; }

.pillar {
  display: flex;
  gap: 18px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.pillar:last-child { border-bottom: none; }
.pillar__num {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--brand);
  background: var(--brand-light);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.pillar h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 6px; }
.pillar p { color: var(--ink-soft); font-size: 0.94rem; }

/* ============================================
   Affiliate promos
   ============================================ */
.promo-card {
  background: linear-gradient(160deg, #fff 0%, var(--paper-alt) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  position: relative;
}
.promo-card__badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 8px 14px;
  border-radius: 999px;
}
.promo-card h3 { font-size: 1.1rem; font-weight: 800; margin: 6px 0 8px; padding-right: 90px; }
.promo-card p { color: var(--ink-soft); font-size: 0.92rem; }

/* ============================================
   Contact
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 40px;
}
.contact-info {
  background: var(--ink);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 36px;
}
.contact-info h3 { font-size: 1.2rem; font-weight: 800; margin-bottom: 22px; }
.contact-item {
  display: flex;
  gap: 14px;
  margin-bottom: 20px;
}
.contact-item .ico {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-item strong { display: block; font-size: 0.95rem; margin-bottom: 2px; }
.contact-item span, .contact-item a { color: #b9c6d4; font-size: 0.9rem; }
.contact-item a:hover { color: #fff; }

.contact-form {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 36px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--paper-alt);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--brand);
  background: #fff;
}
.map-embed {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  margin-top: 40px;
}
.map-embed iframe { width: 100%; height: 340px; border: 0; display: block; }

/* ============================================
   CTA band
   ============================================ */
.cta-band {
  background: linear-gradient(120deg, var(--brand-dark), var(--brand));
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-band h2 { font-size: 1.6rem; font-weight: 800; }
.cta-band p { color: #dcebf6; margin-top: 8px; }

/* ============================================
   Footer
   ============================================ */
footer.site-footer {
  background: var(--ink);
  color: #b9c6d4;
  padding: 64px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1.1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-grid h4 {
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 18px;
}
.footer-grid ul li { margin-bottom: 10px; font-size: 0.88rem; }
.footer-grid ul a:hover { color: #fff; }
.footer-brand .brand { color: #fff; margin-bottom: 14px; }
.footer-brand p { font-size: 0.88rem; color: #93a5b7; max-width: 32ch; }
.footer-social { display: flex; gap: 10px; margin-top: 18px; }
.footer-social a {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem;
  color: #fff;
  transition: background 0.15s ease;
}
.footer-social a:hover { background: var(--brand); }
.footer-social svg { width: 16px; height: 16px; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  font-size: 0.82rem;
  color: #7f93a6;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-bottom a:hover { color: #fff; }

/* ============================================
   Page hero (interior pages)
   ============================================ */
.page-hero {
  background: linear-gradient(160deg, var(--ink) 0%, var(--brand-dark) 100%);
  color: #fff;
  padding: 64px 0 56px;
}
.page-hero .crumb {
  font-size: 0.85rem;
  color: #a9bccd;
  margin-bottom: 14px;
}
.page-hero .crumb a:hover { color: #fff; }
.page-hero h1 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); font-weight: 800; }
.page-hero p { margin-top: 12px; color: #cdd9e4; max-width: 60ch; }

/* Utility */
.mt-lg { margin-top: 48px; }
.text-center { text-align: center; }

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 980px) {
  .nav__links, .nav__cta .btn--outline { display: none; }
  .nav__toggle { display: block; }
  .hero__grid { grid-template-columns: 1fr; padding-top: 60px; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .logo-strip { grid-template-columns: repeat(3, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .client-list-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .section { padding: 60px 0; }
  .grid--4, .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .logo-strip { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .cta-band { flex-direction: column; text-align: center; }
  .topbar__contact { flex-direction: column; gap: 2px; }
  .hero__stats { gap: 24px; }
}

/* Mobile nav drawer */
.nav__links.open {
  display: flex;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  flex-direction: column;
  padding: 12px;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-md);
}
