/* Innovative Modern UI - 2025 (English LTR Version) */
:root {
  --primary: #ee9f0d;
  --primary-dark: #d48c0c;
  --primary-light: #ffd149;
  --surface: #ffffff;
  --background: #f5f5f5;
  --text-primary: #333333;
  --text-secondary: #666666;
  --error: #dc3545;
  --border-radius: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.12);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Rubik", sans-serif;
}

body {
  font-family: "Rubik", serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url("../img/bb.jpeg");
  background-size: cover; /* পুরো স্ক্রিন কভার করবে */
  background-position: center; /* ছবি মাঝখানে থাকবে */
  background-repeat: no-repeat;
  background-attachment: fixed; /* স্ক্রল করলেও ব্যাকগ্রাউন্ড নড়বে না */
  direction: ltr;
  color: var(--text-primary);
  line-height: 1.5;
  margin: 0;
  padding: 20px 0; /* উপরে নিচে সামান্য স্পেস */
}

.wrapper {
  font-family: "Rubik", sans-serif;
  position: relative;
  max-width: 420px;
  width: 100%;
  background: #fff;
  padding: 2.5rem 2rem;
  border-radius: 25px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);

  /* ✅ CHANGED: Align Left & LTR */
  text-align: left;
  direction: ltr;
}

.wrapper:hover {
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.15);
}

.wrapper h2 {
  font-family: "Alexandria", serif;
  position: relative;
  font-size: 22px;
  font-weight: 600;
  color: #333;
  background: #14243b;
  border-radius: 20px;
  color: #ffffff;
  padding: 20px 0;
  margin-bottom: 30px;
  text-align: center;
}

.wrapper h2::before {
  font-family: "Alexandria", serif;
  content: "";
  position: absolute;
  /* Left positioning is fine for decorative underline in LTR too */
  left: 0;
  bottom: 0;
  height: 3px;
  width: 28px;
  border-radius: 12px;
  background: #ee9f0d;
}

.input-box {
  position: relative;
  margin-bottom: 1.5rem;

  /* ✅ CHANGED: Align Left & LTR */
  text-align: left;
  direction: ltr;
}

.input-box input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-size: 1rem;
  border: 2px solid #e2e8f0;
  border-radius: var(--border-radius);
  background: transparent;
  transition: var(--transition);
  outline: none;

  /* ✅ CHANGED: Text align left */
  text-align: left;
  direction: ltr;

  font-family: "Rubik", sans-serif;
  line-height: 1.5;
}

.input-box input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(238, 159, 13, 0.1);
}

.input-box label {
  position: absolute;

  /* ✅ CHANGED: Label moved to Left */
  left: 1rem;
  right: auto;

  top: 50%;
  transform: translateY(-50%);
  background: var(--surface);
  padding: 0 0.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-family: "Rubik", sans-serif;
  font-weight: 500;
  transition: var(--transition);
  pointer-events: none;

  /* ✅ CHANGED: Align Left */
  text-align: left;
  direction: ltr;
}

.input-box input:focus + label,
.input-box input:not(:placeholder-shown) + label {
  top: 0;
  transform: translateY(-50%) scale(0.85);
  color: var(--primary);
  font-weight: 600;
}

.input-box.button {
  margin-top: 2rem;
  /* ✅ CHANGED: Align Left/Center */
  text-align: left;
  direction: ltr;
}

.input-box.button input {
  color: #fff;
  text-align: center;
  line-height: normal;
  letter-spacing: 0.5px;
  border: none;
  height: 3.25rem;
  max-width: 200px;
  width: 100%;
  background: #ee9f0d;
  box-sizing: border-box;
  margin: 0;
  border-radius: 20px;
  display: block;
  cursor: pointer;
  font-family: "Rubik", sans-serif;
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition);
}

.input-box.button input:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(238, 159, 13, 0.25);
}

.input-box.button input:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.input-box.button input:active {
  transform: translateY(0);
}

/* Password Toggle Styles */
.password-toggle {
  position: absolute;

  /* ✅ CHANGED: Icon moved to Right */
  right: 1rem;
  left: auto;

  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-secondary);
  padding: 0.5rem;
  border-radius: 50%;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.password-toggle:hover {
  background: rgba(238, 159, 13, 0.1);
  color: var(--primary);
}

.password-toggle .eye-icon {
  transition: var(--transition);
}

.password-toggle:active .eye-icon {
  transform: scale(0.9);
}

/* Hide eye when password is hidden */
.password-toggle.hidden .eye-icon path:last-child {
  opacity: 0;
}

.password-toggle.hidden .eye-icon::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 2px;
  background: currentColor;
  transform: rotate(45deg);
  top: 50%;
  left: 50%;
  margin-left: -10px;
  margin-top: -1px;
}

