:root {
  --cream: #fcf4e2;
  --green: #25e399;
  --warning: #d97757;
  --text: #111111;
  --muted: rgba(0, 0, 0, 0.78);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--cream); }
body {
  font-family: "PingFang TC", "PingFang SC", "Noto Sans CJK TC", "Microsoft JhengHei", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
}

.page {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--cream);
}
.page-glow::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  box-shadow:
    rgba(217, 119, 87, 0.51) 0 0 10px 0 inset,
    rgba(217, 119, 87, 0.31) 0 0 20px 0 inset,
    rgba(217, 119, 87, 0.106) 0 0 30px 0 inset;
  z-index: 0;
}
.site-header, .main-content, .footer { position: relative; z-index: 1; }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 31px 60px;
}
.brand { display: flex; align-items: center; gap: 8px; color: #000; }
.brand h6 { margin: 0; font-size: 18px; font-weight: 700; line-height: 1; }
.training-badge {
  border: 1px solid rgba(245, 158, 11, 0.55);
  background: #fef3c7;
  color: #92400e;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.download-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 161px;
  height: 51px;
  padding: 0 28px;
  border: none;
  border-radius: 999px;
  background: var(--green);
  color: #000;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity .2s ease, transform .2s ease;
}
.download-btn:hover { opacity: .9; transform: translateY(-1px); }
.main-content { flex: 1; padding: 0 60px; }
.login-card {
  max-width: 999px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  background: #fff;
  padding: 49px 44px;
  border: 1px solid #000;
  border-radius: 25px;
}
.login-copy { flex: 1; min-width: 0; }
.title { margin: 0 0 24px; font-size: 26px; font-weight: 600; line-height: 1.25; }
.intro { margin: 0 0 20px; font-size: 18px; line-height: 1.45; }
.steps { margin: 0; padding-left: 0; list-style: none; font-size: 18px; line-height: 1.45; }
.steps li + li { margin-top: 16px; }
.inline-icon { display: inline-flex; align-items: center; justify-content: center; vertical-align: middle; }
.dots { font-size: 18px; font-weight: 800; line-height: 1; }
.gear { font-size: 14px; }
.help-link { margin: 24px 0 0; font-size: 18px; text-decoration: underline; cursor: pointer; }
.qr-area { flex-shrink: 0; }
.fake-qr { display: block; max-width: 260px; width: 100%; height: auto; }
.footer {
  padding: 40px 24px;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
}
.encrypted-note { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 8px; }
.policy-link { text-decoration: underline; cursor: pointer; }
.training-note {
  max-width: 780px;
  margin: 24px auto 0;
  padding-top: 16px;
  border-top: 1px solid rgba(217, 119, 87, 0.4);
  color: #7a4a2a;
  font-size: 12px;
  line-height: 1.65;
}

@media (max-width: 820px) {
  .header-inner { padding: 24px 20px; }
  .download-btn { min-width: auto; height: 44px; padding: 0 18px; }
  .main-content { padding: 0 20px; }
  .login-card { flex-direction: column; align-items: flex-start; padding: 32px 24px; gap: 28px; }
  .qr-area { width: 100%; display: flex; justify-content: center; }
  .title { font-size: 23px; }
  .intro, .steps, .help-link { font-size: 16px; }
}

@media (max-width: 480px) {
  .brand { gap: 6px; }
  .brand h6 { font-size: 16px; }
  .training-badge { font-size: 10px; padding: 2px 6px; }
  .download-btn span { display: none; }
  .download-btn { width: 44px; padding: 0; }
  .login-card { border-radius: 18px; padding: 26px 18px; }
}



/* ===== subtle spacing refinement ===== */

/* only slightly improve readability */
h1{
  line-height:1.22 !important;
  margin-bottom:32px !important;
  letter-spacing:-0.01em !important;
}

p{
  line-height:1.58 !important;
  margin-bottom:16px !important;
  letter-spacing:0 !important;
}

/* ordered steps spacing */
ol{
  margin-top:24px !important;
  margin-bottom:28px !important;
}

ol li{
  margin-bottom:18px !important;
  line-height:1.6 !important;
}

/* bottom encryption/privacy text area */
footer,
.bottom,
.footer,
.privacy,
.encryption{
  padding-top:28px !important;
  padding-bottom:30px !important;
}

/* desktop only small adjustments */
@media (min-width:768px){
  h1{
    margin-bottom:36px !important;
  }

  ol li{
    margin-bottom:22px !important;
  }
}



/* ===== QR code proportional resize ===== */

img[src*="qr"],
img[src*="QR"],
.qr,
.qrcode,
.qr-code {
  width: clamp(220px, 22vw, 340px) !important;
  max-width: 92% !important;
  height: auto !important;
  display: block;
  margin: 18px auto 0 !important;
}

/* desktop */
@media (min-width: 768px){
  img[src*="qr"],
  img[src*="QR"],
  .qr,
  .qrcode,
  .qr-code {
    width: clamp(260px, 24vw, 380px) !important;
  }
}

/* mobile */
@media (max-width: 767px){
  img[src*="qr"],
  img[src*="QR"],
  .qr,
  .qrcode,
  .qr-code {
    width: min(72vw, 300px) !important;
    margin-top: 14px !important;
  }
}
