/* ==========================================================================
   Segurillave - Estilos principales
   Mobile-First | BEM | CSS3 Nativo
   ========================================================================== */

/* --- RESET Y BASE --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%; /* 1rem = 10px */
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 1.6rem;
  line-height: 1.6;
  color: #1a1a2e;
  background-color: #ffffff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  font-family: inherit;
}

select {
  font-family: inherit;
}

/* --- VARIABLES --- */
:root {
  --color-primary: #0A2463;
  --color-primary-light: #1B3A8C;
  --color-primary-dark: #071A4A;
  --color-accent: #F5B700;
  --color-accent-light: #FFD04D;
  --color-accent-dark: #D49E00;
  --color-white: #FFFFFF;
  --color-bg-light: #F4F6FB;
  --color-bg-alt: #EDF0F7;
  --color-text: #1a1a2e;
  --color-text-muted: #5a5f7a;
  --color-error: #E63946;
  --color-success: #2ECC71;
  --shadow-sm: 0 0.2rem 0.8rem rgba(10, 36, 99, 0.08);
  --shadow-md: 0 0.4rem 1.6rem rgba(10, 36, 99, 0.12);
  --shadow-lg: 0 0.8rem 3.2rem rgba(10, 36, 99, 0.16);
  --shadow-xl: 0 1.2rem 4.8rem rgba(10, 36, 99, 0.2);
  --radius-sm: 0.8rem;
  --radius-md: 1.2rem;
  --radius-lg: 1.6rem;
  --radius-xl: 2.4rem;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   HEADER
   ========================================================================== */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--color-primary);
  box-shadow: var(--shadow-md);
}

.header__container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 2rem;
  max-width: 120rem;
  margin: 0 auto;
}

.header__logo {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header__logo-icon {
  width: 3.6rem;
  height: 3.6rem;
}

.header__logo-text {
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: -0.02em;
}

.header__cta-link {
  display: inline-block;
  padding: 0.8rem 1.6rem;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--color-primary);
  background-color: var(--color-accent);
  border-radius: var(--radius-xl);
  transition: background-color var(--transition), transform var(--transition);
}

.header__cta-link:hover {
  background-color: var(--color-accent-light);
  transform: translateY(-1px);
}

/* ==========================================================================
   HERO
   ========================================================================== */

.hero {
  background: linear-gradient(145deg, var(--color-primary) 0%, var(--color-primary-light) 50%, var(--color-primary) 100%);
  padding: 5rem 2rem 6rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -20%;
  width: 50rem;
  height: 50rem;
  background: radial-gradient(circle, rgba(245, 183, 0, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero__container {
  max-width: 64rem;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 1.4rem;
  background-color: rgba(245, 183, 0, 0.15);
  border: 1px solid rgba(245, 183, 0, 0.3);
  border-radius: var(--radius-xl);
  margin-bottom: 2.4rem;
}

.hero__badge-icon {
  width: 1.6rem;
  height: 1.6rem;
}

.hero__badge-text {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero__title {
  font-size: 3.2rem;
  font-weight: 800;
  color: var(--color-white);
  line-height: 1.2;
  margin-bottom: 1.6rem;
  letter-spacing: -0.02em;
}

.hero__title--highlight {
  color: var(--color-accent);
  display: block;
}

.hero__subtitle {
  font-size: 1.6rem;
  color: rgba(255, 255, 255, 0.85);
  max-width: 48rem;
  margin: 0 auto 3.2rem;
  line-height: 1.7;
}

.hero__cta {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  padding: 1.6rem 3.2rem;
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--color-primary);
  background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-light) 100%);
  border-radius: var(--radius-xl);
  box-shadow: 0 0.4rem 2rem rgba(245, 183, 0, 0.4);
  transition: transform var(--transition), box-shadow var(--transition);
  animation: pulse-glow 2.5s ease-in-out infinite;
}

.hero__cta:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 0.6rem 2.4rem rgba(245, 183, 0, 0.5);
}

.hero__cta-icon {
  width: 2.4rem;
  height: 2.4rem;
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0.4rem 2rem rgba(245, 183, 0, 0.4); }
  50% { box-shadow: 0 0.4rem 3rem rgba(245, 183, 0, 0.6); }
}

.hero__trust {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: 2.4rem;
  padding: 0.8rem 1.6rem;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-xl);
}

.hero__trust-icon {
  width: 1.8rem;
  height: 1.8rem;
  flex-shrink: 0;
}

