/* =======================================================
   1. Google Fonts
   ======================================================= */
/* 1.1 思源黑體（繁體中文 Noto Sans TC） */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+TC:wght@400;500;600;700&display=swap');
/* 1.2 Poppins (备用中文/英文字) */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap');
/* 1.3 Outfit (英文主體) */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700&display=swap');

/* =======================================================
   2. 主题色 & 字体
   ======================================================= */
:root {
  --brand-blue:       #17A2B8;   /* 水蓝 */
  --brand-blue-dark:  #00405C;   /* 深蓝 */
  --brand-red:        #E10600;   /* 主红 */
  --font-zh:          'Noto Sans TC', sans-serif;
  --font-en:          'Outfit', sans-serif;
}

/* =======================================================
   3. 全站基础
   ======================================================= */
html {
  box-sizing: border-box;
}
*, *::before, *::after {
  box-sizing: inherit;
}
body {
  margin: 0;
  padding: 0;
  color: #333;
  font-family: var(--font-zh) !important;
}
html[lang="en"] body {
  font-family: var(--font-en) !important;
}

/* =======================================================
   4. 顶部深蓝细条
   ======================================================= */
.top-bar {
  height: 4px;
  background: var(--brand-blue-dark);
}

/* =======================================================
   5. Header 区块：Logo + 置中标题
   ======================================================= */
.header-title {
  font-size: 2rem;
  font-weight: 600;
  color: var(--brand-blue) !important;
  line-height: 1.2;
  font-family: var(--font-zh);
}
html[lang="en"] .header-title {
  font-family: var(--font-en);
}

/* =======================================================
   6. 导航列（去除 UL 前导点）
   ======================================================= */
.navbar {
  padding: 0;
}
.navbar-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: nowrap;
}
.navbar-nav .nav-item {
  margin: 0 0.5rem;
}
.navbar-nav .nav-link {
  color: var(--brand-blue-dark) !important;
  font-weight: 500;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  transition: background 0.3s, color 0.3s;
}
.navbar-nav .nav-link:hover {
  background: rgba(23,162,184,0.1);
  color: var(--brand-blue) !important;
}
.navbar-nav .nav-link.active {
  background: rgba(23,162,184,0.2);
  color: var(--brand-blue) !important;
}

/* =======================================================
   7. 显示登入者名称（主红 + 背景）
   ======================================================= */
.user-name {
  font-weight: 700 !important;
  color: var(--brand-red) !important;
  background: rgba(225,6,0,0.1) !important;
  padding: 0.2rem 0.5rem !important;
  border-radius: 4px !important;
  margin: 0 0.5rem !important;
}

/* =======================================================
   8. 页面主标题（更新纪录 / 设备管理等）
   ======================================================= */
.page-title {
  color: var(--brand-blue-dark) !important;
  font-family: var(--font-zh) !important;
  font-weight: 600 !important;
  font-size: 1.75rem !important;
  margin: 2rem 0 1rem !important;
}
html[lang="en"] .page-title {
  font-family: var(--font-en) !important;
}

/* =======================================================
   9. 返回首页 按钮区域
   ======================================================= */
.back-home {
  text-align: right;
  margin: 1.5rem 0;
}
.back-home .btn {
  border-radius: 4px;
}

/* =======================================================
   10. 浮动 “回到顶端” 按钮
   ======================================================= */
#backToTop {
  position: fixed;
  bottom: 30px;
  right: 30px;
  display: none !important;
  opacity: 0.4;
  background: var(--brand-blue-dark);
  color: #fff;
  border: none;
  padding: .8rem;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  transition: opacity .3s, background .3s;
  z-index: 1000;
}
#backToTop:hover {
  opacity: 1;
  background: var(--brand-red);
}

/* =======================================================
   11. Logo 右侧主标题 (.site-title)
   ======================================================= */
.site-title {
  display: inline-block;
  vertical-align: middle;
  font-size: 2rem !important;
  font-weight: 600 !important;
  color: var(--brand-blue) !important;
  line-height: 1.2 !important;
  font-family: var(--font-zh) !important;
}
html[lang="en"] .site-title {
  font-family: var(--font-en) !important;
}
/* ====================== 分享页面卡片风格 ====================== */
.share-card {
  border: none;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
  background: #fff;
}
.share-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}
.share-card .card-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.share-card .card-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--brand-blue-dark);
}
.share-card .btn-view {
  margin-top: auto;
  background: var(--brand-blue);
  border: none;
  color: #fff;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-transform: uppercase;
  transition: background 0.3s;
}
.share-card .btn-view:hover {
  background: var(--brand-blue-dark);
}
/* 圆角 pill 按钮 */
.btn-pill {
  border-radius: 20px !important;
  padding: 0.4rem 1rem !important;
}
/* share_device.php 专用行对齐 */
.share-row .row {
  min-height: 60px; /* 可按需要调整高度 */
}