.error-message {
  color: var(--error);
  border: 1px solid currentColor;
  font-size: 0.85rem;
  margin-top: 0.5rem;
  display: none;
  transition: var(--transition);
}

.error-message.show {
  display: block;
}

#loginMessage {
  margin-top: 1.5rem;
  text-align: center;
  font-weight: 500;
  color: var(--error);
  border: 1px solid currentColor;
  transition: var(--transition);
  padding: 0.75rem;
  border-radius: var(--border-radius);
  background: rgba(220, 53, 69, 0.1);
  display: none;
}

#loginMessage.show {
  display: block;
}

/* Login info section */
.login-info,
.password-reset-info,
.info-section {
  margin-top: 4rem;
  padding: 1rem;
  background: rgba(238, 159, 13, 0.1);
  border: 1px solid rgba(238, 159, 13, 0.3);
  border-radius: var(--border-radius);
  text-align: center;
}

.login-info .info-text,
.password-reset-info .info-text,
.info-section .info-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.login-info .info-text strong,
.password-reset-info .info-text strong,
.info-section .info-text strong {
  color: var(--primary-dark);
  font-weight: 600;
}

.text {
  margin-top: 2.5rem;
  text-align: center;
  position: relative;
  padding-top: 1.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  font-size: 1rem;
  display: none;
  animation: slideIn 0.3s ease forwards;
  background: #fff;
  box-shadow: var(--shadow);
}

.text::before {
  content: "";
  position: absolute;
  top: 0;
  left: 25%;
  right: 25%;
  height: 1px;
  background: linear-gradient(to right, transparent, #e2e8f0, transparent);
}

.text h3 {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.text h3 a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
  margin-right: 0.5rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--border-radius);
  background: rgba(238, 159, 13, 0.1);
}

.text h3 a:hover {
  background: rgba(238, 159, 13, 0.15);
  color: var(--primary-dark);
  transform: translateY(-1px);
}

/* Success and Error variants for .text class */
.text.success {
  background: rgba(40, 167, 69, 0.1);
  color: #28a745;
  border: 1px solid #28a745;
  padding: 0.75rem 1rem;
  margin-top: 1rem;
}

.text.error {
  background: rgba(220, 53, 69, 0.1);
  color: #dc3545;
  border: 1px solid #dc3545;
  padding: 0.75rem 1rem;
  margin-top: 1rem;
}

.text.warning {
  background: rgba(255, 193, 7, 0.1);
  color: #f57c00;
  border: 1px solid #f57c00;
  padding: 0.75rem 1rem;
  margin-top: 1rem;
}

/* Responsive adjustments for info sections */
@media (max-width: 480px) {
  .login-info,
  .password-reset-info,
  .info-section {
    padding: 0.75rem;
    margin-top: 1rem;
  }

  .login-info .info-text,
  .password-reset-info .info-text,
  .info-section .info-text {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  body {
    padding: 0.5rem;
  }

  .wrapper {
    padding: 1.5rem;
    margin: 0.5rem;
    max-width: 100%;
  }

  .wrapper h2 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    padding: 15px 0;
  }

  .welcome-message h1 {
    font-size: 1.1rem;
  }

  .welcome-message p {
    font-size: 0.8rem;
    margin-left: 0;
    text-align: center;
  }

  .input-box {
    margin-bottom: 1.5rem;
  }

  .input-box input {
    padding: 0.85rem 1rem;
    font-size: 0.9rem;
  }

  .input-box label {
    font-size: 0.85rem;

    /* ✅ CHANGED: Left align mobile */
    left: 0.75rem;
    right: auto;
  }

  .password-toggle {
    /* ✅ CHANGED: Right align mobile */
    right: 0.75rem;
    left: auto;

    padding: 0.4rem;
  }

  .password-toggle svg {
    width: 18px;
    height: 18px;
  }

  .input-box.button input {
    height: 65px !important;
    min-height: 65px !important;
    padding-top: 1.6rem !important;
    padding-bottom: 1.6rem !important;
    max-width: 100% !important;
  }
}

/* Extra small devices */
@media (max-width: 360px) {
  .wrapper {
    padding: 1.25rem;
    margin: 0.25rem;
  }

  .wrapper h2 {
    font-size: 1.1rem;
    padding: 12px 0;
  }

  .welcome-message h1 {
    font-size: 1rem;
  }

  .welcome-message p {
    font-size: 0.75rem;
  }

  .input-box input {
    padding: 0.75rem 0.85rem;
    font-size: 0.85rem;
  }

  .input-box label {
    font-size: 0.8rem;
    /* ✅ CHANGED: Left align small mobile */
    left: 0.65rem;
    right: auto;
  }
}

