:root{
  --brand-primary:#00AEEF;
  --brand-neutral:#54565A;

  --bg:#e9edf3;
  --surface:#ffffff;
  --border:#e7e7ea;
  --text:#0f172a;
  --muted:#6b7280;

  --radius:18px;
  --shadow: 0 18px 40px rgba(15, 23, 42, .10);
}

*{ box-sizing:border-box; }

html{
  scrollbar-gutter: stable;
}

body{
  margin:0;
  font-family: Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a{ color: inherit; text-decoration:none; }
a:focus-visible{
  outline: 3px solid rgba(0,174,239,.35);
  outline-offset: 3px;
  border-radius: 10px;
}

.container{
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 34px;
}

/* TOPBAR */
.topbar{
  position: sticky;
  top:0;
  z-index: 10;
  background: linear-gradient(90deg, var(--brand-neutral), #2f3134);
  border-bottom: 3px solid var(--brand-primary);
  box-shadow: 0 8px 18px rgba(15, 23, 42, .12);
}
.topbar-inner{
  height: 68px;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 14px;
}
.brand{
  display:flex;
  align-items:center;
  gap: 12px;
  color:#fff;
}
.brand-title{ font-weight: 900; letter-spacing:.2px; }
.brand-sub{ font-size: 12px; opacity:.85; margin-top: 3px; }

.nav{
  display:flex;
  align-items:center;
  gap: 10px;
}
.nav a{
  color:#fff;
  font-weight: 900;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  transition: transform .12s ease, opacity .12s ease, background .12s ease;
}
.nav a:hover{ opacity:.95; }
.nav a:active{ transform: translateY(1px); }

/* HERO PRO */
.hero{
  padding: 86px 0 44px;
  background:
    radial-gradient(1000px 420px at 18% 18%, rgba(0,174,239,.16), transparent 60%),
    radial-gradient(900px 360px at 80% 10%, rgba(84,86,90,.12), transparent 60%);
}

.hero-grid{
  display:grid;
  grid-template-columns: 1.25fr .75fr;
  gap: 28px;
  align-items: center;
}

.hero-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 34px;
  overflow:hidden;
  position: relative;
}

.hero-card::after{
  content:"";
  position:absolute;
  right:-110px;
  top:-110px;
  width:260px;
  height:260px;
  border-radius:999px;
  background: rgba(0,174,239,.12);
}

.kicker{
  display:inline-flex;
  gap: 8px;
  align-items:center;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(0,174,239,.25);
  background: rgba(0,174,239,.10);
  color: var(--brand-neutral);
  font-weight: 900;
  font-size: 12px;
}

.h1{
  margin: 16px 0 12px;
  font-size: clamp(30px, 3.4vw, 50px);
  line-height: 1.08;
  letter-spacing: -0.8px;
}

.p{
  margin: 0 0 18px;
  color: var(--muted);
  font-size: clamp(14px, 1.15vw, 17px);
  line-height: 1.75;
  max-width: 62ch;
}

.cta-row{
  display:flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding: 13px 18px;
  border-radius: 16px;
  font-weight: 900;
  border: 0;
  cursor:pointer;
  transition: transform .12s ease, filter .12s ease, box-shadow .12s ease, background .12s ease;
}
.btn:focus-visible{
  outline: none;
  box-shadow: 0 0 0 4px rgba(0,174,239,.18), 0 14px 26px rgba(0,174,239,.22);
}

.btn-primary{
  background: var(--brand-primary);
  color:#fff;
  box-shadow: 0 14px 26px rgba(0,174,239,.22);
}
.btn-primary:hover{ filter: brightness(.97); }
.btn-primary:active{ transform: translateY(1px); }

.btn-secondary{
  background: rgba(0,174,239,.10);
  color: var(--brand-neutral);
  border: 1px solid rgba(0,174,239,.25);
}
.btn-secondary:hover{ background: rgba(0,174,239,.14); }

/* SIDE CARD */
.side-card{
  background: linear-gradient(180deg, #ffffff, #f7fbff);
  border: 1px solid rgba(0,174,239,.18);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 26px;
}

.side-title{
  font-weight: 900;
  color: var(--brand-neutral);
  margin: 0 0 10px;
  font-size: 18px;
}

.bullets{
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.9;
}

/* TRUST STRIP */
.trust{
  padding: 0 0 18px;
}
.trust-card{
  background: rgba(255,255,255,.72);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(231,231,234,.9);
  border-radius: 22px;
  box-shadow: 0 18px 40px rgba(15,23,42,.08);
  padding: 16px 18px;
  margin-top: -22px; /* lo “sube” hacia el hero */
}
.trust-grid{
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.trust-item{
  display:flex;
  align-items:flex-start;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(0,174,239,.14);
  background: rgba(0,174,239,.06);
}
.trust-dot{
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--brand-primary);
  box-shadow: 0 10px 18px rgba(0,174,239,.18);
  margin-top: 4px;
}
.trust-title{
  font-weight: 900;
  color: var(--brand-neutral);
  font-size: 13px;
  margin: 0;
}
.trust-sub{
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

/* MINI BLOQUE: ASEGURADORAS / ALIADOS */
.partners{
  padding: 18px 0 10px;
}
.partners-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 18px;
}
.partners-head{
  display:flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
}
.partners-title{
  margin: 0;
  font-weight: 900;
  color: var(--brand-neutral);
  font-size: 16px;
}
.partners-note{
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.partner-logos{
  display:grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}
.partner-pill{
  height: 44px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius: 14px;
  border: 1px dashed rgba(84,86,90,.22);
  background: rgba(15,23,42,.02);
  color: rgba(84,86,90,.75);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: .4px;
  text-transform: uppercase;
}

/* SECTIONS */
.section{
  padding: 34px 0;
}

.section-title{
  font-size: 20px;
  font-weight: 900;
  color: var(--brand-neutral);
  margin: 0 0 14px;
}

/* PRODUCTS */
.grid-4{
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 18px;
  transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
}

.card:hover{
  transform: translateY(-2px);
  box-shadow: 0 26px 52px rgba(15, 23, 42, .12);
  border-color: rgba(0,174,239,.25);
}

.card-head{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
}

.pill{
  font-size: 11px;
  font-weight: 900;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(84,86,90,.15);
  background: rgba(84,86,90,.08);
  color: var(--brand-neutral);
}

.card h3{
  margin: 10px 0 6px;
  font-size: 16px;
  color: var(--brand-neutral);
}

.card p{
  margin: 0 0 12px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}

.card a{
  display:inline-flex;
  gap: 8px;
  align-items:center;
  font-weight: 900;
  color: var(--brand-primary);
}

/* STEPS */
.steps{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.step{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 18px;
}

.step b{
  display:inline-flex;
  width: 30px;
  height: 30px;
  align-items:center;
  justify-content:center;
  border-radius: 12px;
  background: rgba(0,174,239,.12);
  border: 1px solid rgba(0,174,239,.25);
  color: var(--brand-neutral);
  margin-bottom: 10px;
}

/* FOOTER */
.footer{
  padding: 22px 0 40px;
  color: var(--muted);
  font-size: 12px;
}

.footer .fineprint{
  background: rgba(84,86,90,.06);
  border: 1px solid rgba(84,86,90,.12);
  border-radius: 16px;
  padding: 14px;
}

/* LOGO */
.brand-logo{
  width: 44px;
  height: 44px;
  object-fit: contain;
  border-radius: 12px;
  background: rgba(255,255,255,.10);
  padding: 6px;
  border: 1px solid rgba(255,255,255,.14);
}

/* RESPONSIVE */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns: 1fr; }
  .grid-4{ grid-template-columns: repeat(2, 1fr); }
  .steps{ grid-template-columns: 1fr; }
  .container{ padding: 0 20px; }
  .trust-grid{ grid-template-columns: repeat(2, 1fr); }
  .partner-logos{ grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 520px){
  .grid-4{ grid-template-columns: 1fr; }
  .trust-grid{ grid-template-columns: 1fr; }
  .partner-logos{ grid-template-columns: repeat(2, 1fr); }
}

/* =========================================================
   FORMS (PRO) — add-on for hcm_cotizar.php and future modules
   ========================================================= */

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

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

.field{
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label{
  font-size: 13px;
  font-weight: 900;
  color: var(--brand-neutral);
}

.field input,
.field select,
.field textarea{
  width: 100%;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(15,23,42,.12);
  background: #fff;
  color: var(--text);
  font-size: 14px;
  transition: box-shadow .12s ease, border-color .12s ease, transform .12s ease;
}

.field input::placeholder{
  color: rgba(107,114,128,.85);
}

.field input:focus,
.field select:focus,
.field textarea:focus{
  outline: none;
  border-color: rgba(0,174,239,.55);
  box-shadow: 0 0 0 4px rgba(0,174,239,.16);
}

.field input:disabled,
.field select:disabled{
  opacity: .7;
  cursor: not-allowed;
}

.hint{
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
  line-height: 1.4;
}

.error{
  font-size: 12px;
  color: #b91c1c;
  font-weight: 800;
  min-height: 14px; /* evita saltos */
}

.field.has-error input,
.field.has-error select{
  border-color: rgba(185,28,28,.55);
  box-shadow: 0 0 0 4px rgba(185,28,28,.10);
}

/* Improve card spacing on forms */
.card form{
  margin-top: 10px;
}

/* Button states */
.btn[disabled]{
  opacity: .75;
  cursor: not-allowed;
  transform: none !important;
  filter: none !important;
}

/* Small alignment fix when you use the topbar brand as <a> */
.brand{
  text-decoration: none;
}

/* ============================= */
/* CHAT WIDGET */
/* ============================= */

.chat-widget{
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999;
}

.chat-button{
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--brand-primary);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size: 24px;
  cursor:pointer;
  color:#fff;
  box-shadow: 0 14px 30px rgba(0,174,239,.35);
  transition: transform .15s ease;
}

.chat-button:hover{
  transform: scale(1.05);
}

.chat-box{
  width: 320px;
  background:#fff;
  border-radius: 20px;
  box-shadow: 0 30px 60px rgba(0,0,0,.15);
  position:absolute;
  bottom: 75px;
  right: 0;
  overflow:hidden;
  opacity:0;
  pointer-events:none;
  transform: translateY(10px);
  transition: all .2s ease;
}

.chat-box.active{
  opacity:1;
  pointer-events:auto;
  transform: translateY(0);
}

.chat-header{
  background: var(--brand-primary);
  color:#fff;
  padding: 14px;
  display:flex;
  justify-content: space-between;
  align-items:center;
}

.chat-status{
  font-size:12px;
  opacity:.85;
}

.chat-header button{
  background:none;
  border:0;
  color:#fff;
  font-size:16px;
  cursor:pointer;
}

.chat-messages{
  padding:14px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.chat-message{
  padding:10px 14px;
  border-radius:14px;
  font-size:13px;
  max-width:85%;
}

.chat-message.support{
  background: rgba(0,174,239,.10);
  color: var(--brand-neutral);
}

.chat-footer{
  padding:14px;
  border-top:1px solid #eee;
}