/* ==========================================================
   NETCheck — estilos compartidos (landing + login)
   Paleta y tipografía tomadas de netcheck.es
   ========================================================== */
:root {
  --navy-900: #081621;
  --navy-800: #0d1f2d;
  --navy-700: #1b2b37;
  --navy-600: #243a4c;
  --steel: #698aa0;
  --mist: #c4d3de;
  --light: #ecf0f3;
  --yellow: #fef102;
  --blue: #004ddb;
  --blue-hover: #0040b8;
  --sky: #2579b8;
  --teal: #1fb5a8;
  --white: #ffffff;
  --text: #212529;
  --danger: #ff6b6b;

  --font-head: "Montserrat", sans-serif;
  --font-body: "Poppins", sans-serif;
  --radius: 4px;
  --radius-lg: 12px;
  --max: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--white);
  background: var(--navy-900);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 700; line-height: 1.2; margin: 0; }
.hl { color: var(--yellow); }
.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-body); font-size: 26px; line-height: 1; letter-spacing: -.5px; }
.logo__mark { width: 26px; height: 26px; }
.logo__net { font-weight: 800; }
.logo__check { font-weight: 400; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 22px; border-radius: var(--radius); border: 2px solid transparent;
  font-family: var(--font-body); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .3px;
  cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--blue); color: var(--white); }
.btn--primary:hover { background: var(--blue-hover); }
.btn--ghost { border-color: var(--white); color: var(--white); background: transparent; }
.btn--ghost:hover { background: var(--white); color: var(--navy-900); }
.btn--yellow { background: var(--yellow); color: var(--navy-900); }
.btn--yellow:hover { background: #fff64d; }
.btn--block { width: 100%; }
.btn:focus-visible, .field input:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(8, 22, 33, .92); backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.header__inner { display: flex; align-items: center; justify-content: space-between; height: 80px; gap: 24px; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { font-size: 13px; font-weight: 600; text-transform: uppercase; transition: color .2s; }
.nav a:not(.btn):hover { color: var(--yellow); }
.nav .btn { padding: 10px 18px; }
.burger { display: none; background: none; border: 0; color: var(--white); cursor: pointer; padding: 8px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: 120px 0 140px;
  background:
    radial-gradient(ellipse 60% 70% at 85% 20%, rgba(37,121,184,.45), transparent 70%),
    radial-gradient(ellipse 40% 50% at 100% 90%, rgba(31,181,168,.25), transparent 70%),
    linear-gradient(180deg, #0a1a27 0%, var(--navy-900) 100%);
}
.hero__waves { position: absolute; right: -10%; top: 0; width: 70%; height: 100%; opacity: .55; pointer-events: none; }
.hero__content { position: relative; max-width: 760px; }
.hero h1 { font-size: clamp(34px, 5vw, 54px); }
.hero__sub { font-size: 20px; font-weight: 700; margin: 28px 0 44px; }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 16px; }

/* ---------- Secciones ---------- */
.section { padding: 100px 0; }
.section--alt { background: var(--navy-800); }
.section__head { text-align: center; margin-bottom: 56px; }
.section__head::before { content: ""; display: block; width: 140px; height: 2px; margin: 0 auto 28px; background: var(--teal); }
.section__eyebrow { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 1.5px; color: var(--mist); margin-bottom: 8px; }
.section__head h2 { font-size: clamp(28px, 3.5vw, 38px); }

/* Tarjetas de servicios */
.grid { display: grid; gap: 24px; }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--navy-700); border: 1px solid var(--navy-600); border-radius: var(--radius-lg);
  padding: 32px 26px; display: flex; flex-direction: column; gap: 16px;
  transition: transform .25s, border-color .25s;
}
.card:hover { transform: translateY(-6px); border-color: var(--sky); }
.card h3 { font-size: 20px; }
.card p { margin: 0; color: var(--mist); font-size: 14px; flex: 1; }
.card .btn { align-self: flex-start; padding: 10px 16px; font-size: 12px; }
.card__icon { width: 52px; height: 52px; border-radius: 10px; display: grid; place-items: center; background: rgba(254,241,2,.1); color: var(--yellow); }

/* Sectores */
.sector { text-align: center; padding: 8px; }
.sector__icon { width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 20px; background: var(--sky); color: var(--white); transition: transform .25s; }
.sector:hover .sector__icon { transform: scale(1.06); }
.sector h3 { font-size: 24px; margin-bottom: 10px; }
.sector p { color: var(--mist); font-size: 14px; margin: 0; }

/* Cifras */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; text-align: center; }
.stat__num { font-family: var(--font-head); font-size: clamp(40px, 5vw, 56px); font-weight: 800; color: var(--yellow); line-height: 1; }
.stat__label { color: var(--mist); margin-top: 10px; }

/* CTA final */
.cta {
  background: linear-gradient(120deg, var(--blue) 0%, var(--sky) 100%);
  border-radius: var(--radius-lg); padding: 56px; display: flex; align-items: center; justify-content: space-between; gap: 32px;
}
.cta h2 { font-size: clamp(26px, 3vw, 34px); margin-bottom: 10px; }
.cta p { margin: 0; color: rgba(255,255,255,.85); max-width: 560px; }

