*,
    *::before,
    *::after {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    :root {
      --navy: #003366;
      --navy-light: #004488;
      --gold: #c8a84b;
      --gold-light: #e0c06a;
      --white: #ffffff;
      --bg: #f4f6f9;
      --text: #1a1a2e;
      --muted: #6b7280;
      --border: #d1d5db;
      --error: #dc2626;
      --success: #16a34a;
      --radius: 8px;
      --font-body: 'Barlow', sans-serif;
      --font-display: 'Barlow Condensed', sans-serif;
    }

    * {
      transition: border-color .2s, background .2s, color .2s, opacity .2s;
    }

    body {
      font-family: var(--font-body);
      background: var(--bg);
      color: var(--text);
      min-height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 2rem 1rem;
    }

    .page {
      display: flex;
      width: 100%;
      max-width: 900px;
      min-height: 560px;
      border-radius: 16px;
      overflow: hidden;
      box-shadow: 0 20px 60px rgba(0, 51, 102, .15);
    }

    /* ── Animaciones orbes ── */
    @keyframes drift1 {
      0%, 100% { transform: translate(0,0) scale(1); }
      40%       { transform: translate(50px, 35px) scale(1.07); }
      70%       { transform: translate(-15px, 55px) scale(0.96); }
    }
    @keyframes drift2 {
      0%, 100% { transform: translate(0,0) scale(1); }
      35%       { transform: translate(-45px, -25px) scale(1.09); }
      65%       { transform: translate(25px, 15px) scale(0.94); }
    }
    @keyframes drift3 {
      0%, 100% { transform: translate(0,0) scale(1); }
      50%       { transform: translate(-30px, -20px) scale(1.18); }
    }

    /* ── Panel izquierdo ── */
    .panel-brand {
      flex: 0 0 360px;
      background: #080C14;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      padding: 3rem 2.25rem;
      position: relative;
      overflow: hidden;
    }

    /* Orbe azul superior-izquierda */
    .panel-brand::before {
      content: '';
      position: absolute;
      width: 340px;
      height: 340px;
      border-radius: 50%;
      background: radial-gradient(circle at 40% 40%, #0033A0cc, transparent 70%);
      top: -120px;
      left: -100px;
      filter: blur(55px);
      animation: drift1 11s ease-in-out infinite;
      z-index: 0;
    }

    /* Orbe azul oscuro inferior-derecha */
    .panel-brand::after {
      content: '';
      position: absolute;
      width: 260px;
      height: 260px;
      border-radius: 50%;
      background: radial-gradient(circle at 60% 60%, #002580aa, transparent 70%);
      bottom: -90px;
      right: -60px;
      filter: blur(50px);
      animation: drift2 14s ease-in-out infinite;
      z-index: 0;
    }

    /* Orbe rojo */
    .ring-mid {
      position: absolute;
      width: 160px;
      height: 160px;
      border-radius: 50%;
      background: radial-gradient(circle, #CC000066, transparent 70%);
      bottom: -20px;
      right: 40px;
      left: auto;
      top: auto;
      border: none;
      filter: blur(38px);
      animation: drift3 9s ease-in-out infinite;
      z-index: 0;
    }

    /* Malla de puntos */
    .dot-grid {
      position: absolute;
      inset: 0;
      background-image: radial-gradient(circle, rgba(255,255,255,0.04) 1px, transparent 1px);
      background-size: 28px 28px;
      z-index: 0;
    }

    /* Línea decorativa izquierda */
    .deco-line-left {
      position: absolute;
      width: 1px;
      height: 100%;
      background: linear-gradient(to bottom, transparent, rgba(0,51,160,0.25), transparent);
      left: 25%;
      transform: skewX(-12deg);
      z-index: 0;
    }

    /* Línea decorativa derecha */
    .deco-line-right {
      position: absolute;
      width: 1px;
      height: 100%;
      background: linear-gradient(to bottom, transparent, rgba(204,0,0,0.15), transparent);
      left: 75%;
      transform: skewX(-12deg);
      z-index: 0;
    }

    /* Contenido del panel por encima de efectos */
    .panel-brand > *:not(.ring-mid):not(.dot-grid):not(.deco-line-left):not(.deco-line-right) {
      position: relative;
      z-index: 1;
    }

    .logo-wrap {
      background: rgba(255,255,255,0.08);
      border: 1px solid rgba(255,255,255,0.12);
      border-radius: 12px;
      padding: 14px 22px;
      margin-bottom: 1.75rem;
      backdrop-filter: blur(6px);
    }

    .logo-wrap img {
      height: 34px;
      display: block;
    }

    .brand-divider {
      width: 36px;
      height: 3px;
      background: var(--gold);
      margin: 0 auto 1.25rem;
    }

    .brand-tagline {
      font-size: 13.5px;
      color: rgba(255,255,255,0.55);
      line-height: 1.75;
      text-align: center;
      max-width: 210px;
      margin-bottom: 2.25rem;
    }

    .brand-feat {
      display: flex;
      flex-direction: column;
      gap: .875rem;
      width: 100%;
    }

    .feat-item {
      display: flex;
      align-items: flex-start;
      gap: 10px;
    }

    .feat-dot {
      width: 26px;
      height: 26px;
      border-radius: 50%;
      background: rgba(200,168,75,.15);
      border: 1px solid rgba(200,168,75,.35);
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      margin-top: 1px;
    }

    .feat-dot span {
      width: 7px;
      height: 7px;
      border-radius: 50%;
      background: var(--gold);
      display: block;
    }

    .feat-title {
      font-size: 13px;
      font-weight: 500;
      color: rgba(255,255,255,0.85);
      margin-bottom: 2px;
    }

    .feat-sub {
      font-size: 11px;
      color: rgba(255,255,255,0.40);
    }

    .back-link {
      margin-top: 2rem;
      font-size: 12px;
      color: rgba(255,255,255,.4);
      text-decoration: none;
      position: relative;
      z-index: 1;
      transition: color .2s;
    }

    .back-link:hover {
      color: var(--gold);
    }

    /* ── Panel derecho ── */
    .panel-form {
      flex: 1;
      background: #fff;
      display: flex;
      flex-direction: column;
      justify-content: center;
      padding: 3rem 2.75rem;
    }

    .form-heading {
      font-family: var(--font-display);
      font-size: 28px;
      font-weight: 700;
      color: var(--navy);
      letter-spacing: .3px;
      margin-bottom: .3rem;
    }

    .form-sub {
      font-size: 13px;
      color: var(--muted);
      margin-bottom: 2rem;
    }

    /* Alertas */
    .alert {
      padding: 10px 14px;
      border-radius: var(--radius);
      font-size: 13px;
      margin-bottom: 1.25rem;
      line-height: 1.5;
    }

    .alert-error {
      background: #fef2f2;
      color: var(--error);
      border: 1px solid #fecaca;
    }

    .alert-success {
      background: #f0fdf4;
      color: var(--success);
      border: 1px solid #bbf7d0;
    }

    /* Campos */
    .field {
      display: flex;
      flex-direction: column;
      gap: 4px;
      margin-bottom: 1.1rem;
    }

    label.lbl {
      font-size: 11px;
      font-weight: 600;
      color: var(--muted);
      text-transform: uppercase;
      letter-spacing: .06em;
    }

    input[type=email],
    input[type=password] {
      width: 100%;
      padding: 10px 13px;
      font-family: var(--font-body);
      font-size: 14px;
      color: var(--text);
      background: #f9fafb;
      border: 1px solid var(--border);
      border-radius: var(--radius);
      outline: none;
    }

    input[type=email]:focus,
    input[type=password]:focus {
      border-color: var(--navy);
      background: #fff;
      box-shadow: 0 0 0 3px rgba(0,51,102,.08);
    }

    /* Fila opciones */
    .opt-row {
      display: flex;
      align-items: center;
      justify-content: space-between;
      margin-bottom: 1.5rem;
    }

    .remember {
      display: flex;
      align-items: center;
      gap: 7px;
      font-size: 13px;
      color: var(--muted);
      cursor: pointer;
    }

    .remember input[type=checkbox] {
      width: 14px;
      height: 14px;
      accent-color: var(--navy);
    }

    .forgot {
      font-size: 13px;
      color: var(--navy);
      text-decoration: none;
      font-weight: 500;
    }

    .forgot:hover {
      text-decoration: underline;
    }

    /* Botón */
    .btn-submit {
      width: 100%;
      padding: 11px;
      background: var(--navy);
      color: #fff;
      border: none;
      border-radius: var(--radius);
      font-family: var(--font-display);
      font-size: 16px;
      font-weight: 700;
      letter-spacing: .5px;
      cursor: pointer;
      transition: background .2s, transform .1s;
    }

    .btn-submit:hover {
      background: var(--navy-light);
    }

    .btn-submit:active {
      transform: scale(.99);
    }

    .btn-submit:disabled {
      opacity: .6;
      cursor: not-allowed;
    }

    /* Separador */
    .sep {
      display: flex;
      align-items: center;
      gap: 12px;
      margin: 1.5rem 0;
    }

    .sep-line {
      flex: 1;
      height: 1px;
      background: var(--border);
    }

    .sep-txt {
      font-size: 12px;
      color: var(--muted);
    }

    /* Botones sociales */
    .social-row {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: .625rem;
    }

    .btn-social {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 7px;
      padding: 9px;
      border: 1px solid var(--border);
      border-radius: var(--radius);
      background: #f9fafb;
      color: var(--text);
      font-size: 13px;
      font-family: var(--font-body);
      font-weight: 500;
      cursor: pointer;
      transition: border-color .2s, background .2s;
    }

    .btn-social:hover {
      border-color: #9ca3af;
      background: #f3f4f6;
    }

    /* Banner distribuidor */
    .dist-banner {
      margin-top: 1.5rem;
      padding: 11px 14px;
      background: #f0f4fa;
      border-radius: var(--radius);
      border-left: 3px solid var(--gold);
    }

    .dist-banner p {
      font-size: 12.5px;
      color: var(--muted);
      line-height: 1.55;
      margin: 0;
    }

    .dist-banner a {
      color: var(--navy);
      font-weight: 600;
      text-decoration: none;
    }

    .dist-banner a:hover {
      text-decoration: underline;
    }

    /* ── Responsive ── */
    @media (max-width: 680px) {
      .page {
        flex-direction: column;
        max-width: 420px;
      }

      .panel-brand {
        flex: none;
        padding: 2rem 1.5rem;
      }

      .panel-form {
        padding: 2rem 1.5rem;
      }

      .social-row {
        grid-template-columns: 1fr;
      }
    }