.account-widget {
  position: fixed;
  top: 12px;
  right: 12px;
  z-index: 300;
  display: flex;
  gap: 6px;
  align-items: center;
}

.account-btn {
  font-size: 0.72rem;
  padding: 6px 10px;
}

.account-email {
  color: var(--green-faint);
  font-size: 0.75rem;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-modal {
  position: fixed;
  inset: 0;
  z-index: 400;
  background: rgba(0, 0, 0, 0.7);
  align-items: center;
  justify-content: center;
}

.account-modal:not([hidden]) {
  display: flex;
}

.account-modal-box {
  width: min(320px, 90vw);
  background: var(--bg-panel);
  border: 1px solid var(--green-dim);
  border-radius: 6px;
  padding: 16px;
}

.account-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  color: var(--green);
}

.account-modal-close {
  background: transparent;
  border: none;
  color: var(--green-faint);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.account-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.account-form input {
  font-family: var(--font);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  padding: 10px;
  font-size: 0.85rem;
}

.account-form input:focus {
  outline: none;
  border-color: var(--green);
}

.account-error {
  margin: 0;
  color: var(--red);
  font-size: 0.75rem;
}

.account-submit {
  padding: 10px;
}

.account-switch {
  background: transparent;
  border: none;
  color: var(--cyan);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 4px;
}