.hero__trust-text {
  font-size: 1.3rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

/* ==========================================================================
   FORMULARIO
   ========================================================================== */

.form-section {
  padding: 5rem 2rem;
  background-color: var(--color-bg-light);
}

.form-section__container {
  max-width: 52rem;
  margin: 0 auto;
}

.form-section__title {
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--color-primary);
  text-align: center;
  margin-bottom: 0.8rem;
  letter-spacing: -0.02em;
}

.form-section__subtitle {
  font-size: 1.5rem;
  color: var(--color-text-muted);
  text-align: center;
  margin-bottom: 3.2rem;
}

.form {
  background-color: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 3.2rem 2.4rem;
  box-shadow: var(--shadow-lg);
}

.form__group {
  margin-bottom: 2rem;
}

.form__label {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 0.8rem;
}

.form__label-icon {
  width: 1.8rem;
  height: 1.8rem;
  flex-shrink: 0;
}

.form__input,
.form__select {
  width: 100%;
  padding: 1.4rem 1.6rem;
  font-size: 1.5rem;
  color: var(--color-text);
  background-color: var(--color-bg-light);
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
  -webkit-appearance: none;
}

.form__input:focus,
.form__select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(10, 36, 99, 0.1);
  background-color: var(--color-white);
}

.form__input::placeholder {
  color: #9ba3bf;
}

.form__input--error,
.form__select--error {
  border-color: var(--color-error);
  background-color: #FFF5F5;
}

.form__select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%230A2463' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1.6rem center;
  padding-right: 4rem;
}

.form__error {
  display: block;
  font-size: 1.2rem;
  color: var(--color-error);
  margin-top: 0.4rem;
  min-height: 1.8rem;
  font-weight: 500;
}

.form__submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  padding: 1.6rem;
  margin-top: 1.2rem;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--color-white);
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  border-radius: var(--radius-sm);
  box-shadow: 0 0.4rem 1.6rem rgba(37, 211, 102, 0.3);
  transition: transform var(--transition), box-shadow var(--transition);
}

.form__submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.6rem 2rem rgba(37, 211, 102, 0.4);
}

.form__submit:active {
  transform: translateY(0);
}

.form__submit-icon {
  width: 2.2rem;
  height: 2.2rem;
}

/* ==========================================================================
   PASOS
   ========================================================================== */

.steps {
  padding: 5rem 2rem;
  background-color: var(--color-white);
}

.steps__container {
  max-width: 100rem;
  margin: 0 auto;
}

.steps__title {
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--color-primary);
  text-align: center;
  margin-bottom: 0.8rem;
  letter-spacing: -0.02em;
}

.steps__subtitle {
  font-size: 1.5rem;
  color: var(--color-text-muted);
  text-align: center;
  margin-bottom: 4rem;
}

.steps__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.step {
  position: relative;
  background-color: var(--color-bg-light);
  border-radius: var(--radius-lg);
  padding: 3rem 2.4rem 2.4rem;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition);
}

.step:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.step__number {
  position: absolute;
  top: -1.2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--color-white);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.step__icon {
  width: 5.6rem;
  height: 5.6rem;
  margin: 0.8rem auto 1.6rem;
}

.step__icon svg {
  width: 100%;
  height: 100%;
}

.step__title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.8rem;
}

.step__text {
  font-size: 1.4rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* ==========================================================================
   MÉTODOS DE PAGO
   ========================================================================== */

.payment {
  padding: 5rem 2rem;
  background: linear-gradient(145deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
}

.payment__container {
  max-width: 80rem;
  margin: 0 auto;
  text-align: center;
}

.payment__header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.8rem;
}

.payment__header-icon {
  width: 2.8rem;
  height: 2.8rem;
}

.payment__header-icon rect,
.payment__header-icon line {
  stroke: var(--color-accent);
}

.payment__header-icon rect:last-of-type {
  fill: var(--color-accent);
}

.payment__title {
  font-size: 2.4rem;
  font-weight: 800;
  color: var(--color-white);
  letter-spacing: -0.02em;
}

.payment__subtitle {
  font-size: 1.5rem;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 3.2rem;
}

.payment__methods {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.6rem;
}

.payment__method {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  transition: background var(--transition);
}

.payment__method:hover {
  background: rgba(255, 255, 255, 0.14);
}

.payment__method-icon {
  width: 4.8rem;
  height: 4.8rem;
  flex-shrink: 0;
}

.payment__method-icon svg {
  width: 100%;
  height: 100%;
}

.payment__method-name {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--color-white);
}

