/* navy : #1d3557 */
/* one : #457b9d */
/* two : #a8dadc */
/* red : #e63946 */

/* Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #e0f2f1;
}

/* Layout */
.login-wrapper {
  display: flex;
  height: 100vh;
  width: 100%;
}

/* Left Side */
.login-left {
  flex: 1;
  background-color: #457b9d;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.illustration {
  text-align: center;
  max-width: 100%; /* allow full space */
}

.illustration img {
  width: 90%;
  max-width: 470px; /* increase size */
  height: auto;
  opacity: 0.8;
}


/* Right Side */
.login-right {
  flex: 1;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px;
}

/* Enhanced Brand Heading */
.login-right h2.brand {
  font-family: 'Segoe UI', sans-serif;
  font-size: 30px;
  font-weight: bold;
  color: #1d3557;
  margin-bottom: 6px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Enhanced Subheading */
.login-right .subtitle {
  font-size: 12px;
  font-weight: 500;
  color: #457b9d;
  margin-bottom: 30px;
  letter-spacing: 0.3px;
}


.login-right h3 {
  font-size: 20px;
  margin-bottom: 30px;
  color: #333;
}

/* Form */
input {
  display: block;
  margin: 15px 0;
  padding: 12px;
  width: 100%;
  border: 1px solid #cbd5e1;
  font-size: 14px;
  transition: 0.3s ease;
}

input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.inline-fields {
  display: flex;
  gap: 10px;
  margin: 15px 0;
}

.inline-fields input {
  flex: 1;
  margin: 0; /* remove default vertical margins */
}
#register-age { flex: 0.5; }    /* smaller */
#register-town,
#register-state { flex: 1; }    /* wider */

select#time-zone {
  display: block;
  margin: 15px 0;
  padding: 12px;
  width: 100%;
  border: 1px solid #cbd5e1;
  font-size: 14px;
  background-color: #fff;
  color: #333;
  transition: 0.3s ease;
}

select#time-zone:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}


.password-wrapper {
  position: relative;
  width: 100%;
}

.password-wrapper input {
  padding-right: 40px;
}

.toggle-password {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  cursor: pointer;
  color: #444;
  font-size: 16px;
}

.forgot-link {
  font-size: 13px;
  color: #457b9d;
  text-align: right;
  display: block;
  margin: 6px 0 16px;
  text-decoration: none;
}

.forgot-link:hover {
  text-decoration: underline;
}

button {
  background-color: #e63946;
  color: white;
  padding: 12px;
  border: none;
  width: 100%;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: background 0.3s ease;
}

button:hover {
  background-color: #457b9d;
}

.separator {
  text-align: center;
  margin: 20px 0;
  font-size: 14px;
  color: #888;
}

/* Footer */
.form-footer {
  text-align: center;
  font-size: 14px;
}

.form-footer a {
  color: #457b9d;
  text-decoration: none;
}

.form-footer a:hover {
  text-decoration: underline;
}

.form-footer-reset{
  padding-top:20px;
}

/* Responsive */

/* ===== MOBILE (≤768px): Login + Register ===== */
@media (max-width: 768px) {
  /* Page stack + safe spacing */
  .login-wrapper {
    flex-direction: column;
    min-height: 100dvh;
    padding: 0;
    background: #e0f2f1;
  }

  /* Teal logo header band (keeps light logos visible) */
  .login-left {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 160px;                 /* compact header */
    padding: 0;
    background: #457b9d;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
    margin: 0 0 12px 0;            /* gap below header */
  }
  .illustration { width: 100%; text-align: center; }
  .illustration img {
    max-width: 160px;
    height: auto;
    opacity: 1 !important;         /* override desktop 0.8 */
    display: block;
    margin: 0 auto;
  }

  /* Centered card for the form/content */
  .login-right {
    width: 100%;
    max-width: 420px;
    margin: 0 auto 16px;
    padding: 24px 18px calc(18px + env(safe-area-inset-bottom));
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  /* Headings */
  .login-right h2.brand {
    font-size: 22px;
    text-align: center;
    margin-bottom: 2px;
    letter-spacing: .3px;
  }
  .login-right .subtitle {
    font-size: 12px;
    text-align: center;
    margin-bottom: 14px;
  }

  /* Inputs & selects: comfy taps */
  input,
  select#time-zone {
    font-size: 15px;
    padding: 12px;
    border-radius: 10px;
  }
  .password-wrapper input { padding-right: 42px; }
  .toggle-password { right: 10px; }

  /* Buttons */
  button {
    font-size: 16px;
    padding: 12px;
    border-radius: 10px;
  }

  /* Inline field groups:
     - Login has none; Register has 2 groups (Email+Age, Town+State+Zip)
     - Stack everything on mobile for perfect readability */
  .inline-fields {
    display: grid;
    grid-template-columns: 1fr !important;
    gap: 10px;
    margin: 10px 0;
  }

  /* Links & footer */
  .forgot-link {
    font-size: 12px;
    text-align: center;
    margin: 8px 0 12px;
  }
  .separator { margin: 12px 0; }
  .form-footer { font-size: 13px; text-align: center; }

  /* Toasts fit narrow screens */
  #toast-container { top: 12px; }
  .toast { min-width: 260px; padding: 12px 16px; }
}

