/* ========================================================= */
/* 🎨 VARIABLES Y TEMAS */
/* ========================================================= */

:root {
  /* Base */
  --bg: #0c1222;
  --card: #141c33;
  --text: #e9edf7;
  --muted: #b3bddc;
  --fine-text: rgba(183, 195, 230, .85);
  /* Marca (AZUL ÚNICO) */
  /* --brand: #1e5bd8; */
    --brand: red;
  /* UI */
  --border: rgba(255,255,255,.08);
  --shadow: 0 18px 45px rgba(0,0,0,.35);
  --radius: 18px;
}

body[data-theme="light"] {
  --bg: #f5f7fb;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #5f6b85;
  --brand: #1d4ed8;
  --border: #e2e8f0;
  --shadow: 0 10px 28px rgba(15,23,42,.08);
  --fine-text: rgb(0, 0, 0);
}

body[data-theme="light"] .themeBtn {
  background:
    radial-gradient(60% 100% at 50% 50%, rgba(255,200,0,.25), transparent 70%),
    color-mix(in srgb, var(--card) 90%, transparent);
}

body[data-theme="light"] .btn {
  color: #ffffff;
}

/* ========================================================= */
/* 🧱 RESET Y BASE */
/* ========================================================= */

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, "Helvetica Neue", Arial, "Noto Sans";
  background:
    radial-gradient(1000px 500px at 20% 10%, rgba(30,91,216,.20), transparent 60%),
    var(--bg);
  color: var(--text);
  line-height: 1.45;
  overflow-x: hidden;
}

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

/* ========================================================= */
/* 📐 LAYOUT GENERAL */
/* ========================================================= */

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

@media (max-width: 600px) {
  html, body {
    width: 100%;
    overflow-x: hidden;
  }

  .wrap {
    max-width: 100%;
    padding: 0 16px;
  }

  .grid,
  .cols3 {
    width: 100%;
  }
}


/* ========================================================= */
/* 🧭 HEADER Y NAVEGACIÓN */
/* ========================================================= */

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(10px);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  border-bottom: 1px solid var(--border);
}

.header .wrap { padding: 0 24px; }

@media (min-width: 1200px) {
  .header .wrap { padding: 0 32px; }
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 800;
  letter-spacing: .4px;
  padding-left: 4px;
}

.brandName {
  font-size: 14px;
  color: var(--muted);
  font-weight: 900;
  letter-spacing: .6px;
}

.brandSub {
  letter-spacing: .8px;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--muted);
  margin-top: -2px;
}

.logo {
  width: 72px;
  height: 72px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.navlinks {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.navlinks a {
  color: var(--muted);
  font-weight: 700;
}

.navlinks a:hover {
  color: var(--text);
}

.navActions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ========================================================= */
/* 📱 RESPONSIVE HERO Y MINI */
/* ========================================================= */

@media screen and (max-width: 950px) {
  .grid {
    display: grid;
    grid-template-columns: 1fr !important;
    gap: 20px;
  }

  .heroCard {
    order: 1;
    width: 100%;
  }

  .mini {
    order: 2;
    width: 100%;
    margin-top: 0;
  }

  html, body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .wrap {
    max-width: 100%;
    padding: 0 16px;
  }

  .navlinks {
    display: none; 
  }
}

/* ========================================================= */
/* 🎛 BOTONES */
/* ========================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, var(--brand), #3b82f6);
  color: var(--text);
  font-weight: 800;
  transition: transform .08s ease, background .2s ease, border-color .2s ease, filter .2s ease;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(30,91,216,.25);
  margin-left: 5px;
  margin-right: 5px;
}

.btn:hover {
  transform: translateY(-1px);
  background: rgba(255,255,255,.09);
  border-color: rgba(255,255,255,.14);
}

.btn.primary {
  border: none;
  background: linear-gradient(135deg, var(--brand), #3b82f6);
  box-shadow: 0 14px 28px rgba(30,91,216,.25);
}

.btn.primary:hover { 
  filter: brightness(1.03); 
}

.btn.green {
  border: none;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  box-shadow: 0 14px 28px rgba(34,197,94,.25);
}

.btn.green:hover { filter: brightness(1.03); }

/* ========================================================= */
/* 🦸 HERO */
/* ========================================================= */

.hero { padding: 46px 0 18px; }

.grid {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 18px;
  align-items: stretch;
}

.card {
  background: color-mix(in srgb, var(--card) 85%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.heroCard { padding: 28px; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.06);
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

/* ========================================================= */
/* 🧩 MINI CARDS Y ESTADÍSTICAS */
/* ========================================================= */

.mini {
  display: grid;
  gap: 10px;
  padding: 22px;
  background: color-mix(in srgb, var(--card) 85%, transparent);
}

.stat {
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(58, 163, 255, .16), rgba(34, 197, 94, .10));
}

.stat b { display: block; font-size: 18px; }

.stat span {
  color: var(--muted);
  font-size: 13px;
}

.row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.quickForm {
  margin-bottom: 22px;
}


/* ========================================================= */
/* ✏️ TEXTO */
/* ========================================================= */

h1 {
  margin: 14px 0 10px;
  font-size: 42px;
  line-height: 1.08;
}

@media (max-width: 520px) { h1 { font-size: 34px; } }

h2 { margin: 0; font-size: 24px; }

p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 16px;
}

p b { color: var(--text); }

.fine {
  font-size: 15px;
  color:var(--fine-text);
  margin-top: 14px;
  margin-bottom: 14px;
}

/* ========================================================= */
/* 💼 SERVICIOS */
/* ========================================================= */

.cols3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 14px;
}

@media (max-width: 900px) { .cols3 { grid-template-columns: 1fr; } }

.service {
  padding: 18px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.04);
}