/* ==========================================================================
   VALIDACIÓN DE IDENTIDAD
   ========================================================================== */

.identity {
  padding: 5rem 2rem;
  background-color: var(--color-bg-light);
}

.identity__container {
  max-width: 60rem;
  margin: 0 auto;
  text-align: center;
}

.identity__icon-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.identity__icon {
  width: 7.2rem;
  height: 7.2rem;
}

.identity__title {
  font-size: 2.4rem;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 1.2rem;
  letter-spacing: -0.02em;
}

.identity__text {
  font-size: 1.5rem;
  color: var(--color-text-muted);
  margin-bottom: 3rem;
  line-height: 1.7;
}

.identity__text strong {
  color: var(--color-primary);
}

.identity__docs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.6rem;
}

.identity__doc {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  padding: 2rem 2.4rem;
  background-color: var(--color-white);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--color-accent);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
}

.identity__doc:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-md);
}

.identity__doc-icon {
  width: 3.2rem;
  height: 3.2rem;
  flex-shrink: 0;
}

.identity__doc-text {
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--color-primary);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

.footer {
  padding: 3.2rem 2rem;
  background-color: var(--color-primary-dark);
  text-align: center;
}

.footer__container {
  max-width: 80rem;
  margin: 0 auto;
}

.footer__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

.footer__logo-icon {
  width: 3.2rem;
  height: 3.2rem;
}

.footer__brand-name {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-white);
}

.footer__legal {
  font-size: 1.3rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 0.8rem;
  padding: 0.8rem 1.6rem;
  background: rgba(245, 183, 0, 0.1);
  border-radius: var(--radius-sm);
  display: inline-block;
}

.footer__copyright {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 1.2rem;
}

/* ==========================================================================
   NOTIFICACIÓN
   ========================================================================== */

.notification {
  position: fixed;
  top: 2rem;
  right: 2rem;
  max-width: 36rem;
  padding: 1.6rem 2rem;
  border-radius: var(--radius-md);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--color-white);
  box-shadow: var(--shadow-xl);
  transform: translateX(120%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.notification--visible {
  transform: translateX(0);
}

.notification--success {
  background-color: var(--color-success);
}

.notification--error {
  background-color: var(--color-error);
}

.notification__icon {
  width: 2rem;
  height: 2rem;
  flex-shrink: 0;
}

/* ==========================================================================
   RESPONSIVE — TABLET (>= 600px)
   ========================================================================== */

@media (min-width: 600px) {
  .hero {
    padding: 6rem 3rem 7rem;
  }

  .hero__title {
    font-size: 4rem;
  }

  .hero__subtitle {
    font-size: 1.8rem;
  }

  .form {
    padding: 4rem 3.2rem;
  }

  .steps__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2.4rem;
  }

  .payment__methods {
    grid-template-columns: repeat(3, 1fr);
  }

  .identity__docs {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   RESPONSIVE — DESKTOP (>= 960px)
   ========================================================================== */

@media (min-width: 960px) {
  .header__container {
    padding: 1.4rem 4rem;
  }

  .header__logo-text {
    font-size: 2.2rem;
  }

  .header__cta-link {
    font-size: 1.4rem;
    padding: 1rem 2.4rem;
  }

  .hero {
    padding: 8rem 4rem 10rem;
  }

  .hero__title {
    font-size: 5rem;
  }

  .hero__title--highlight {
    display: inline;
  }

  .hero__subtitle {
    font-size: 1.9rem;
  }

  .hero__cta {
    padding: 1.8rem 4rem;
    font-size: 1.8rem;
  }

  .form-section {
    padding: 6rem 4rem;
  }

  .form-section__title {
    font-size: 3.2rem;
  }

  .steps {
    padding: 7rem 4rem;
  }

  .steps__title {
    font-size: 3.2rem;
  }

  .steps__grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 2.4rem;
  }

  .payment {
    padding: 6rem 4rem;
  }

  .payment__title {
    font-size: 2.8rem;
  }

  .identity {
    padding: 6rem 4rem;
  }

  .identity__title {
    font-size: 2.8rem;
  }

  .footer {
    padding: 4rem;
  }
}

/* ==========================================================================
   RESPONSIVE — DESKTOP GRANDE (>= 1200px)
   ========================================================================== */

@media (min-width: 1200px) {
  .hero__title {
    font-size: 5.6rem;
  }

  .hero__subtitle {
    font-size: 2rem;
  }
}

/* ==========================================================================
   ACCESIBILIDAD — Reducir animaciones
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}
