  *,
  *::before,
  *::after {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
  }

  :root {
      --bg: #0a0c10;
      --panel: #10131a;
      --border: rgba(255, 255, 255, 0.07);
      --gold: #c9a96e;
      --gold-light: #e8c98a;
      --text: #e8e4dc;
      --muted: #6b7280;
      --input-bg: #161922;
      --error: #e05252;
      --error-bg: rgba(224, 82, 82, 0.08);
      --error-border: rgba(224, 82, 82, 0.25);
  }

  body {
      font-family: 'DM Sans', sans-serif;
      background: var(--bg);
      min-height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      color: var(--text);
  }

  body::before {
      content: '';
      position: fixed;
      inset: 0;
      background:
          radial-gradient(ellipse 60% 50% at 70% 20%, rgba(201, 169, 110, 0.06) 0%, transparent 60%),
          radial-gradient(ellipse 40% 60% at 10% 80%, rgba(99, 120, 180, 0.05) 0%, transparent 50%);
      pointer-events: none;
  }

  body::after {
      content: '';
      position: fixed;
      inset: 0;
      background-image:
          linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
          linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
      background-size: 48px 48px;
      pointer-events: none;
  }

  .container {
      display: flex;
      width: 900px;
      max-width: 96vw;
      min-height: 540px;
      border: 1px solid var(--border);
      border-radius: 2px;
      overflow: hidden;
      position: relative;
      z-index: 1;
      box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(201, 169, 110, 0.08);
      animation: fadeUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  @keyframes fadeUp {
      from {
          opacity: 0;
          transform: translateY(24px);
      }

      to {
          opacity: 1;
          transform: translateY(0);
      }
  }

  /* ── Brand Panel ── */
  .brand-panel {
      width: 42%;
      background: linear-gradient(160deg, #13161f 0%, #0d0f15 100%);
      border-right: 1px solid var(--border);
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      padding: 52px 44px;
      position: relative;
      overflow: hidden;
  }

  .brand-panel::before {
      content: '';
      position: absolute;
      top: -80px;
      right: -80px;
      width: 300px;
      height: 300px;
      border-radius: 50%;
      background: radial-gradient(circle, rgba(201, 169, 110, 0.08) 0%, transparent 70%);
      pointer-events: none;
  }

  .brand-panel::after {
      content: '';
      position: absolute;
      bottom: 60px;
      left: -60px;
      width: 220px;
      height: 220px;
      border-radius: 50%;
      background: radial-gradient(circle, rgba(99, 120, 180, 0.06) 0%, transparent 70%);
      pointer-events: none;
  }

  .logo {
      display: flex;
      align-items: center;
      gap: 12px;
      animation: fadeUp 0.7s 0.1s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .logo-mark {
      width: 38px;
      height: 38px;
      border: 1.5px solid var(--gold);
      display: flex;
      align-items: center;
      justify-content: center;
      position: relative;
  }

  .logo-mark::before {
      content: '';
      position: absolute;
      inset: 4px;
      border: 1px solid rgba(201, 169, 110, 0.3);
  }

  .logo-mark svg {
      width: 16px;
      height: 16px;
      fill: var(--gold);
  }

  .logo-name {
      font-family: 'Cormorant Garamond', serif;
      font-size: 22px;
      font-weight: 600;
      letter-spacing: 3px;
      color: var(--text);
      text-transform: uppercase;
  }

  .brand-content {
      animation: fadeUp 0.7s 0.2s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .brand-tagline {
      font-family: 'Cormorant Garamond', serif;
      font-size: 32px;
      font-weight: 300;
      line-height: 1.3;
      color: var(--text);
      margin-bottom: 20px;
      letter-spacing: 0.5px;
  }

  .brand-tagline em {
      color: var(--gold);
      font-style: normal;
  }

  .brand-desc {
      font-size: 13px;
      color: var(--muted);
      line-height: 1.7;
      font-weight: 300;
      max-width: 220px;
  }

  /* ── Form Panel ── */
  .form-panel {
      flex: 1;
      background: var(--panel);
      display: flex;
      flex-direction: column;
      justify-content: center;
      padding: 52px 48px;
  }

  .form-header {
      margin-bottom: 28px;
      animation: fadeUp 0.7s 0.15s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .form-header h2 {
      font-family: 'Cormorant Garamond', serif;
      font-size: 28px;
      font-weight: 400;
      color: var(--text);
      margin-bottom: 6px;
      letter-spacing: 0.5px;
  }

  .form-header p {
      font-size: 13px;
      color: var(--muted);
      font-weight: 300;
  }

  /* ── Alert ── */
  .alert {
      display: flex;
      align-items: flex-start;
      gap: 11px;
      background: var(--error-bg);
      border: 1px solid var(--error-border);
      border-left: 3px solid var(--error);
      border-radius: 2px;
      padding: 12px 14px;
      margin-bottom: 22px;
      animation: alertIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
      position: relative;
  }

  @keyframes alertIn {
      from {
          opacity: 0;
          transform: translateY(-8px) scaleY(0.95);
      }

      to {
          opacity: 1;
          transform: translateY(0) scaleY(1);
      }
  }

  .alert-icon {
      flex-shrink: 0;
      width: 16px;
      height: 16px;
      margin-top: 1px;
  }

  .alert-icon svg {
      width: 16px;
      height: 16px;
      stroke: var(--error);
      fill: none;
      stroke-width: 2;
      stroke-linecap: round;
      stroke-linejoin: round;
  }

  .alert-text {
      font-size: 13px;
      color: #f0a0a0;
      line-height: 1.5;
      font-weight: 400;
      flex: 1;
  }

  .alert-close {
      background: none;
      border: none;
      cursor: pointer;
      padding: 0;
      color: rgba(240, 160, 160, 0.5);
      display: flex;
      align-items: center;
      transition: color 0.2s;
      flex-shrink: 0;
  }

  .alert-close:hover {
      color: #f0a0a0;
  }

  .alert-close svg {
      width: 14px;
      height: 14px;
      stroke: currentColor;
      fill: none;
      stroke-width: 2;
      stroke-linecap: round;
  }

  /* ── Fields ── */
  .field {
      margin-bottom: 20px;
      animation: fadeUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .field:nth-child(1) {
      animation-delay: 0.2s;
  }

  .field:nth-child(2) {
      animation-delay: 0.25s;
  }

  label {
      display: block;
      font-size: 11px;
      letter-spacing: 2px;
      text-transform: uppercase;
      color: var(--muted);
      margin-bottom: 8px;
      font-weight: 500;
  }

  .input-wrap {
      position: relative;
  }

  .input-wrap>svg {
      position: absolute;
      left: 14px;
      top: 50%;
      transform: translateY(-50%);
      width: 15px;
      height: 15px;
      stroke: var(--muted);
      fill: none;
      stroke-width: 1.5;
      stroke-linecap: round;
      stroke-linejoin: round;
      transition: stroke 0.2s;
      pointer-events: none;
  }

  input[type="email"],
  input[type="password"],
  input[type="text"] {
      width: 100%;
      background: var(--input-bg);
      border: 1px solid var(--border);
      border-radius: 2px;
      padding: 13px 14px 13px 42px;
      font-family: 'DM Sans', sans-serif;
      font-size: 14px;
      font-weight: 300;
      color: var(--text);
      outline: none;
      transition: border-color 0.2s, box-shadow 0.2s;
      letter-spacing: 0.3px;
  }

  /* Inputs con error heredan borde rojo */
  .field.has-error input {
      border-color: var(--error-border);
  }

  input::placeholder {
      color: rgba(107, 114, 128, 0.6);
  }

  input:focus {
      border-color: rgba(201, 169, 110, 0.4);
      box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.05);
  }

  .input-wrap:has(input:focus)>svg {
      stroke: var(--gold);
  }

  .pass-toggle {
      position: absolute;
      right: 14px;
      top: 50%;
      transform: translateY(-50%);
      background: none;
      border: none;
      cursor: pointer;
      padding: 2px;
      display: flex;
      align-items: center;
      color: var(--muted);
      transition: color 0.2s;
  }

  .pass-toggle:hover {
      color: var(--text);
  }

  .pass-toggle svg {
      width: 15px;
      height: 15px;
      stroke: currentColor;
      fill: none;
      stroke-width: 1.5;
      stroke-linecap: round;
      stroke-linejoin: round;
  }

  /* ── Button ── */
  .btn-login {
      width: 100%;
      padding: 14px;
      background: var(--gold);
      border: none;
      border-radius: 2px;
      font-family: 'DM Sans', sans-serif;
      font-size: 13px;
      font-weight: 500;
      letter-spacing: 2.5px;
      text-transform: uppercase;
      color: #0a0c10;
      cursor: pointer;
      transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
      position: relative;
      overflow: hidden;
      animation: fadeUp 0.7s 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .btn-login::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(to bottom, rgba(255, 255, 255, 0.12), transparent);
  }

  .btn-login:hover {
      background: var(--gold-light);
      box-shadow: 0 6px 24px rgba(201, 169, 110, 0.25);
      transform: translateY(-1px);
  }

  .btn-login:active {
      transform: translateY(0);
  }

  /* ── Forgot link ── */
  .forgot-wrap {
      text-align: right;
      margin-bottom: 24px;
      animation: fadeUp 0.7s 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .forgot-link {
      font-size: 12px;
      color: var(--gold);
      text-decoration: none;
      transition: color 0.2s;
      letter-spacing: 0.3px;
  }

  .forgot-link:hover {
      color: var(--gold-light);
  }

  @media (max-width: 640px) {
      .brand-panel {
          display: none;
      }

      .form-panel {
          padding: 40px 28px;
      }

      .container {
          min-height: auto;
      }
  }