/* ============================================================
   CONTALISS — Hoja de estilos v1.0
   Diseño corporativo, limpio y responsive.
   ============================================================ */

:root {
  /* Colores oficiales de marca (extraídos de los logos CONTALISS) */
  --azul-oscuro: #003466;
  --azul-medio: #0d4d85;
  --azul-claro: #eaf1f8;
  --verde: #00af8d;
  --verde-oscuro: #008f73;
  --texto: #24313f;
  --texto-suave: #5a6b7d;
  --blanco: #ffffff;
  --gris-fondo: #f5f8fb;
  --borde: #dde6ef;
  --radio: 12px;
  --sombra: 0 4px 18px rgba(14, 42, 71, 0.08);
  --fuente: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

/* Evita que el header fijo tape el inicio de las secciones al navegar con anclas */
section[id] { scroll-margin-top: 84px; }

body {
  font-family: var(--fuente);
  color: var(--texto);
  background: var(--blanco);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

.container {
  width: min(1140px, 92%);
  margin-inline: auto;
}

.narrow { max-width: 780px; }

/* ---------- Tipografía ---------- */
h1, h2, h3 { line-height: 1.25; color: var(--azul-oscuro); font-weight: 700; }

h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 0.75rem; }
h3 { font-size: 1.08rem; margin-bottom: 0.4rem; }

.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--verde);
  margin-bottom: 0.5rem;
}

.section-intro {
  max-width: 720px;
  color: var(--texto-suave);
  margin-bottom: 2.2rem;
  font-size: 1.05rem;
}

/* ---------- Botones ---------- */
.btn {
  display: inline-block;
  padding: 0.85rem 1.8rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  font-size: 1rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.btn:active { transform: scale(0.98); }

.btn-primary { background: var(--verde); color: var(--blanco); }
.btn-primary:hover { background: var(--verde-oscuro); }

.btn-secondary { background: transparent; color: var(--blanco); border-color: rgba(255, 255, 255, 0.6); }
.btn-secondary:hover { background: rgba(255, 255, 255, 0.12); border-color: var(--blanco); }

.btn-lg { padding: 1rem 2.4rem; font-size: 1.05rem; }
.btn-block { width: 100%; border: none; font-family: var(--fuente); }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--blanco);
  border-bottom: 1px solid var(--borde);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 0.8rem;
}

.brand-logo { width: 190px; height: 44px; display: block; }

.nav-list {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  list-style: none;
}

.nav-list a {
  text-decoration: none;
  color: var(--texto);
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-list a:hover { color: var(--verde); }

.nav-cta {
  background: var(--azul-oscuro);
  color: var(--blanco) !important;
  padding: 0.55rem 1.2rem;
  border-radius: 8px;
}

.nav-cta:hover { background: var(--azul-medio); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.nav-toggle span {
  width: 26px;
  height: 3px;
  background: var(--azul-oscuro);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, #00284f 0%, var(--azul-oscuro) 55%, var(--azul-medio) 100%);
  color: var(--blanco);
  padding: clamp(4rem, 9vw, 7rem) 0;
}

.hero-content { max-width: 820px; }

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.82rem;
  font-weight: 600;
  color: #3fd9b8;
  margin-bottom: 1rem;
}

.hero h1 { color: var(--blanco); margin-bottom: 1.2rem; }

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255, 255, 255, 0.88);
  max-width: 680px;
  margin-bottom: 2.2rem;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ---------- Secciones ---------- */
.section { padding: clamp(3.5rem, 7vw, 5.5rem) 0; }

.section-alt { background: var(--gris-fondo); }

.section-dark {
  background: var(--azul-oscuro);
}