/* ===== MOBILE (≤1024px): make Register match Login ===== */
@media (max-width: 1024px) {
  /* Page stack + background */
  .login-wrapper {
    flex-direction: column;
    min-height: 100dvh;
    background: #e0f2f1;
    padding: 0;
  }

  /* Teal header band (same as login) */
  .login-left {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 140px;                 /* match login header height */
    background: #457b9d;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
    margin: 0;                     /* remove extra gap */
    padding: 0;
    width: 100%;
  }

  .illustration { width: 100%; text-align: center; }
  .illustration img {
    max-width: 140px;              /* same logo size as login */
    height: auto;
    display: block;
    margin: 0 auto;
    opacity: 1 !important;
  }

  /* Card (identical spacing to login) */
  .login-right {
    width: 100%;
    max-width: 420px;
    margin: -44px auto 16px;       /* slight overlap under teal band */
    padding: 20px 16px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .register .login-right {
    width: 100%;
    max-width: 920px;
    margin: 20px;
    padding: 0px 16px;
    }

  /* Headings */
  .login-right h2.brand {
    font-size: 20px;
    text-align: center;
    margin-bottom: 4px;
    letter-spacing: .3px;
  }
  .login-right .subtitle {
    font-size: 12px;
    text-align: center;
    margin-bottom: 12px;
  }

  /* Inputs & selects */
  input,
  select#time-zone {
    font-size: 15px;
    padding: 12px;
    border-radius: 10px;
  }
  .password-wrapper input { padding-right: 42px; }
  .toggle-password { right: 10px; }

  /* Buttons */
  button {
    font-size: 16px;
    padding: 12px;
    border-radius: 10px;
  }

  /* Register’s inline groups: stack on mobile */
  .inline-fields {
    display: grid;
    grid-template-columns: 1fr !important;
    gap: 10px;
    margin: 8px 0;
  }

  /* Links, separators */
  .forgot-link { font-size: 12px; text-align: center; margin: 6px 0 10px; }
  .separator { margin: 12px 0; }
  .form-footer { font-size: 13px; text-align: center; }
}


/* Hide left section (image & bg) in mobile */
@media (max-width: 768px) {
  .register .login-left {
    display: none !important;   /* removes image & background */
  }
  .register .login-wrapper {
    background: none !important; /* no background color */
  }
}

/* Tablet/small laptops also: */
@media (max-width: 1024px) {
  .register .login-left {
    display: none !important;
  }
  .register .login-wrapper {
    background: none !important;
  }
}


/* ===== Toasts ===== */
/* ===== Toasts v2 (pill bar with progress) ===== */
.toast-container{
  position: fixed;
  top: 16px; right: 16px;
  display: flex; flex-direction: column; gap: 10px;
  z-index: 3000;
}

.toast{
  --dur: 5000ms;                    /* default lifetime (override per toast) */
  display: grid;
  grid-template-columns: 36px 1fr auto 24px; /* compact */
  align-items: center;
  gap: 10px;
  min-width: 300px;
  max-width: min(520px, 92vw);
  border-radius: 14px;
  padding: 10px 10px;
  color:#fff;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
  border: 1px solid rgba(255,255,255,.25);
  position: relative;
  overflow: hidden;
  transform: translateY(0);
  animation: toast-in .18s ease-out;
  font-size: 13px;
}

.toast__icon{
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(2px);
  font-size: 16px;
}

.toast__body{ display: grid; gap: 2px; }
.toast__title{ font-weight: 800; letter-spacing:.2px; font-size: 14px; }
.toast__msg{ font-weight: 600; opacity:.95; font-size: 12px; }

.toast__action{
  font: inherit; font-weight: 700; font-size: 12px;
  padding: 6px 10px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.5);
  background: rgba(255,255,255,.15);
  color:#fff; cursor: pointer;
  transition: filter .2s ease, transform .06s ease;
  white-space: nowrap;
}
.toast__action:hover{ filter: brightness(1.1); }
.toast__action:active{ transform: translateY(1px); }

.toast__close{
  border:0; background: transparent; color:#fff; opacity:.9;
  font-size: 16px; cursor: pointer; line-height:1;
}

.toast::after{
  content:"";
  position: absolute; left: 0; bottom: 0; height: 4px; width: 100%;
  background: rgba(255,255,255,.8);
  transform-origin: left;
  animation: toast-progress var(--dur) linear forwards;
}

/* Variants (like your reference) */
.toast.error   { background: linear-gradient(90deg,#f87171,#ef4444); }
.toast.success { background: linear-gradient(90deg,#34d399,#10b981); }
.toast.info    { background: linear-gradient(90deg,#60a5fa,#3b82f6); }
.toast.warning { background: linear-gradient(90deg,#fbbf24,#f59e0b); color:#1f2937; }
.toast.wait    { background: linear-gradient(90deg,#f3f4f6,#e5e7eb); color:#111827; }

.toast.wait .toast__icon,
.toast.warning .toast__icon{ background: rgba(0,0,0,.08); color: currentColor; }
.toast.wait::after{ background: rgba(0,0,0,.35); }

/* Animations */
@keyframes toast-in   { from{opacity:0; transform: translateY(-6px);} to{opacity:1; transform: translateY(0);} }
@keyframes toast-out  { to{opacity:0; transform: translateY(-6px);} }
@keyframes toast-progress { to{ transform: scaleX(0); } }

/* Small screens: center at top */
@media (max-width: 480px){
  .toast-container{ left: 8px; right: 8px; top: 10px; }
  .toast{ max-width: 100%; min-width: 0; }
}