/* Footer */
.footer { padding: 48px 0; border-top: 1px solid rgba(255,255,255,.08); color: var(--steel); font-size: 13px; }
.footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer a:hover { color: var(--yellow); }
.footer__links { display: flex; gap: 20px; flex-wrap: wrap; }

/* Animación de entrada */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ==========================================================
   Login
   ========================================================== */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.auth__aside {
  position: relative; overflow: hidden; padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between;
  background:
    radial-gradient(ellipse 70% 60% at 80% 30%, rgba(37,121,184,.5), transparent 70%),
    radial-gradient(ellipse 50% 40% at 20% 100%, rgba(31,181,168,.25), transparent 70%),
    var(--navy-900);
}
.auth__aside .hero__waves { width: 120%; right: -40%; }
.auth__claim { position: relative; max-width: 480px; }
.auth__claim h1 { font-size: clamp(30px, 3.6vw, 44px); margin-bottom: 18px; }
.auth__claim p { color: var(--mist); margin: 0; }
.auth__meta { position: relative; color: var(--steel); font-size: 13px; }

.auth__main { background: var(--light); color: var(--text); display: grid; place-items: center; padding: 48px 24px; }
.auth__card { width: 100%; max-width: 420px; }
.auth__back { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--navy-600); margin-bottom: 40px; }
.auth__back:hover { color: var(--blue); }
.auth__card h2 { color: var(--navy-900); font-size: 30px; margin-bottom: 8px; }
.auth__card .lead { color: #5b6b78; margin: 0 0 32px; font-size: 15px; }

.form { display: flex; flex-direction: column; gap: 20px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--navy-700); margin-bottom: 6px; }
.field__wrap { position: relative; }
.field input {
  width: 100%; padding: 14px 16px; font: inherit; font-size: 15px; color: var(--text);
  background: var(--white); border: 1.5px solid var(--mist); border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0,77,219,.15); }
.field input[aria-invalid="true"] { border-color: #d93636; }
.field__error { color: #d93636; font-size: 12px; margin-top: 6px; min-height: 18px; }
.field__toggle {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  background: none; border: 0; padding: 8px; cursor: pointer; color: var(--steel);
}
.field__toggle:hover { color: var(--navy-700); }

.form__row { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; color: var(--navy-600); }
.check input { width: 16px; height: 16px; accent-color: var(--blue); }
.link { color: var(--blue); font-weight: 600; }
.link:hover { text-decoration: underline; }

.form__alert { display: none; padding: 12px 14px; border-radius: var(--radius); font-size: 14px; }
.form__alert.is-error { display: block; background: #fde8e8; color: #a12020; border: 1px solid #f5c2c2; }
.form__alert.is-ok { display: block; background: #e6f4ea; color: #1e6b34; border: 1px solid #b9dfc4; }

.divider { display: flex; align-items: center; gap: 12px; color: var(--steel); font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--mist); }
.btn--sso { background: var(--white); color: var(--navy-700); border-color: var(--mist); text-transform: none; font-size: 14px; }
.btn--sso:hover { border-color: var(--navy-700); }
.auth__help { margin-top: 32px; font-size: 13px; color: #5b6b78; text-align: center; }

.success-gif {
  width: 140px; height: auto; margin: 0 auto 28px; display: block;
}
.tips {
  text-align: left; background: #f5f7f9; border: 1px solid var(--mist);
  border-radius: var(--radius); padding: 18px 20px; margin: 24px 0;
}
.tips__title { margin: 0 0 10px; font-weight: 700; color: var(--navy-900); font-size: 14px; }
.tips ul { margin: 0; padding-left: 20px; color: #4a5a66; font-size: 14px; }
.tips li { margin-bottom: 6px; }
.tips li:last-child { margin-bottom: 0; }
.reminder {
  font-size: 14px; color: var(--navy-700); border-left: 3px solid var(--teal);
  padding: 2px 0 2px 14px; margin: 0 0 24px; text-align: left;
}

.spinner { width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; display: none; }
.is-loading .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .burger { display: block; }
  .nav {
    position: absolute; top: 80px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--navy-900); border-bottom: 1px solid rgba(255,255,255,.08);
    padding: 8px 24px 24px; display: none;
  }
  .nav.is-open { display: flex; }
  .nav a:not(.btn) { padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
  .nav .btn { margin-top: 16px; }
  .grid--3 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; gap: 40px; }
  .cta { flex-direction: column; align-items: flex-start; padding: 40px 28px; }
  .auth { grid-template-columns: 1fr; }
  .auth__aside { padding: 32px 24px; min-height: 260px; }
  .auth__claim h1 { font-size: 28px; }
}
@media (max-width: 560px) {
  .container { padding: 0 16px; }
  .grid--4 { grid-template-columns: 1fr; }
  .hero { padding: 72px 0 88px; }
  .section { padding: 72px 0; }
  .hero__ctas .btn { width: 100%; }
}
