/* General layout */
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.page-wrapper {
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ✅ Blurred background */
body::before {
  content: "";
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('/assets/images/estate.jpg') no-repeat center center/cover;
  filter: blur(4px) brightness(0.7);
  z-index: -1;
  transform: scale(1.05);
}

/* Login box - Modern with original colors */
.login-box {
  width: 400px;
  max-width: 90%;
  background: linear-gradient(165deg, #031703 0%, #005B10 50%, #003308 100%);
  border: 3px solid #e0b000;
  padding: 40px 32px;
  border-radius: 16px;
  box-shadow: 
    0 20px 60px rgba(0,0,0,0.5),
    0 0 0 1px rgba(224,176,0,0.3),
    inset 0 1px 0 rgba(255,255,255,0.1);
  text-align: center;
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  z-index: 10000;
  backdrop-filter: blur(20px);
  animation: fadeInScale 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@media (min-width: 769px) {
  .login-box {
    z-index: 10000;
  }
}

.login-box img {
  width: 80%;
  max-width: 240px;
  margin-bottom: 32px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

.login-box input[type="text"],
.login-box input[type="password"] {
  width: 100%;
  box-sizing: border-box;
  padding: 14px 16px;
  margin: 10px 0;
  border: 2px solid rgba(224,176,0,0.3);
  border-radius: 12px;
  font-size: 15px;
  font-family: inherit;
  color: #1a1a1a;
  background: rgba(255,255,255,0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
}

.login-box input[type="text"]:focus,
.login-box input[type="password"]:focus {
  outline: none;
  border-color: #e0b000;
  background: rgba(255,255,255,1);
  box-shadow: 
    0 0 0 4px rgba(224,176,0,0.15),
    0 4px 12px rgba(224,176,0,0.2);
  transform: translateY(-2px);
}

.login-box input::placeholder {
  color: #7a7a7a;
  font-weight: 400;
}

.login-box button {
  width: auto;
  min-width: 140px;
  padding: 14px 40px;
  margin-top: 20px;
  background: linear-gradient(135deg, #f0c040 0%, #e0b000 100%);
  border: 3px solid #e0b000;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  color: #1a1a1a;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 
    0 6px 20px rgba(224,176,0,0.4),
    inset 0 1px 0 rgba(255,255,255,0.4);
  text-shadow: 0 1px 2px rgba(255,255,255,0.3);
  letter-spacing: 0.5px;
}

.login-box button:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 8px 28px rgba(224,176,0,0.5),
    inset 0 1px 0 rgba(255,255,255,0.5);
  background: linear-gradient(135deg, #f5d060 0%, #edc020 100%);
  border-color: #f0c040;
}

.login-box button:active {
  transform: translateY(0);
  box-shadow: 
    0 4px 12px rgba(224,176,0,0.4),
    inset 0 2px 4px rgba(0,0,0,0.1);
}

/* Tablet */
@media (max-width: 768px) {
  .login-box { 
    width: 85%; 
    max-width: 400px;
    padding: 36px 28px; 
  }
  .login-box img { 
    width: 75%;
    max-width: 220px;
  }
  .login-box input[type="text"],
  .login-box input[type="password"] { 
    font-size: 15px; 
    padding: 13px 14px; 
  }
  .login-box button { 
    font-size: 15px;
    padding: 13px 36px;
    min-width: 130px;
  }
}

/* Mobile */
@media (max-width: 480px) {
  body { padding: 15px; }
  .login-box { 
    width: 95%; 
    max-width: 380px; 
    padding: 32px 24px;
    border-radius: 14px;
  }
  .login-box img { 
    width: 70%;
    max-width: 200px;
    margin-bottom: 28px;
  }
  .login-box input[type="text"],
  .login-box input[type="password"] { 
    font-size: 15px;
    padding: 12px 14px;
    margin: 8px 0;
  }
  .login-box button { 
    font-size: 14px;
    padding: 12px 32px;
    min-width: 120px;
  }
}

/* ✅ SweetAlert custom look */
.swal2-popup {
  border: 3px solid #e0b000 !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 24px rgba(0,0,0,0.35) !important;
}

.swal2-title {
  font-weight: 700 !important;
  color: #005B10 !important;
}

.swal2-html-container {
  font-size: 14px !important;
  color: #333 !important;
}

.swal2-icon {
  border-width: 3px !important;
}

.swal2-confirm {
  background: #e0b000 !important;
  color: #000 !important;
  font-weight: 600 !important;
  border-radius: 30px !important;
  padding: 10px 24px !important;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.swal2-confirm:hover {
  background: #c79a00 !important;
}

/* ✅ Backdrop fix */
.swal2-backdrop-show {
  background: transparent !important;   /* remove gray overlay */
  backdrop-filter: blur(3px) !important;
}

/* ✅ Ensure SweetAlert backdrop always covers full window */
.swal2-container {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: 11000 !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

/* Prevent layout shift when SweetAlert appears */
body.swal2-shown .login-box {
  filter: blur(1px);
  pointer-events: none;
}