.welcome-message {
  text-align: center;
  margin-bottom: 2rem;
  animation: fadeIn 1s ease-in;
}

.welcome-message h1 {
  color: #2c3e50;
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}



.gradient-text {
  /* ✅ CHANGED: Margin Left for LTR flow */
  margin-left: 10px;
  margin-right: 0;

  font-weight: 700;
  background: linear-gradient(to right, #ff6a00, #f8a203, #ff6a00);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  background-size: 200% auto;
  animation: gradientAnimation 3s linear infinite;
}

@keyframes gradientAnimation {
  0% {
    background-position: 200% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.welcome-message p {
  color: #7f8c8d;
  font-size: 0.9rem;

  /* ✅ CHANGED: Swapped margin for LTR (or centered) */
  margin-right: 7rem;
  margin-left: 0;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== FORGET PASSWORD SECTION ===== */
.forget-password-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0.5rem 0 1.5rem 0;
  direction: ltr;
}

.forget-password-link {
  color: #64748b;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  font-family: "Rubik", sans-serif;
  transition: var(--transition);
  display: inline-block;
  position: relative;
  line-height: 1;
  padding: 8px 0;
  background: transparent;
  z-index: 1;
}

.forget-password-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -8px;
  right: -8px;
  bottom: 0;
  background: var(--primary);
  opacity: 0;
  border-radius: 8px;
  z-index: -1;
  transition: var(--transition);
  transform: scale(0.95);
}

.forget-password-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--primary);
  border-radius: 4px;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.forget-password-link:hover {
  color: var(--primary-dark);
}

.forget-password-link:hover::before {
  opacity: 0.08;
  transform: scale(1);
}

.forget-password-link:hover::after {
  width: 100%;
}

.forget-password-link:active {
  transform: translateY(1px);
}

.forget-password-link:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Remember Me Checkbox Styles - Premium Redesign */
.remember-me {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  user-select: none;
  padding: 2px 0;
  transition: var(--transition);
}

.remember-me input {
  display: none;
}

.checkbox-custom {
  width: 20px;
  height: 20px;
  border: 2px solid #cbd5e1;
  border-radius: 6px;
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: #fff;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.remember-me input:checked + .checkbox-custom {
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 0 12px rgba(238, 159, 13, 0.35);
}

.checkbox-custom::after {
  content: "";
  width: 11px;
  height: 11px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='4.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'%3E%3C/polyline%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.remember-me input:checked + .checkbox-custom::after {
  opacity: 1;
  transform: scale(1);
}

.remember-text {
  font-size: 0.88rem;
  color: #64748b;
  font-weight: 500;
  line-height: 1;
  font-family: "Rubik", sans-serif;
  transition: var(--transition);
}

.remember-me:hover .remember-text {
  color: #334155;
}

.remember-me:hover .checkbox-custom {
  border-color: var(--primary);
}

.remember-me:active .checkbox-custom {
  transform: scale(0.9);
}

/* Mobile Responsive Design */
@media (max-width: 768px) {
  .wrapper {
    padding: 2rem 1.75rem;
  }

  .welcome-message {
    margin-bottom: 2rem;
  }

  .wrapper h2 {
    font-size: 1.25rem;
    padding: 1rem 1.25rem;
    margin-bottom: 1.75rem;
  }

  .input-box.button input {
    height: 60px !important;
    min-height: 60px !important;
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
  }
}

@media (max-width: 480px) {
  body {
    padding: 0.5rem;
  }

  .wrapper {
    padding: 1.75rem 1.5rem;
    max-width: 100%;
  }

  .welcome-message {
    margin-bottom: 1.75rem;
    padding-right: 0.25rem;
  }

  .welcome-message h1 {
    font-size: 1.125rem;
  }

  .welcome-message p {
    font-size: 0.8rem;
  }

  .wrapper h2 {
    font-size: 1.125rem;
    padding: 0.875rem 1rem;
    margin-bottom: 1.5rem;
  }

  .input-box {
    margin-bottom: 1.25rem;
  }

  .input-box input {
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
  }

  .input-box label {
    font-size: 0.85rem;
    /* ✅ CHANGED: Left align */
    left: 0.875rem;
    right: auto;
  }

  .forget-password-section {
    margin: 0.5rem 0 1.5rem 0;
  }

  .forget-password-link {
    font-size: 0.8rem;
  }

  .input-box.button input {
    height: 68px !important;
    min-height: 68px !important;
    padding-top: 1.7rem !important;
    padding-bottom: 1.7rem !important;
    max-width: 100% !important;
  }
}

@media (max-width: 360px) {
  .wrapper {
    padding: 1.5rem 1.25rem;
  }

  .welcome-message h1 {
    font-size: 1rem;
  }

  .welcome-message p {
    font-size: 0.75rem;
  }

  .wrapper h2 {
    font-size: 1rem;
    padding: 0.75rem 0.875rem;
  }

  .input-box input {
    padding: 0.75rem 0.875rem;
    font-size: 0.9rem;
  }

  .input-box label {
    font-size: 0.8rem;
    /* ✅ CHANGED: Left align */
    left: 0.75rem;
    right: auto;
  }

  .forget-password-link {
    font-size: 0.75rem;
  }

  .input-box.button input {
    height: 70px !important;
    min-height: 70px !important;
    padding-top: 1.8rem !important;
    padding-bottom: 1.8rem !important;
  }
}

/* Premium Liquid Footer Design */
.premium-footer {
  margin-top: 40px;
  margin-bottom: 32px;
  position: relative;
  text-align: center;
  padding: 0 16px;
}

.footer-content {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 8px 16px;
  background: linear-gradient(
    135deg,
    rgba(238, 159, 13, 0.08),
    rgba(215, 53, 2, 0.06)
  );
  border: 1px solid rgba(238, 159, 13, 0.2);
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  min-height: 36px;
}

.footer-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(238, 159, 13, 0.1),
    transparent
  );
  transition: left 0.6s ease;
}

