/* ============================================================================
   auth.css  ——  右上角登录入口、下拉菜单、登录弹层
   与 main.css 保持同一套字体（SimSun）和灰白配色；页面处于 quirks 模式，
   所以这里所有尺寸都写明确值，不依赖 flex 的默认行为。
   ============================================================================ */

/* ---- 右上角入口 ---------------------------------------------------------- */
#userInfo{padding:12px;font-family:SimSun;font-size:12px;cursor:pointer;float:right;white-space:nowrap;}
/* 昵称可能比较长：限宽后省略，避免把导航栏撑宽；下拉箭头（.caret）保持可见 */
#userInfo .uname{color:#333;display:inline-block;max-width:38vw;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:middle;}
#userInfo .caret{display:inline-block;margin-left:4px;width:0;height:0;border-left:4px solid transparent;border-right:4px solid transparent;border-top:5px solid #888;vertical-align:middle;}

/* ---- 下拉菜单 ------------------------------------------------------------
   .nav 有 overflow-x:auto，会把绝对定位的子元素裁掉，所以菜单放在 body 下、
   用 fixed 定位，位置由 auth.js 按导航栏实际高度算。 */
.user-menu{display:none;position:fixed;top:38px;right:10px;z-index:1001;min-width:132px;
  background:#FFFFFF;border:1px solid #DDDDDD;
  box-shadow:0 3px 10px rgba(0,0,0,.14);font-family:SimSun;font-size:13px;text-align:left;}
.user-menu a{display:block;padding:10px 16px;color:#333333;text-decoration:none;}
.user-menu a:hover{background-color:#F2F2F2;color:#333333;}

/* ---- 登录遮罩与弹层 ------------------------------------------------------ */
.auth-mask{display:none;position:fixed;left:0;top:0;width:100%;height:100%;
  background-color:rgba(0,0,0,.35);z-index:1200;}

.auth-box{position:absolute;left:50%;top:50%;width:300px;margin-left:-150px;margin-top:-148px;
  box-sizing:border-box;padding:20px 20px 16px 20px;background:#FFFFFF;
  border-radius:6px;box-shadow:0 10px 34px rgba(0,0,0,.28);
  font-family:SimSun;font-size:13px;text-align:left;}

.auth-head{font-size:15px;color:#333333;padding-bottom:14px;border-bottom:1px solid #EEEEEE;margin-bottom:16px;}

.auth-input{display:block;width:100%;box-sizing:border-box;height:38px;line-height:38px;
  padding:0 10px;margin:0 0 12px 0;border:1px solid #DDDDDD;border-radius:4px;
  background:#FFFFFF;color:#333333;font-family:SimSun;font-size:16px;outline:none;}
.auth-input:focus{border-color:#D92626;}

/* 验证码一行：输入框 + 按钮 */
.auth-code-row{position:relative;}
.auth-code-row .auth-code{width:100%;padding-right:112px;margin-bottom:12px;}
.auth-send{position:absolute;right:0;top:0;width:104px;height:38px;line-height:38px;
  padding:0;border:1px solid #DDDDDD;border-radius:4px;background:#F7F7F7;
  color:#333333;font-family:SimSun;font-size:12px;cursor:pointer;overflow:hidden;}
.auth-send:hover{background:#EFEFEF;}
.auth-send-off,.auth-send-off:hover{color:#AAAAAA;background:#F7F7F7;cursor:default;}

.auth-msg{min-height:18px;line-height:18px;margin:0 0 10px 0;color:#D92626;font-size:12px;}
.auth-msg-ok{color:#2E7D32;}

.auth-submit{display:block;width:100%;height:40px;line-height:40px;
  border:0;border-radius:4px;background:#D92626;color:#FFFFFF;
  font-family:SimSun;font-size:15px;cursor:pointer;}
.auth-submit:hover{background:#C21F1F;}
.auth-submit:disabled{background:#DDAAAA;cursor:default;}

.auth-close{display:block;margin-top:12px;text-align:center;color:#888888;font-size:12px;text-decoration:none;}
.auth-close:hover{color:#333333;}

/* 小屏：弹层留出边距，避免贴边 */
@media screen and (max-width: 360px) {
  .auth-box{width:calc(100% - 40px);margin-left:0;left:20px;}
}
