@font-face {
  font-family: 'INGMe';
  src: url('../fonts/INGMeWeb-Regular.woff') format('woff');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'INGMe';
  src: url('../fonts/INGMeWeb-Bold.woff') format('woff');
  font-weight: bold;
  font-style: normal;
  font-display: swap;
}

:root {
  --ing-orange: #ff6200;
  --ing-orange-hover: #e55800;
  --ing-orange-active: #cc4e00;
  --ing-text: #333333;
  --ing-text-secondary: #525252;
  --ing-bg: #ececee;
  --ing-border: #767676;
  --ing-link: #1363a8;
  --ing-white: #ffffff;
  --ing-error: #d70101;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: INGMe, arial, helvetica, sans-serif;
  background-color: var(--ing-bg);
  color: var(--ing-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

input, button, select, textarea {
  font-family: INGMe, arial, helvetica, sans-serif;
}

/* Header */
header {
  background-color: var(--ing-white);
  height: 68px;
  width: 100%;
  border-bottom: 1px solid #e1e3e6;
  display: flex;
  align-items: center;
  padding: 0 44px;
  z-index: 10;
}

.header-logo {
  height: 42px;
  display: block;
}

.header-logo img {
  height: 100%;
  width: auto;
  object-fit: contain;
}

/* Main Container */
main {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 34px 16px 48px;
  position: relative;
  z-index: 2;
}

/* Lion Watermark in bottom right */
.lion-watermark {
  position: fixed;
  bottom: 0;
  right: 0;
  height: 460px;
  width: auto;
  max-width: 48vw;
  pointer-events: none;
  z-index: 1;
  user-select: none;
  opacity: 0.95;
}

/* Card */
.login-card {
  background: var(--ing-white);
  border-radius: 8px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
  width: 560px;
  min-height: 608px;
  max-width: 100%;
  padding: 42px 40px 36px;
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.login-card form {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-title {
  font-size: 24px;
  font-weight: 400;
  color: var(--ing-text);
  line-height: 1.25;
  margin-bottom: 26px;
}

/* Alert Message */
.form-alert {
  padding: 10px 14px;
  border-radius: 4px;
  margin-bottom: 18px;
  font-size: 13.5px;
}

.form-alert-success {
  background-color: #def7ec;
  color: #03543f;
  border: 1px solid #84e1bc;
}

/* Radio Group: Elige tu documento */
.radio-section {
  margin-bottom: 20px;
}

.section-label {
  display: block;
  font-size: 14px;
  color: var(--ing-text);
  margin-bottom: 10px;
}

.radio-options {
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.radio-label {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  font-size: 14px;
  color: var(--ing-text);
  user-select: none;
}

.radio-label input[type="radio"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.radio-custom {
  width: 19px;
  height: 19px;
  border: 2px solid #767676;
  border-radius: 50%;
  margin-right: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease-in-out;
  flex-shrink: 0;
}

.radio-custom::after {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: transparent;
  transition: background-color 0.15s ease-in-out;
}

.radio-label input[type="radio"]:checked + .radio-custom {
  border-color: var(--ing-orange);
}

.radio-label input[type="radio"]:checked + .radio-custom::after {
  background-color: var(--ing-orange);
}

/* Document Number Field */
.field-group {
  margin-bottom: 20px;
}

.field-label {
  display: block;
  font-size: 14px;
  color: var(--ing-text);
  margin-bottom: 7px;
}

.input-text {
  width: 100%;
  height: 46px;
  border: 1px solid var(--ing-border);
  border-radius: 4px;
  padding: 0 12px;
  font-size: 15px;
  color: var(--ing-text);
  background-color: var(--ing-white);
  transition: border-color 0.2s;
}

.input-text::placeholder {
  color: #767676;
  font-size: 14px;
}

.input-text:focus {
  outline: none;
  border-color: #333333;
}

/* Birthdate Segmented Box */
.birthdate-container {
  width: 100%;
  height: 46px;
  border: 1px solid var(--ing-border);
  border-radius: 4px;
  display: flex;
  align-items: center;
  background-color: var(--ing-white);
  transition: border-color 0.2s;
  overflow: hidden;
}

.birthdate-container:focus-within {
  outline: none;
  border-color: #333333;
}

.birthdate-input {
  border: none;
  outline: none;
  height: 100%;
  font-size: 15px;
  color: var(--ing-text);
  text-align: left;
  background: transparent;
  padding: 0 12px;
  width: 33.333%;
  flex: 1;
}

.birthdate-input::placeholder {
  color: #767676;
  font-size: 14px;
}

.birthdate-divider {
  width: 1px;
  height: 24px;
  background-color: #8c8c8c;
  flex-shrink: 0;
}

/* Error States */
.input-text.has-error,
.birthdate-container.has-error {
  border-color: var(--ing-error) !important;
}

.field-error-msg {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 6px;
  font-size: 13.5px;
  color: var(--ing-text);
  line-height: 1.25;
}

.error-circle-icon {
  width: 16px;
  height: 16px;
  background-color: var(--ing-error);
  color: #ffffff;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
}

/* Checkbox "Recordar" */
.checkbox-section {
  display: flex;
  align-items: center;
  margin-top: 16px;
  margin-bottom: 22px;
}

.checkbox-label {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  font-size: 15px;
  color: var(--ing-text);
  user-select: none;
}

.checkbox-custom-input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
}

.checkbox-box {
  width: 20px;
  height: 20px;
  border: 1.5px solid #666666;
  border-radius: 5px;
  margin-right: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #fff;
  transition: all 0.15s;
}

.checkbox-box svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.5;
  display: none;
}

.checkbox-custom-input:checked + .checkbox-box {
  background-color: var(--ing-orange);
  border-color: var(--ing-orange);
}

.checkbox-custom-input:checked + .checkbox-box svg {
  display: block;
}

/* Question Mark Circle */
.help-tooltip-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--ing-orange);
  color: var(--ing-orange);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  margin-left: 8px;
  cursor: pointer;
  position: relative;
  user-select: none;
}

.help-tooltip-trigger:hover::after {
  content: "Recuerda tu documento en este dispositivo para agilizar futuros accesos.";
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background-color: #2b2b2b;
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: normal;
  width: 210px;
  text-align: center;
  line-height: 1.35;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  z-index: 30;
  pointer-events: none;
}

/* Submit Button */
.submit-btn {
  width: 100%;
  height: 48px;
  background-color: var(--ing-orange);
  color: var(--ing-white);
  border: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s ease-in-out, transform 0.05s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.submit-btn:hover {
  background-color: var(--ing-orange-hover);
}

.submit-btn:active {
  background-color: var(--ing-orange-active);
  transform: scale(0.99);
}

/* Security Link */
.security-link-wrapper {
  margin-top: 22px;
  display: flex;
  align-items: center;
}

.security-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ing-link);
  font-size: 14px;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  transition: color 0.15s;
}

.security-link:hover {
  color: #0b4b84;
}

.chevron-svg {
  width: 14px;
  height: 14px;
  fill: var(--ing-orange);
  flex-shrink: 0;
}

.external-icon {
  width: 13px;
  height: 13px;
  fill: currentColor;
  margin-left: 2px;
  flex-shrink: 0;
}

/* Tablet (641px – 1024px) */
@media (min-width: 641px) and (max-width: 1024px) {
  .login-card {
    width: 600px;
    padding: 42px 48px 36px;
  }
}

/* Responsive Design (Mobile) */
@media (max-width: 640px) {
  header {
    padding: 0 24px;
    height: 60px;
  }

  .header-logo {
    height: 38px;
  }

  main {
    padding: 24px 16px 50px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
  }

  .login-card {
    width: 100%;
    max-width: 440px;
    height: auto !important;
    min-height: auto !important;
    padding: 38px 28px 36px;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  }

  .card-title {
    font-size: 24px;
    margin-bottom: 28px;
  }

  .radio-section {
    margin-bottom: 24px;
  }

  .section-label {
    font-size: 14.5px;
    margin-bottom: 12px;
  }

  .radio-options {
    gap: 14px;
  }

  .radio-label {
    font-size: 15px;
  }

  .field-group {
    margin-bottom: 24px;
  }

  .field-label {
    font-size: 14.5px;
    margin-bottom: 8px;
  }

  .input-text {
    height: 50px;
    font-size: 15.5px;
    padding: 0 14px;
  }

  .birthdate-container {
    height: 50px;
  }

  .birthdate-input {
    font-size: 15.5px;
    padding: 0 14px;
  }

  .birthdate-divider {
    height: 26px;
  }

  .checkbox-section {
    margin-top: 20px;
    margin-bottom: 28px;
  }

  .checkbox-label {
    font-size: 15.5px;
  }

  .submit-btn {
    height: 50px;
    font-size: 17px;
    border-radius: 6px;
  }

  .security-link-wrapper {
    margin-top: 26px;
  }

  .security-link {
    font-size: 15px;
  }

  .lion-watermark {
    height: 380px;
    max-width: 90vw;
    bottom: 0;
    right: 0;
  }
}
