/* =========================================================
   Bayanan Medical Clinic — Sign In Page Styles
   ========================================================= */

:root{
  --brand-dark:      #1F4A30;
  --brand-primary:   #2F7A50;
  --brand-mid:       #448B6C;
  --brand-light-bg:  #EAF7EF;
  --brand-pill-bg:   #C9F1DD;
  --text-muted-green:#7A9A8A;
  --font-display: 'Playfair Display', serif;
  --font-body: 'Nunito Sans', sans-serif;
}

html {
  height: 100%;
  overflow-x: hidden;
}

body{
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  font-family: var(--font-body);
  color:#222;
  margin:0;
}

@media (min-width: 992px) {
  html,
  body {
    overflow: hidden;
  }
}

.auth-modern-popup {
 position: fixed;
 right: 1.25rem;
 bottom: 1.25rem;
 z-index: 2000;
 display: flex;
 align-items: center;
 gap: 0.9rem;
 width: min(360px, calc(100vw - 2rem));
 padding: 1rem 1.1rem;
 border-radius: 18px;
 background: rgba(255,255,255,0.98);
 box-shadow: 0 18px 45px rgba(17, 36, 26, 0.18);
 border: 1px solid rgba(35, 74, 52, 0.08);
 opacity: 0;
 transform: translateY(18px) scale(0.97);
 transition: opacity 0.25s ease, transform 0.25s ease;
}

.auth-modern-popup.is-visible {
 opacity: 1;
 transform: translateY(0) scale(1);
}

.auth-modern-popup--success {
 border-left: 5px solid #2f7a50;
}

.auth-modern-popup--error {
 border-left: 5px solid #c93a3a;
}

.auth-modern-popup__icon {
 width: 42px;
 height: 42px;
 border-radius: 12px;
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.4rem;
 background: rgba(47, 122, 80, 0.1);
 color: #2f7a50;
 flex-shrink: 0;
}

.auth-modern-popup--error .auth-modern-popup__icon {
 background: rgba(201, 58, 58, 0.1);
 color: #c93a3a;
}

.auth-modern-popup__content {
 flex: 1;
}

.auth-modern-popup__title {
 font-size: 0.96rem;
 font-weight: 800;
 color: #1f2d26;
 margin-bottom: 0.15rem;
}

.auth-modern-popup__message {
 font-size: 0.85rem;
 line-height: 1.5;
 color: #54635d;
}

/* ---------- Navbar ---------- */
.navbar-logo {
  height: 40px;
  width: auto;
}

@media (min-width: 992px) {
  .navbar-logo {
    height: 52px; 
  }
}

.navbar-brand-text {
  font-family: var(--font-display);
  font-size: clamp(1rem, 0.9rem + 0.4vw, 1.6rem);
  color: #2b2b2b;
  line-height: 1.1;
}

.navbar-brand-sub {
  font-family: var(--font-body);
  font-size: 0.68rem;
  color: #8a8a8a;
  display: block;
}