.footer-content:hover::before {
  left: 100%;
}

.footer-content:hover {
  transform: translateY(-2px);
  border-color: rgba(238, 159, 13, 0.4);
  box-shadow: 0 8px 25px rgba(238, 159, 13, 0.15);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 6px;
}

.brand-icon {
  font-size: 0.9rem;
  filter: hue-rotate(20deg);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.8;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

.brand-text {
  font-size: 0.7rem;
  color: #666;
  font-weight: 500;
  font-family: "Alexandria", "Rubik", serif;
}

.brand-link {
  font-size: 0.75rem;
  color: #ee9f0d;
  font-weight: 700;
  text-decoration: none;
  position: relative;
  transition: all 0.3s ease;
  font-family: "Alexandria", "Rubik", serif;
}

.brand-link::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #ee9f0d, #d48c0c);
  transition: width 0.3s ease;
}

.brand-link:hover::after {
  width: 100%;
}

.brand-link:hover {
  color: #d48c0c;
  transform: translateY(-1px);
}

.footer-version {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 8px;
  background: rgba(215, 53, 2, 0.1);
  border-radius: 12px;
  border: 1px solid rgba(215, 53, 2, 0.2);
}

.version-text {
  font-size: 0.65rem;
  color: #888;
  font-weight: 500;
  font-family: "Alexandria", "Rubik", serif;
}

.version-number {
  font-size: 0.7rem;
  color: #d73502;
  font-weight: 700;
  font-family: "Alexandria", "Rubik", serif;
}

.footer-decoration {
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 3px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(238, 159, 13, 0.3),
    transparent
  );
  border-radius: 2px;
}

/* Premium Footer Mobile Responsive */
@media (max-width: 768px) {
  .premium-footer {
    margin-top: 48px;
    margin-bottom: 20px;
    padding: 0 12px;
  }

  .footer-content {
    gap: 10px;
    padding: 7px 14px;
    border-radius: 18px;
    min-height: 32px;
  }

  .brand-text {
    font-size: 0.65rem;
  }

  .brand-link {
    font-size: 0.7rem;
  }

  .version-text {
    font-size: 0.6rem;
  }

  .version-number {
    font-size: 0.65rem;
  }

  .brand-icon {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .premium-footer {
    margin-top: 60px;
    margin-bottom: 16px;
    padding: 0 8px;
  }

  .footer-content {
    gap: 8px;
    padding: 6px 12px;
    border-radius: 16px;
    min-height: 28px;
  }

  .footer-version {
    padding: 2px 6px;
    border-radius: 10px;
  }

  .brand-text {
    font-size: 0.6rem;
  }

  .brand-link {
    font-size: 0.65rem;
  }

  .version-text {
    font-size: 0.55rem;
  }

  .version-number {
    font-size: 0.6rem;
  }

  .brand-icon {
    font-size: 0.75rem;
  }
}

@media (max-width: 360px) {
  .premium-footer {
    margin-top: 80px;
    margin-bottom: 12px;
  }

  .footer-content {
    gap: 6px;
    padding: 5px 10px;
    border-radius: 14px;
    min-height: 24px;
  }

  .footer-version {
    padding: 1px 5px;
    border-radius: 8px;
  }

  .brand-text {
    font-size: 0.55rem;
  }

  .brand-link {
    font-size: 0.6rem;
  }

  .version-text {
    font-size: 0.5rem;
  }

  .version-number {
    font-size: 0.55rem;
  }

  .brand-icon {
    font-size: 0.7rem;
  }

  .footer-decoration {
    width: 25px;
    height: 2px;
  }
}
