﻿@charset "UTF-8";
/*------------------------------------------------------------------
 Login Page Styles - Simplified
 Project: Caja Honor Portal
-------------------------------------------------------------------*/

/* === CSS Variables === */
:root {
  --primary-color: #0f1f67;
  --primary-hover: #0c1952;
  --success-color: #23af47;
  --danger-color: #e94437;
  --text-color: #1c2c42;
  --bg-color: #f4f5f7;
  --white: #ffffff;
  --border-color: #e0e0e0;
  --border-radius: 0.375rem;
}

/* === Reset & Base === */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text-color);
  background-color: var(--bg-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--text-color);
}

h4 {
  font-size: 1.5rem;
}

h6 {
  font-size: 1rem;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--success-color);
}

img {
  vertical-align: middle;
  max-width: 100%;
  height: auto;
}

button {
  border-radius: 0;
  cursor: pointer;
}

button:focus:not(:focus-visible) {
  outline: 0;
}

input,
button,
select,
textarea {
  margin: 0;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

/* === Layout === */
.container-scroller {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container-fluid {
  width: 100%;
  padding-right: 15px;
  padding-left: 15px;
  margin-right: auto;
  margin-left: auto;
}

.page-body-wrapper {
  min-height: calc(100vh - 56px);
  display: flex;
  flex-direction: row;
  padding-left: 0;
  padding-right: 0;
}

.page-body-wrapper.full-page-wrapper {
  width: 100%;
  min-height: 100vh;
}

.main-panel {
  transition: width 0.25s ease, margin 0.25s ease;
  width: 100%;
  min-height: calc(100vh - 56px);
  display: flex;
  flex-direction: column;
}

.content-wrapper {
  background: var(--bg-color);
  padding: 2.75rem 1.5rem;
  width: 100%;
  flex-grow: 1;
}

.content-wrapper.auth {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
}

/* === Grid System === */
.row {
  display: flex;
  flex-wrap: wrap;
  margin-right: -15px;
  margin-left: -15px;
}

.col-lg-4 {
  position: relative;
  width: 100%;
  padding-right: 15px;
  padding-left: 15px;
  max-width: 540px;
  margin: 0 auto;
}

@media (min-width: 992px) {
  .col-lg-4 {
    flex: 0 0 33.333333%;
    max-width: 33.333333%;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .col-lg-4 {
    max-width: 500px;
  }
}

@media (max-width: 767px) {
  .col-lg-4 {
    max-width: 100%;
  }
}

/* === Utility Classes === */
.w-100 {
  width: 100% !important;
}

.mx-0 {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.mx-auto {
  margin-left: auto !important;
  margin-right: auto !important;
}

.mx-2 {
  margin-left: 0.5rem !important;
  margin-right: 0.5rem !important;
}

.mt-2 {
  margin-top: 0.5rem !important;
}

.mt-3 {
  margin-top: 1rem !important;
}

.mt-4 {
  margin-top: 1.5rem !important;
}

.mb-0 {
  margin-bottom: 0 !important;
}

.px-0 {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.px-4 {
  padding-left: 1.5rem !important;
  padding-right: 1.5rem !important;
}

.py-5 {
  padding-top: 3rem !important;
  padding-bottom: 3rem !important;
}

.pt-3 {
  padding-top: 1rem !important;
}

@media (min-width: 576px) {
  .px-sm-5 {
    padding-left: 3rem !important;
    padding-right: 3rem !important;
  }
}

.d-flex {
  display: flex !important;
}

.d-grid {
  display: grid !important;
}

.align-items-center {
  align-items: center !important;
}

.justify-content-center {
  justify-content: center !important;
}

.text-start {
  text-align: left !important;
}

.text-center {
  text-align: center !important;
}

.text-danger {
  color: var(--danger-color) !important;
}

.fw-light {
  font-weight: 300 !important;
}

.font-weight-medium {
  font-weight: 500 !important;
}

.gap-2 {
  gap: 0.5rem !important;
}

/* === Auth Form === */
.auth-form-light {
  background: var(--white);
  padding: 3rem 2rem;
  border-radius: 0.5rem;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.08);
}

.brand-logo {
  text-align: center;
  margin-bottom: 2rem;
}

.brand-logo img {
  max-width: 250px;
  height: auto;
}

.login-title {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

/* === Forms === */
.form-group {
  margin-bottom: 1.5rem;
}

.cmxform {
  width: 100%;
}

.form-control,
.form-control-lg {
  display: block;
  width: 100%;
  padding: 0.875rem 1.375rem;
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text-color);
  background-color: var(--white);
  background-clip: padding-box;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  appearance: none;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus,
.form-control-lg:focus {
  color: var(--text-color);
  background-color: var(--white);
  border-color: var(--primary-color);
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(15, 31, 103, 0.25);
}

.form-control::placeholder {
  color: #979797;
  opacity: 1;
}

.form-control:disabled {
  background-color: #e9ecef;
  opacity: 1;
}

/* === Buttons === */
.btn {
  display: inline-block;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text-color);
  text-align: center;
  text-decoration: none;
  vertical-align: middle;
  cursor: pointer;
  user-select: none;
  background-color: transparent;
  border: 1px solid transparent;
  padding: 0.625rem 1.625rem;
  font-size: 0.875rem;
  border-radius: var(--border-radius);
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.btn:hover {
  text-decoration: none;
}

.btn:focus {
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(15, 31, 103, 0.25);
}

.btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.btn-primary {
  color: var(--white);
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  color: var(--white);
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
}

.btn-primary:focus {
  color: var(--white);
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
  box-shadow: 0 0 0 0.2rem rgba(15, 31, 103, 0.5);
}

.btn-primary:disabled {
  color: var(--white);
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-lg {
  padding: 1rem 3rem;
  font-size: 0.875rem;
  border-radius: var(--border-radius);
}

.btn-block {
  display: block;
  width: 100%;
}

.auth-form-btn {
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

/* === Form Links === */
.form-links {
  font-size: 0.875rem;
  color: var(--text-color);
}

.link-registration,
.link-password {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
  font-weight: 500;
}

.link-registration:hover,
.link-password:hover {
  color: var(--success-color);
  text-decoration: underline;
}

/* === Validation Messages === */
.login-error-message {
  font-size: 0.875rem;
  padding: 0.75rem 1rem;
  background-color: #fef2f2;
  border-left: 4px solid var(--danger-color);
  border-radius: var(--border-radius);
  color: var(--danger-color);
}

.login-error-message ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

/* === reCAPTCHA === */
#recaptcha-wrapper {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
  max-width: 100%;
}

#recaptcha-wrapper > div {
  display: inline-block;
  max-width: 100%;
}

.g-recaptcha {
  display: inline-block !important;
  margin: 0 auto;
  max-width: 304px;
}

/* Centrar el iframe del reCAPTCHA */
.g-recaptcha > div,
.g-recaptcha iframe {
  margin: 0 auto;
  display: block;
  max-width: 100%;
}

#recaptcha-error {
  width: 100%;
  text-align: center;
}

/* === Responsive Design === */
@media (max-width: 991px) {
  .auth-form-light {
    padding: 2rem 1.5rem;
  }

  .login-title {
    font-size: 1.5rem;
  }

  .brand-logo img {
    max-width: 220px;
  }
}

/* Escalado del reCAPTCHA para pantallas medianas-grandes */
@media (max-width: 991px) and (min-width: 650px) {
  #recaptcha-wrapper {
    transform: scale(0.92);
    transform-origin: center center;
    padding: 0.25rem 0;
  }
}

/* Escalado del reCAPTCHA para pantallas medianas */
@media (max-width: 649px) and (min-width: 576px) {
  #recaptcha-wrapper {
    transform: scale(0.85);
    transform-origin: center center;
    padding: 0.5rem 0;
  }
}

@media (max-width: 767px) {
.content-wrapper.auth {
  padding: 1rem 0.5rem !important;
}

.auth-form-light {
  padding: 1.5rem 1.25rem;
  overflow-x: hidden;
}

.login-title {
  font-size: 1.375rem;
}

.brand-logo {
  margin-bottom: 1.5rem;
}

.brand-logo img {
  max-width: 200px;
}

  .form-control-lg {
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
  }

  .btn-lg {
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
  }

  .form-links {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
  }

  .form-links .mx-2 {
    display: none;
  }

  /* reCAPTCHA para tablets pequeñas */
  #recaptcha-wrapper {
    transform: scale(0.88);
    transform-origin: center center;
    padding: 0.5rem 0;
  }
}

@media (max-width: 575px) {
  .page-body-wrapper {
    padding: 0;
  }

  .content-wrapper.auth {
    padding: 0.75rem 0.5rem !important;
    min-height: 100vh;
  }

  .row.w-100 {
    margin: 0 !important;
  }

  .col-lg-4 {
    padding: 0 0.75rem;
  }

  .auth-form-light {
    padding: 1.5rem 1rem;
  }

  .brand-logo {
    margin-bottom: 1.25rem;
  }

  .brand-logo img {
    max-width: 180px;
  }

  .login-title {
    font-size: 1.25rem;
  }

  h6.fw-light {
    font-size: 0.875rem;
    margin-bottom: 1rem;
  }

  .form-group {
    margin-bottom: 1rem;
  }

  .form-control-lg {
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
  }

  .btn-lg {
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
  }

  .py-5 {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
  }

  .form-links {
    font-size: 0.8125rem;
  }

  .login-error-message {
    font-size: 0.8125rem;
    padding: 0.625rem;
  }

  /* reCAPTCHA responsive */
  #recaptcha-wrapper {
    transform: scale(0.95);
    transform-origin: center center;
  }

  /* Prevenir zoom en iOS */
  input[type="text"],
  input[type="password"] {
    font-size: 16px !important;
  }
}

@media (max-width: 375px) {
.auth-form-light {
  padding: 1.25rem 0.75rem;
}

.brand-logo img {
  max-width: 160px;
}

  .login-title {
    font-size: 1.125rem;
  }

  h6.fw-light {
    font-size: 0.8125rem;
  }

  /* reCAPTCHA m�s peque�o */
  #recaptcha-wrapper {
    transform: scale(0.85);
    transform-origin: center center;
  }
}

@media (max-width: 767px) and (orientation: landscape) {
.content-wrapper.auth {
  padding: 0.5rem !important;
}

.auth-form-light {
  padding: 1rem;
}

.brand-logo {
  margin-bottom: 0.75rem;
}

.brand-logo img {
  max-width: 140px;
}

  .login-title {
    font-size: 1.125rem;
  }

  .py-5 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
  }
}