.navbar-toggler-custom:hover{ background:#132a1b; }
.navbar-toggler-custom:focus{ box-shadow:none; }

.mobile-nav-menu{
  max-height:0;
  overflow:hidden;
  transition: max-height .25s ease;
  background:#fff;
  border-top:1px solid transparent;
}
.mobile-nav-menu.show{
  max-height:200px;
  border-top:1px solid #eee;
}
.mobile-nav-menu a{
  display:block;
  padding:.75rem 1.5rem;
  color:#333;
  text-decoration:none;
  font-weight:600;
}
.mobile-nav-menu a:hover{ background: var(--brand-light-bg); }

/* ---------- Auth layout ---------- */
.auth-page-wrap{
  display:flex;
  min-height: calc(100vh - 73px);
}
@media (max-width: 991.98px){
  .auth-page-wrap{ flex-direction: column; min-height:auto; }
}

/* Info panel */
.auth-info-panel{
  flex: 0 0 45%;
  max-width:45%;
  position:relative;
  overflow:hidden;
  background: radial-gradient(circle at 25% 20%, #6CDBAB 0%, #364631 100%);
  color:#fff;
  display:flex;
  align-items:center;
  padding: clamp(2rem, 3vw, 4rem);
}
.auth-info-panel::before{
  content:"";
  position:absolute;
  inset:0;
  background-image: radial-gradient(rgba(255,255,255,.18) 1px, transparent 1px);
  background-size: 22px 22px;
  pointer-events:none;
}
@media (max-width: 991.98px){
  .auth-info-panel{
    flex:none;
    max-width:100%;
    width:100%;
    padding: 2rem 1.5rem;
  }
}

.circle-decor{
  position:absolute;
  border:1px solid rgba(255,255,255,.25);
  border-radius:50%;
  pointer-events:none;
}
.circle-decor-1{ width:140px; height:140px; top:-40px; left:-40px; }
.circle-decor-2{ width:220px; height:220px; bottom:-80px; right:-60px; }

.auth-info-inner{ position:relative; z-index:1; max-width:34rem; }

.info-badge{
  color:#fff;
  font-size:clamp(0.95rem, 1vw, 1.15rem);
  display:inline-flex;
  align-items:center;
  gap:.4rem;
  padding: 0;
  font-weight: 600;
}
.info-badge .dot{
  width:6px;height:6px;border-radius:50%;
  background:#fff;
  display:inline-block;
}

.panel-logo{
  align-items:center;
  gap:.6rem;
  margin-top:1.5rem;
}
.panel-logo img{ width:40px; height:40px; }
.panel-logo span{
  font-family: var(--font-display);
  font-size:1.1rem;
  font-weight:600;
}

.auth-heading{
  font-family: var(--font-display);
  font-weight:500;
  font-size: clamp(1.9rem, 1.3rem + 2vw, 2.8rem);
  line-height:1.15;
}
.auth-heading em{ font-style:italic; color:#cdeede; }

.auth-copy{
  color:#dcece3;
  font-size: clamp(.95rem, .85rem + .3vw, 1.05rem);
}

.perk-list{
  list-style:none;
  padding:0;
  margin:0;
}
.perk-list li{
  display:flex;
  align-items:flex-start;
  gap:.6rem;
  margin-bottom:.75rem;
  font-size:.95rem;
  color:#eaf5ee;
}
.perk-list .dot{
  width:6px;height:6px;border-radius:50%;
  background:#fff;
  margin-top:.55rem;
  flex-shrink:0;
}

/* Form panel */
.auth-form-panel{
  flex:1;
  display:flex;
  align-items:center;
  justify-content:center;
  padding: clamp(2rem, 3vw, 4rem);
  background:#fff;
}
.auth-form-inner{
  width:100%;
  max-width:420px;
}
.form-title{
  font-family: var(--font-display);
  font-size:2rem;
  font-weight:600;
  margin-bottom:.25rem;
}
.form-subtitle{
  color:#8a8a8a;
  margin-bottom:2rem;
}
.form-label{
  font-size:.75rem;
  font-weight:700;
  letter-spacing:.03em;
  color:#555;
  text-transform:uppercase;
}
.form-control{
  border-radius:8px;
  border:1px solid #dcdcdc;
  padding:.7rem .9rem;
}
.form-control:focus{
  border-color: var(--brand-primary);
  box-shadow:0 0 0 .2rem rgba(47,122,80,.15);
}

.password-field{ position:relative; }
.password-field .form-control{ padding-right:2.6rem; }
.toggle-password{
  position:absolute;
  right:.6rem;
  top:50%;
  transform:translateY(-50%);
  background:none;
  border:none;
  color:#888;
  font-size:1.1rem;
}
.auth-form-panel .password-field .toggle-password:hover{
  transform:translateY(-50%) !important;
  box-shadow:none !important;
  filter:none !important;
}

.forgot-link{
  font-size:.85rem;
  color: var(--brand-primary);
  text-decoration:none;
  font-weight:600;
}
.forgot-link:hover{ text-decoration:underline; }

.btn-brand-fill{
  background: var(--brand-primary);
  color:#fff;
  border:none;
  border-radius:8px;
  padding:.85rem;
  font-weight:700;
  letter-spacing:.03em;
  transition: background 0.2s ease, transform 0.2s ease;
}
.btn-brand-fill:hover{ background:#26643f; color:#fff; transform: scale(1.05); }

.divider-row{
  display:flex;
  align-items:center;
  gap:1rem;
  color:#999;
  font-size:.85rem;
}
.divider-row span{
  flex:1;
  height:1px;
  background:#e2e2e2;
}

.switch-link{
  font-size:.9rem;
  color:#555;
}
.switch-link a{
  color: var(--brand-primary);
  font-weight:700;
  text-decoration:none;
}
.switch-link a:hover{ text-decoration:underline; }
/* =========================================================
   Forgot Password Modal
   ========================================================= */
.forgot-modal-content{
  border-radius: 20px;
  border: none;
}
.forgot-modal-logo{
  width: 56px;
  height: 56px;
}
.forgot-modal-title{
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.7rem;
  color: #1a1a1a;
  margin-bottom: .25rem;
}
.forgot-modal-subtitle{
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #8a8a8a;
}
.forgot-modal-message{
  font-size: .85rem;
  min-height: 1.2em;
  margin-bottom: 1rem;
  color: var(--brand-primary);
}
.forgot-modal-message.is-error{ color: #c0392b; }

/* =========================================================
  OTP Verification Modal
  ========================================================= */
.otp-verification-modal .modal-content {
 border: none;
 border-radius: 18px;
 box-shadow: 0 30px 60px rgba(15, 31, 21, 0.18);
}

.otp-modal-content {
 background: rgba(255,255,255,.96);
}

.otp-modal-logo {
 width: 56px;
 height: 56px;
}

.otp-modal-title {
 font-family: var(--font-display);
 font-size: clamp(1.5rem, 1.1rem + 1.1vw, 2.3rem);
 line-height: 1.2;
 letter-spacing: .02em;
 color: #1f1f1f;
 margin-bottom: .35rem;
 font-weight: 600;
}

.otp-modal-subtitle {
 color: #61786b;
 font-size: .82rem;
 font-weight: 700;
 letter-spacing: .04em;
 text-transform: uppercase;
 margin-bottom: 1.5rem;
}

.otp-input-row {
 display: flex;
 gap: .55rem;
 justify-content: center;
 margin-bottom: .9rem;
}

.otp-input {
 width: 48px;
 max-width: calc((100% - 2.75rem) / 6);
 height: 70px;
 text-align: center;
 border: 2px solid rgba(52, 130, 91, .25);
 border-radius: 12px;
 background: #e7f5eb;
 color: #1e3d2c;
 font-size: 2rem;
 padding: 0;
 font-weight: 700;
 transition: all .2s ease;
}

.otp-input:focus {
 outline: none;
 border-color: var(--brand-primary);
 box-shadow: 0 0 0 .2rem rgba(47,122,80,.15);
}

.otp-demo-code {
 color: #6a7d72;
 font-size: .8rem;
 font-weight: 700;
 margin-bottom: .6rem;
 letter-spacing: .03em;
}

.otp-error {
 min-height: 1.25rem;
 margin-bottom: .9rem;
 color: #d94b47;
 font-weight: 700;
 font-size: .85rem;
}

.otp-submit-btn {
 display: block;
 width: 100%;
 max-width: 150px;
 margin: 0 auto 1rem auto;
 border-radius: 50px;
 border: 2px solid #1a1a1a;
 background: #fff;
 color: #1a1a1a;
 font-weight: 700;
 letter-spacing: .04em;
 padding: .75rem 1.2rem;
}

.otp-submit-btn:hover {
 background: #f5f5f5;
 color: #1a1a1a;
}

.otp-resend-btn {
 border: none;
 background: transparent;
 color: #1d1d1d;
 font-weight: 700;
 text-transform: none;
 text-decoration: none;
 padding: 0;
}

.otp-resend-btn:hover {
 color: var(--brand-primary);
}

@media (max-width: 575.98px) {
 .otp-input {
   width: 62px;
   height: 62px;
   font-size: 1.7rem;
 }
}

@media (min-width: 992px) and (max-height: 850px) {
  html,
  body {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .auth-page-wrap {
    min-height: calc(100vh - 95px);
  }

  .auth-info-panel,
  .auth-form-panel {
    padding-block: clamp(0.85rem, 2.5vh, 1.5rem);
  }

  .auth-info-panel {
    padding-inline: clamp(1.25rem, 2.5vw, 2.5rem);
  }

  .auth-form-panel {
    padding-inline: clamp(1.25rem, 2.5vw, 2.5rem);
  }

  .auth-info-inner .info-badge {
    margin-bottom: 0.75rem !important;
  }

  .auth-info-inner .panel-logo {
    margin-top: 0.75rem;
  }

  .auth-heading {
    font-size: clamp(1.55rem, 4.5vh, 2.3rem);
  }

  .auth-copy {
    font-size: clamp(0.85rem, 1.9vh, 0.98rem);
    margin-top: 0.5rem !important;
  }

  .perk-list.mt-4 {
    margin-top: 0.85rem !important;
  }

  .perk-list li {
    font-size: clamp(0.78rem, 1.8vh, 0.9rem);
    margin-bottom: 0.4rem;
  }

  .form-title {
    font-size: clamp(1.55rem, 3.8vh, 2rem);
  }

  .form-subtitle {
    margin-bottom: 1.1rem;
  }

  .auth-form-inner .form-control {
    padding: 0.58rem 0.8rem;
  }

  .auth-form-inner .text-end.mb-4 {
    margin-bottom: 0.9rem !important;
  }

  .auth-form-inner .divider-row {
    margin-block: 0.9rem !important;
  }

  .auth-form-inner .btn-brand-fill {
    padding: 0.68rem;
  }
}
