:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #17261f;
  background: #eef2ef;
}
* { box-sizing: border-box; }
html, body { width: 100%; min-width: 320px; height: 100%; margin: 0; }
button, input { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.app-shell { min-height: 100%; }
.connect-view { min-height: 100vh; padding: 42px clamp(24px, 6vw, 92px); background: radial-gradient(circle at 80% 12%, #d9e8df 0, transparent 34%), #eef2ef; }
.brand { color: #24563f; font-family: Georgia, serif; font-size: 24px; font-weight: 700; letter-spacing: 3px; }
.connect-card { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: clamp(40px, 7vw, 100px); align-items: center; max-width: 1180px; min-height: calc(100vh - 130px); margin: auto; }
.eyebrow { margin: 0 0 16px; color: #4f7965; font-size: 15px; font-weight: 750; letter-spacing: 2px; }
h1 { max-width: 680px; margin: 0; font-size: clamp(38px, 5vw, 68px); line-height: 1.12; letter-spacing: -2px; }
.login-note { display: inline-block; margin: 24px 0 0; padding: 10px 15px; border-radius: 12px; color: #285f46; background: #deebe3; font-size: 15px; font-weight: 700; }
ol { margin: 36px 0 0; padding-left: 26px; color: #43534b; font-size: 20px; line-height: 2; }
.security-note { max-width: 650px; margin: 30px 0 0; color: #718078; font-size: 15px; line-height: 1.7; }
.qr-panel { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 510px; padding: 42px; border: 1px solid rgba(45, 80, 62, .12); border-radius: 34px; background: rgba(255, 255, 255, .92); box-shadow: 0 28px 80px rgba(35, 68, 51, .12); }
.qr-image { width: min(100%, 330px); aspect-ratio: 1; }
.qr-loading { display: grid; place-items: center; width: 300px; aspect-ratio: 1; border-radius: 22px; color: #6c7972; background: #f2f5f3; }
.pair-code { margin-top: 18px; color: #58685f; font-size: 13px; letter-spacing: 5px; }
.connect-status { margin-top: 22px; color: #526159; font-size: 16px; text-align: center; }
.outline-button, .toolbar-button, .control-button { border: 0; border-radius: 12px; }
.outline-button { margin-top: 20px; padding: 11px 20px; color: #275a42; border: 1px solid #9db5a8; background: transparent; }
.presenter-view { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; width: 100vw; height: 100vh; overflow: hidden; background: #0d1210; }
.topbar, .controls { z-index: 4; display: flex; align-items: center; gap: 16px; padding: 14px 22px; color: #ecf2ef; background: rgba(15, 22, 18, .94); }
.topbar { justify-content: space-between; border-bottom: 1px solid #29322e; }
.title-wrap { min-width: 0; }
.deck-title { overflow: hidden; font-size: 17px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.identity-label { margin-top: 4px; color: #9eaba4; font-size: 12px; }
.top-actions { display: flex; gap: 10px; }
.toolbar-button { padding: 9px 15px; color: #e8efeb; background: #28332e; }
.toolbar-button.danger { color: #ffd9d4; background: #4c2925; }
.stage { position: relative; display: flex; align-items: center; justify-content: center; min-height: 0; overflow: hidden; background: #050706; }
.slide-image { width: 100%; height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.slide-loading { color: #c7d0cb; font-size: 17px; }
.nav-zone { position: absolute; z-index: 2; top: 0; bottom: 0; width: 18%; padding: 0; border: 0; opacity: 0; background: transparent; }
.nav-zone.previous { left: 0; }
.nav-zone.next { right: 0; }
.presenter-view:not(:fullscreen) .nav-zone { pointer-events: none; }
.controls { justify-content: center; border-top: 1px solid #29322e; }
.control-button { min-width: 94px; padding: 10px 18px; color: #dfe8e3; background: #2a3530; }
.control-button.primary { color: #fff; background: #2f7654; }
.control-button:disabled { cursor: default; opacity: .42; }
.page-jump { display: flex; align-items: center; gap: 8px; color: #b8c2bd; }
.page-jump input { width: 66px; padding: 9px 6px; border: 1px solid #45514b; border-radius: 9px; color: #fff; background: #171d1a; text-align: center; }
.shortcut-tip { margin-left: 14px; color: #86938c; font-size: 12px; }
.error-toast { position: fixed; z-index: 8; left: 50%; bottom: 88px; max-width: 560px; padding: 14px 20px; border-radius: 12px; color: #ffe5e1; background: rgba(120, 47, 38, .95); box-shadow: 0 12px 36px rgba(0,0,0,.35); transform: translateX(-50%); }
:fullscreen .topbar { display: none; }
:fullscreen .controls { position: fixed; right: 20px; bottom: 18px; left: 20px; border: 0; border-radius: 16px; opacity: .13; transition: opacity .2s; }
:fullscreen .controls:hover { opacity: .96; }
@media (max-width: 820px) {
  .connect-view { padding: 24px; }
  .connect-card { grid-template-columns: 1fr; gap: 28px; padding: 45px 0; }
  .qr-panel { min-height: 420px; }
  .shortcut-tip { display: none; }
}
