/* Shared login-sheet surface and the understated draft status line. */
.login-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .5);
  z-index: 500;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s;
  visibility: hidden;
}
.login-backdrop.open { opacity: 1; pointer-events: all; visibility: visible; }
.login-sheet {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 480px;
  background: #fff;
  border-radius: 24px 24px 0 0;
  z-index: 501;
  padding: 20px 24px 40px;
  transition: transform .32s cubic-bezier(.32,.72,0,1);
  box-shadow: 0 -8px 40px rgba(0,0,0,.18);
  max-height: 90vh;
  overflow-y: auto;
  visibility: hidden;
}
.login-sheet.open { transform: translateX(-50%) translateY(0); visibility: visible; }
.sheet-handle { width: 36px; height: 4px; background: #e0e0e0; border-radius: 2px; margin: 0 auto 20px; }
.sheet-title { font-size: 20px; font-weight: 800; letter-spacing: -.5px; margin-bottom: 4px; }
.sheet-sub { font-size: 13px; color: var(--text-3); margin-bottom: 20px; }
.sheet-close {
  position: absolute; top: 20px; right: 20px; width: 32px; height: 32px;
  background: var(--border); border: 0; border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center; font-size: 16px;
  color: var(--text-2); line-height: 1;
}
.tg-btn-wrap { display: flex; width: 100%; justify-content: center; margin-bottom: 16px; }
.tg-deeplink-btn {
  display: inline-flex; width: 100%; box-sizing: border-box; justify-content: center;
  align-items: center; gap: 9px; background: var(--accent);
  color: #fff; font-size: 15px; font-weight: 700; padding: 14px 28px;
  border-radius: 14px; text-decoration: none; font-family: inherit; transition: background .15s;
}
.tg-deeplink-btn:hover { background: var(--accent-dark); }
.sheet-sep { display: flex; align-items: center; gap: 10px; margin: 16px 0; font-size: 12px; color: var(--text-3); }
.sheet-sep::before, .sheet-sep::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.sheet-input {
  width: 100%; padding: 13px 16px; border: 1.5px solid var(--border); border-radius: 13px;
  font-size: 14px; font-family: inherit; margin-bottom: 10px; outline: none;
  transition: border-color .15s; color: var(--text); background: #fff;
}
.sheet-input:focus { border-color: var(--accent); }
.sheet-submit {
  width: 100%; background: var(--accent); color: #fff; font-size: 15px; font-weight: 700;
  padding: 15px; border-radius: 14px; border: 0; cursor: pointer; font-family: inherit;
  transition: background .15s;
}
.sheet-submit:hover { background: var(--accent-dark); }
.sheet-reg-link { text-align: center; margin-top: 14px; font-size: 13px; color: var(--text-3); }
.sheet-reg-link a { color: var(--accent); text-decoration: none; font-weight: 600; }
.guest-draft-notice {
  margin: 0 0 14px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-2);
  font-size: 12px;
  line-height: 1.45;
  background: var(--card-bg);
}
.guest-draft-notice[data-kind="error"] { border-color: rgba(239,68,68,.35); color: #b91c1c; }
.guest-draft-notice[hidden] { display: none; }

/* The landing uses this same dark-glass login panel over its dark surface. */
.login-sheet { background: rgba(10,8,36,.72) !important; }
.login-sheet .sheet-title { color: #f0f0ff !important; }
.login-sheet .sheet-sub { color: rgba(255,255,255,.58) !important; }
.login-sheet .sheet-close { background: rgba(255,255,255,.10) !important; color: rgba(255,255,255,.70) !important; }
.login-sheet .sheet-input { background: rgba(255,255,255,.07) !important; color: #f0f0ff !important; border-color: rgba(255,255,255,.18) !important; }
.login-sheet .sheet-input::placeholder { color: rgba(255,255,255,.35) !important; }
.login-sheet .sheet-input:focus { border-color: rgba(99,102,241,.70) !important; background: rgba(255,255,255,.11) !important; }
.login-sheet .sheet-sep { color: rgba(255,255,255,.35) !important; }
.login-sheet .sheet-sep::before, .login-sheet .sheet-sep::after { background: rgba(255,255,255,.12) !important; }
.login-sheet .sheet-handle { background: rgba(255,255,255,.22) !important; }
.login-sheet .sheet-reg-link { color: rgba(255,255,255,.45) !important; }
.login-sheet .sheet-reg-link a { color: #a5b4fc !important; }
.login-sheet .tg-btn-wrap { display: block; width: 100%; }
.login-sheet #back-email-btn { color: rgba(255,255,255,.45) !important; }
.login-sheet #otp-step2 p { color: rgba(255,255,255,.60) !important; }
.login-sheet #otp-step2 strong { color: #f0f0ff !important; }
.login-backdrop.open { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; background: rgba(0,0,0,.28) !important; }
.login-sheet {
  backdrop-filter: blur(40px) saturate(1.6) !important;
  -webkit-backdrop-filter: blur(40px) saturate(1.6) !important;
  border: 1.5px solid transparent !important;
  background:
    rgba(8,6,30,.80) padding-box,
    linear-gradient(135deg, rgba(255,255,255,.22) 0%, rgba(99,102,241,.50) 50%, rgba(139,92,246,.30) 100%) border-box !important;
  box-shadow: 0 -12px 60px rgba(0,0,0,.50), 0 -4px 32px rgba(99,102,241,.20), inset 0 1.5px 0 rgba(255,255,255,.10) !important;
}
