@import url('https://fonts.googleapis.com/css2?family=Coiny&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --primary: #21449C;
  --primary-hover: #193B8B;
  --ink: #1F2937;
  --text: #444557;
  --muted: #757589;
  --line: #C5C5DB;
  --soft-blue: #3871C0;
  --white: #FFFFFF;
  --support-bg: #F8FAFD;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100%;
  font-family: 'Inter', 'Segoe UI', Arial, sans-serif;
  color: var(--ink);
  background: #EFF5FF;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button,
a,
label {
  -webkit-tap-highlight-color: transparent;
}

button,
a {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ===== AUTH PAGE WRAPPER ===== */
.auth-page {
  position: relative;
  width: 100%;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: url('../images/auth-background.png') center center / cover no-repeat;
  overflow-x: hidden;
}

.auth-stage {
  position: relative;
  width: 100%;
  max-width: 1560px;
  min-height: 100vh;
  padding: 20px clamp(16px, 3vw, 50px) 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
}

/* ===== TWO-COLUMN FLUID BODY ===== */
.auth-body {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(20px, 3.5vw, 60px);
  min-height: 0;
}

/* ===== LEFT VISUAL (LOGO + LAPTOP HERO) ===== */
.auth-visual {
  flex: 1 1 0;
  min-width: 0;
  max-width: 860px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 1.8vh, 18px);
  user-select: none;
}

.auth-intro {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.auth-product-logo {
  display: block;
  width: 100%;
  max-width: 590px;
  height: auto;
  max-height: clamp(120px, 20vh, 210px);
  object-fit: contain;
  margin: 0 auto;
}

.auth-hero {
  display: block;
  width: 100%;
  max-width: 790px;
  height: auto;
  max-height: clamp(310px, 54vh, 550px);
  object-fit: contain;
  pointer-events: none;
  animation: auth-hero-float 4s ease-in-out infinite;
  will-change: transform;
}

@keyframes auth-hero-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-hero {
    animation: none;
  }
}

/* ===== RIGHT CARD ===== */
.auth-card {
  flex: 0 0 clamp(410px, 32vw, 475px);
  max-width: 475px;
  width: 100%;
  padding: clamp(30px, 3.8vh, 44px) clamp(22px, 2.4vw, 36px) clamp(18px, 2.2vh, 24px);
  border: 1px solid rgba(215, 220, 231, .78);
  border-radius: 20px;
  background: rgba(255, 255, 255, .95);
  box-shadow: 0 14px 36px rgba(43, 67, 115, .08);
  backdrop-filter: blur(8px);
}

.auth-logo {
  display: block;
  width: 140px;
  max-height: 56px;
  object-fit: contain;
  margin: 0 auto clamp(14px, 2.2vh, 24px);
}

.auth-heading {
  margin: 0;
  text-align: center;
  color: #1A1B26;
  font-size: clamp(23px, 2.1vw, 28px);
  line-height: 1.15;
  font-weight: 700;
}

.auth-subtitle {
  margin: clamp(6px, 1vh, 12px) 0 clamp(16px, 2.2vh, 26px);
  text-align: center;
  color: #757589;
  font-size: 13.5px;
  line-height: 1.45;
}

.auth-form {
  width: 100%;
}

.field {
  margin-bottom: clamp(12px, 1.6vh, 16px);
}

.input-wrap {
  position: relative;
  width: 100%;
  height: 49px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .8);
  transition: border-color .15s ease, box-shadow .15s ease;
}

.input-wrap:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(33, 68, 156, .08);
}

.field-icon {
  width: 42px;
  height: 47px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  color: #7B8192;
}

.field-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.input-wrap input {
  min-width: 0;
  height: 47px;
  flex: 1;
  padding: 0 12px 0 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #2D3748;
  font-size: 14px;
}

.input-wrap input::placeholder {
  color: #A4A8B6;
}

.input-wrap input:-webkit-autofill,
.input-wrap input:-webkit-autofill:hover,
.input-wrap input:-webkit-autofill:focus {
  -webkit-text-fill-color: #2D3748;
  -webkit-box-shadow: 0 0 0 1000px #FFFFFF inset;
  box-shadow: 0 0 0 1000px #FFFFFF inset;
  transition: background-color 5000s ease-in-out 0s;
}

