/* Authentication Layout for OpenShop */

.auth-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
  position: relative;
  z-index: 1;
}

.auth-card {
  width: 100%;
  max-width: 480px;
  padding: 40px;
  position: relative;
  overflow: hidden;
}

/* Auth Header */
.auth-header {
  text-align: center;
  margin-bottom: 32px;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary) 0%, #00e676 100%);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #ffffff;
  font-size: 24px;
  font-family: var(--font-en);
  box-shadow: 0 4px 12px var(--primary-glow-strong);
}

.brand-name {
  font-family: var(--font-en);
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: linear-gradient(to right, var(--text-primary) 30%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.auth-subtitle {
  color: var(--text-secondary);
  font-size: 14px;
  margin-top: 4px;
  font-weight: 300;
}

/* Form Styles */
.form-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-primary);
  border-left: 4px solid var(--primary);
  padding-left: 12px;
  line-height: 1.2;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-secondary);
}

/* Password Toggle Icon */
.password-toggle {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition-smooth);
  display: flex;
  align-items: center;
  justify-content: center;
}

.password-toggle:hover {
  color: var(--primary);
}

/* Error/Success Feedbacks */
.validation-message {
  font-size: 12px;
  color: var(--error);
  margin-top: 6px;
  display: none;
  animation: slideDown 0.2s ease forwards;
  padding-left: 4px;
}

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

.form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  font-size: 14px;
}

/* Custom Checkbox */
.checkbox-container {
  display: flex;
  align-items: center;
  position: relative;
  padding-left: 28px;
  cursor: pointer;
  color: var(--text-secondary);
  user-select: none;
}

.checkbox-container input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkmark {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  height: 18px;
  width: 18px;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--surface-border);
  border-radius: 4px;
  transition: var(--transition-smooth);
}

.checkbox-container:hover input ~ .checkmark {
  border-color: rgba(0, 200, 83, 0.4);
  background-color: rgba(0, 200, 83, 0.05);
}

.checkbox-container input:checked ~ .checkmark {
  background-color: var(--primary);
  border-color: var(--primary);
}

.checkmark::after {
  content: "";
  position: absolute;
  display: none;
}

.checkbox-container input:checked ~ .checkmark::after {
  display: block;
}

.checkbox-container .checkmark::after {
  left: 6px;
  top: 2px;
  width: 4px;
  height: 8px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.auth-link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition-smooth);
}

.auth-link:hover {
  text-shadow: 0 0 8px var(--primary-glow);
  color: #00e676;
}

.btn-submit {
  width: 100%;
  padding: 14px;
  font-size: 16px;
  border-radius: 12px;
  margin-bottom: 24px;
}

.auth-footer {
  text-align: center;
  font-size: 14px;
  color: var(--text-secondary);
}

/* Toast Notification - Modern Popup Style */
.toast {
  position: fixed;
  top: 80px;
  right: 24px;
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 9999;
  transform: translateX(400px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-left: 4px solid #00c853;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.toast-error {
  border-left-color: #d32f2f;
}

.toast-icon {
  flex-shrink: 0;
  line-height: 1;
}

.toast-message {
  font-size: 15px;
  color: #1a1a1a;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
}

/* Mobile responsive fixes */
@media (max-width: 480px) {
  .auth-card {
    padding: 24px;
  }
  .form-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

/* PC styling to emulate a mobile device viewport for auth screens */
@media (min-width: 481px) {
  .auth-container {
    max-width: 430px;
    width: 100%;
    margin: 0 auto !important;
    min-height: 100vh;
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.1);
    border-left: 1px solid var(--surface-border);
    border-right: 1px solid var(--surface-border);
    background: rgba(246, 250, 247, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 24px 16px !important;
    box-sizing: border-box;
  }

  .auth-card {
    padding: 24px !important;
  }

  .form-actions {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
  }
}