.section-dark h2, .section-dark h3 { color: var(--blanco); }
.section-dark p { color: rgba(255, 255, 255, 0.85); }
.section-dark .section-eyebrow { color: #3fd9b8; }
.section-dark strong { color: var(--blanco); }

/* ---------- Tarjetas de servicios ---------- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.4rem;
}

.card {
  background: var(--blanco);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 1.6rem 1.4rem;
  box-shadow: var(--sombra);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 26px rgba(14, 42, 71, 0.14);
}

.card-icon { font-size: 1.7rem; margin-bottom: 0.7rem; }

.card p { color: var(--texto-suave); font-size: 0.94rem; }

/* ---------- Diferencial ---------- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.6rem;
  list-style: none;
}

.feature { display: flex; gap: 0.9rem; align-items: flex-start; }

.feature-check {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--verde);
  color: var(--blanco);
  display: grid;
  place-items: center;
  font-weight: 700;
  margin-top: 0.2rem;
}

.feature p { color: var(--texto-suave); font-size: 0.94rem; }

/* ---------- Sobre / Tecnología ---------- */
.about-text p + p { margin-top: 1.1rem; }
.about-text { font-size: 1.03rem; }

/* ---------- Clientes ---------- */
.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.4rem;
}

.client-item {
  background: var(--azul-claro);
  border-radius: var(--radio);
  padding: 1.4rem 1.3rem;
}

.client-item p { color: var(--texto-suave); font-size: 0.94rem; }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--verde-oscuro), var(--verde));
  padding: clamp(3rem, 6vw, 4.5rem) 0;
}

.cta-content { text-align: center; max-width: 820px; }

.cta-content h2 { color: var(--blanco); margin-bottom: 1.8rem; }

.cta-band .btn-primary { background: var(--blanco); color: var(--verde-oscuro); }
.cta-band .btn-primary:hover { background: var(--azul-claro); }

/* ---------- Contacto ---------- */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 3rem;
  align-items: start;
}

.contact-info p { color: var(--texto-suave); margin-bottom: 1.5rem; }

.whatsapp-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 600;
  color: var(--verde-oscuro);
  text-decoration: none;
  border: 2px solid var(--verde);
  padding: 0.7rem 1.3rem;
  border-radius: 8px;
  transition: background 0.2s ease, color 0.2s ease;
}

.whatsapp-inline:hover { background: var(--verde); color: var(--blanco); }

.contact-form {
  background: var(--gris-fondo);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 1.8rem;
}

.form-row { margin-bottom: 1.1rem; }

.form-row label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.35rem;
  color: var(--azul-oscuro);
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--borde);
  border-radius: 8px;
  font-family: var(--fuente);
  font-size: 0.95rem;
  color: var(--texto);
  background: var(--blanco);
}

.form-row input:focus,
.form-row textarea:focus {
  outline: 2px solid var(--verde);
  border-color: var(--verde);
}

.form-note { margin-top: 0.8rem; font-size: 0.88rem; color: var(--texto-suave); }
.form-note.ok { color: var(--verde-oscuro); font-weight: 600; }
.form-note.error { color: #c0392b; font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--azul-oscuro);
  color: rgba(255, 255, 255, 0.82);
  padding-top: 3.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.2rem;
  padding-bottom: 2.5rem;
}

.footer-logo { width: 180px; height: 42px; display: block; margin-bottom: 1rem; }

.site-footer h3 { color: var(--blanco); font-size: 0.95rem; margin-bottom: 0.8rem; }

.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 0.5rem; font-size: 0.92rem; }

.site-footer a { color: rgba(255, 255, 255, 0.82); text-decoration: none; }
.site-footer a:hover { color: var(--blanco); text-decoration: underline; }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-block: 1.2rem;
  font-size: 0.85rem;
  text-align: center;
}

.footer-legal {
  margin-top: 0.4rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.55);
}

.legal-pending { cursor: default; }

/* ---------- WhatsApp flotante ---------- */
.whatsapp-float {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 200;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: var(--blanco);
  display: grid;
  place-items: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease;
}

.whatsapp-float:hover { transform: scale(1.08); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .contact-wrap { grid-template-columns: 1fr; gap: 2rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .nav-toggle { display: flex; }

  .nav-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--blanco);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    border-bottom: 1px solid var(--borde);
    box-shadow: var(--sombra);
    display: none;
    padding: 0.5rem 0 1rem;
  }

  .nav-list.open { display: flex; }

  .nav-list li { padding: 0.55rem 1.4rem; }

  .nav-cta { display: inline-block; text-align: center; }

  .hero-actions .btn { width: 100%; text-align: center; }

  .footer-grid { grid-template-columns: 1fr; gap: 1.8rem; }
}
