/* Tabi Studio - Site Passcode Authentication & Lock Screen Styles */

.site-auth-modal {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  max-width: 90vw;
  width: 440px;
  overflow: visible;
  z-index: 99999;
}

.site-auth-modal::backdrop {
  background: rgba(14, 25, 22, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.site-auth-modal[open] {
  animation: authFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes authFadeIn {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.auth-modal-card {
  background: #172420;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45), 0 2px 8px rgba(0, 0, 0, 0.2);
  padding: 36px 32px 28px;
  color: #f0f4f2;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.auth-modal-card::before {
  content: "";
  position: absolute;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  width: 180px;
  height: 100px;
  background: radial-gradient(circle, rgba(74, 155, 128, 0.35) 0%, transparent 70%);
  pointer-events: none;
}

.auth-brand-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, #275d4f 0%, #173e35 100%);
  border: 1px solid rgba(135, 206, 175, 0.3);
  box-shadow: 0 8px 20px rgba(23, 62, 53, 0.5);
  margin-bottom: 16px;
}

.auth-brand-badge .brand-mark {
  color: #7ce3b6;
  font-size: 26px;
  font-weight: 700;
  font-family: inherit;
}

.auth-modal-header h2 {
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 8px;
  color: #f7faf8;
  letter-spacing: -0.02em;
}

.auth-subtitle {
  font-size: 13.5px;
  color: #9cb1a8;
  margin: 0 0 24px;
  line-height: 1.5;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-input-group {
  position: relative;
  display: flex;
  align-items: center;
}

.auth-password-input {
  width: 100%;
  height: 48px;
  padding: 0 46px 0 16px;
  background: rgba(10, 18, 15, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  font-size: 15px;
  color: #ffffff;
  outline: none;
  transition: border-color 0.18s, box-shadow 0.18s;
  box-sizing: border-box;
}

.auth-password-input:focus {
  border-color: #52b788;
  box-shadow: 0 0 0 3px rgba(82, 183, 136, 0.25);
}

.auth-password-input::placeholder {
  color: #667a72;
}

.auth-toggle-pwd {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  color: #8da49b;
  cursor: pointer;
  padding: 6px;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: color 0.15s;
}

.auth-toggle-pwd:hover {
  color: #e2ede8;
}

.auth-error {
  background: rgba(220, 53, 69, 0.18);
  border: 1px solid rgba(220, 53, 69, 0.4);
  color: #ff8b97;
  font-size: 13px;
  padding: 9px 12px;
  border-radius: 8px;
  text-align: left;
  line-height: 1.4;
  animation: authShake 0.35s ease-in-out;
}

@keyframes authShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  75% { transform: translateX(-4px); }
}

.auth-submit-btn {
  height: 46px;
  background: linear-gradient(135deg, #2d7a64 0%, #1e5848 100%);
  border: 1px solid rgba(124, 227, 182, 0.25);
  border-radius: 12px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.14s, box-shadow 0.18s, filter 0.18s;
  box-shadow: 0 6px 16px rgba(20, 60, 48, 0.4);
}

.auth-submit-btn:hover:not(:disabled) {
  filter: brightness(1.12);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(20, 60, 48, 0.55);
}

.auth-submit-btn:active:not(:disabled) {
  transform: translateY(0);
}

.auth-submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.auth-modal-footer {
  margin-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding-top: 14px;
}

.auth-modal-footer small {
  color: #758b81;
  font-size: 12px;
}

/* Lock Button in Topbar */
.auth-lock-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  color: #9cb1a8;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.auth-lock-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #e2ede8;
  border-color: rgba(255, 255, 255, 0.2);
}