.password-toggle {
  width: 44px;
  height: 47px;
  flex: 0 0 44px;
  border: 0;
  background: transparent;
  color: #757B8D;
  display: grid;
  place-items: center;
}

.password-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.field-error {
  min-height: 13px;
  margin-top: 3px;
  color: #EF4444;
  font-size: 11px;
}

.login-options {
  min-height: 24px;
  margin: 0 0 clamp(10px, 1.6vh, 16px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.remember {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #444557;
  font-size: 13px;
  white-space: nowrap;
  cursor: pointer;
}

.remember input {
  width: 17px;
  height: 17px;
  margin: 0;
  accent-color: var(--primary);
}

.forgot-link {
  color: #21449C;
  font-size: 13px;
  white-space: nowrap;
}

.forgot-link:hover {
  text-decoration: underline;
}

.auth-primary-button {
  width: 100%;
  height: 49px;
  border: 0;
  border-radius: 10px;
  background: var(--primary);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  transition: background .15s ease, transform .1s ease;
}

.auth-primary-button:hover {
  background: var(--primary-hover);
}

.auth-primary-button:active {
  transform: scale(0.99);
}

.support-card {
  width: 100%;
  min-height: 90px;
  margin-top: clamp(14px, 2.2vh, 24px);
  padding: 13px 15px;
  border: 1px solid #E8EBF0;
  border-radius: 12px;
  background: rgba(248, 250, 253, .92);
  display: flex;
  align-items: center;
  gap: 13px;
}

.support-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #3871C0;
  background: #E6EDFF;
}

.support-icon svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.support-content {
  min-width: 0;
}

.support-label {
  margin-bottom: 3px;
  color: #5D5D6F;
  font-size: 11.5px;
}

.support-phone {
  margin-bottom: 2px;
  color: #3871C0;
  font-size: 18px;
  line-height: 1;
  font-weight: 700;
}

.support-time {
  color: #757589;
  font-size: 11px;
  line-height: 1.35;
}

/* ===== FOOTER COPYRIGHT ===== */
.auth-copyright {
  width: 100%;
  margin: 10px 0 0;
  text-align: center;
  color: #404B52;
  font-size: clamp(12px, 0.95vw, 14.5px);
  line-height: 1.35;
  font-weight: 400;
}

/* ===== RESPONSIVE: TABLET & SMALL LAPTOPS (STACK ON <= 1000px) ===== */
@media (max-width: 1000px) {
  .auth-page {
    overflow-y: auto;
    align-items: flex-start;
  }

  .auth-stage {
    min-height: 100vh;
    height: auto;
    padding: 36px 20px 24px;
    justify-content: flex-start;
  }

  .auth-body {
    flex-direction: column;
    justify-content: center;
    gap: 28px;
    flex: 0 0 auto;
  }

  .auth-visual {
    width: 100%;
    max-width: 620px;
    gap: 16px;
  }

  .auth-product-logo {
    max-width: 480px;
  }

  .auth-hero {
    max-width: 580px;
  }

  .auth-card {
    flex: 0 0 auto;
    width: min(480px, 100%);
    max-width: 480px;
    padding: 34px 28px 24px;
  }

  .auth-copyright {
    margin-top: 28px;
    font-size: 13px;
  }
}

/* ===== RESPONSIVE: MOBILE (<= 600px) ===== */
@media (max-width: 600px) {
  .auth-stage {
    padding: 24px 14px 20px;
  }

  .auth-visual {
    max-width: 100%;
    gap: 12px;
  }

  .auth-product-logo {
    max-width: 340px;
  }

  .auth-hero {
    max-width: 95vw;
  }

  .auth-card {
    padding: 26px 18px 20px;
    border-radius: 16px;
  }

  .auth-heading {
    font-size: 24px;
  }

  .auth-subtitle {
    margin: 8px 0 18px;
    font-size: 13px;
  }

  .input-wrap input {
    font-size: 16px;
  }

  .support-card {
    margin-top: 18px;
    padding: 12px 14px;
  }

  .support-phone {
    font-size: 17px;
  }

  .login-options {
    gap: 8px;
  }

  .remember,
  .forgot-link {
    font-size: 12px;
  }
}