.service h3 { margin: 10px 0 6px; }

.service p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(58,163,255,.12);
  border: 1px solid rgba(58,163,255,.25);
  font-weight: 900;
}

.icon.green {
  background: rgba(34,197,94,.12);
  border: 1px solid rgba(34,197,94,.25);
}

/* ========================================================= */
/* 📢 CTA Y ELEMENTOS VARIOS */
/* ========================================================= */

.cta {
  margin-top: 14px;
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(58,163,255,.16), rgba(34,197,94,.10));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.ctaTitle {
  font-weight: 900;
  font-size: 18px;
}

/* 🔹 Pills informativas */
.pill {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--border);
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
  margin-top: 10px;
}


/* ========================================================= */
/* 📧 FORMULARIOS */
/* ========================================================= */

.formCard {
  margin-top: 14px;
  padding: 22px;
}

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

input, select, textarea {
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 90%, transparent);
  color: var(--text);
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(30,91,216,.18);
}

textarea {
  min-width: 150px;
  min-height: 175px;
  resize: none;
}

.emailForm {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 16px;
  align-items: stretch;
}

.emailForm .data {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.emailForm .messageBox {
  display: flex;
  flex-direction: column;
}

.emailForm textarea {
  flex: 1;
  min-height: 180px;
  resize: none;
}

@media (max-width: 700px) {
  .emailForm { grid-template-columns: 1fr; }
  .emailForm textarea { min-height: 140px; }
}

/* ========================================================= */
/* 🌙 BOTÓN DE TEMA */
/* ========================================================= */

.themeBtn {
  width: 56px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background:
    radial-gradient(60% 100% at 50% 50%, rgba(255,255,255,.10), transparent 70%),
    color-mix(in srgb, var(--card) 85%, transparent);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.04),
    0 8px 18px rgba(0,0,0,.25);
  transition:
    background .25s ease,
    box-shadow .25s ease,
    transform .15s ease;
}

.themeBtn:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.08),
    0 10px 22px rgba(0,0,0,.35);
}

.themeBtn span, .themeBtn { 
  font-size: 16px; 
  line-height: 1; 
}

/* ========================================================= */
/* ⚓ FOOTER */
/* ========================================================= */

.footer {
  padding: 22px 0 36px;
  color: rgba(183,195,230,.85);
  border-top: 1px solid var(--border);
}

.foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* ========================================================= */
/* 📱 RESPONSIVE / UTILS */
/* ========================================================= */

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

section {
  margin-bottom: 3rem;
}

section + section {
  border-top: 1px solid var(--border);
  padding-top: 2.5rem;
  margin-top: 2.5rem;
}

#servicios, #contacto, #cobertura { scroll-margin-top: 100px; }
