:root {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang HK", sans-serif;
  color: #253b38; background: #f7f8f5; font-size: 15px; line-height: 1.65; font-synthesis: none;
  --ink: #253b38; --muted: #77827d; --teal: #267b69; --border: #e5e9e2;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .6; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid #91bdae; outline-offset: 4px; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 600; letter-spacing: -.035em; }
h1 { font-size: clamp(30px, 4vw, 44px); line-height: 1.35; }
h2 { font-size: 21px; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
a { color: inherit; text-decoration: none; }
.topbar { height: 90px; max-width: 1232px; margin: auto; padding: 0 52px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--border); }
.brand { display: flex; align-items: center; gap: 10px; font-size: 23px; font-weight: 650; letter-spacing: -1px; }
.brand-dot { color: #72a38f; margin-left: -10px; }
.brand-mark { display: grid; place-items: center; background: var(--ink); color: #fff; border-radius: 11px; width: 34px; height: 34px; margin-right: 2px; }
.brand-mark svg { width: 20px; height: 20px; }
.topbar-end { display: flex; align-items: center; gap: 28px; }
.private-label { color: #8a938e; font-size: 12px; display: flex; align-items: center; gap: 5px; }
.private-label svg { width: 15px; height: 15px; }
.button-text { border: 0; padding: 4px 0; background: transparent; color: var(--teal); font-size: 13px; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: #b9d0c7; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; border-radius: 9px; padding: 11px 18px; font-size: 14px; font-weight: 550; border: 1px solid transparent; transition: background .15s, transform .15s; }
.button:active:not(:disabled) { transform: translateY(1px); }
.button-primary { background: var(--ink); color: white; }
.button-primary:hover:not(:disabled) { background: #36564f; }
.button-secondary { background: white; border-color: var(--border); color: var(--ink); }
.button-secondary:hover:not(:disabled) { background: #edf3ed; }
.button svg { width: 17px; height: 17px; }
.muted { color: var(--muted); }
.eyebrow { font-size: 10px; font-weight: 650; letter-spacing: .16em; color: #8a958e; margin-bottom: 8px; }
.initial-view { display: flex; align-items: center; justify-content: center; gap: 13px; min-height: 55vh; color: var(--muted); }
.spinner { width: 17px; height: 17px; border: 2px solid #d6e2d9; border-top-color: var(--teal); border-radius: 50%; animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.login-view { max-width: 1068px; padding: 80px 36px 48px; margin: auto; display: grid; grid-template-columns: 1.2fr 1fr; gap: 100px; align-items: center; }
.login-intro h1 { font-size: clamp(35px, 4.8vw, 55px); line-height: 1.35; letter-spacing: -.05em; margin-bottom: 24px; }
.intro-copy { color: var(--muted); font-size: 14px; line-height: 1.9; }
.login-card { padding: 40px 36px; background: white; border: 1px solid var(--border); border-radius: 18px; box-shadow: 0 12px 50px #253b3804; }
.card-icon { width: 43px; height: 43px; display: grid; place-items: center; color: var(--teal); background: #eef5ef; border-radius: 12px; margin-bottom: 24px; }
.login-card h2 { font-size: 25px; margin-bottom: 6px; }
.login-card > .muted { font-size: 13px; }
.login-card form { margin-top: 30px; }
.login-card label { display: block; font-size: 13px; font-weight: 550; margin-bottom: 9px; }
.login-card input { width: 100%; min-height: 48px; border: 1px solid #dce2db; border-radius: 8px; background: #fafbf8; color: var(--ink); padding: 11px 14px; }
.login-card input::placeholder { color: #a2aba4; font-size: 13px; }
.form-message { min-height: 23px; color: #a14d36; font-size: 12px; margin-top: 9px; }
.login-submit { width: 100%; justify-content: space-between; margin-top: 15px; }
.login-submit span { font-size: 21px; font-weight: 400; }
.login-footnote { margin-top: 24px; border-top: 1px solid #f0f2ed; padding-top: 20px; font-size: 11px; color: #939c94; line-height: 1.7; }
.home-scene { height: 240px; position: relative; margin-top: 24px; overflow: hidden; }
.scene-orbit { position: absolute; border: 1px solid #e4e9df; border-radius: 50%; width: 310px; height: 150px; left: 18px; top: 47px; transform: rotate(-20deg); }
.orbit-two { width: 390px; height: 210px; left: -20px; top: 20px; }
.scene-floor { position: absolute; width: 205px; height: 76px; border-radius: 50%; background: #dce7d980; filter: blur(9px); top: 120px; left: 71px; transform: rotate(-17deg); }
.vacuum-illustration { width: 158px; height: 158px; position: relative; background: linear-gradient(145deg, #fdfefa, #e4e8e0); border: 1px solid #d7ddd3; border-radius: 50%; box-shadow: inset 0 0 0 7px #f4f5f0, inset 0 0 0 9px #e7ebe2, 0 12px 22px #2b423410; flex-shrink: 0; }
.home-scene > .vacuum-illustration { position: absolute; left: 93px; top: 35px; transform: rotate(-17deg) scaleY(.86); }
.vacuum-illustration::after { content: ""; position: absolute; left: 29px; right: 29px; bottom: 43px; height: 1px; background: #d6ddd0; }
.vacuum-sensor { position: absolute; width: 39px; height: 39px; top: 25px; left: 58px; background: linear-gradient(145deg, #fafcf7, #dde4d7); border: 1px solid #cdd6c6; border-radius: 50%; box-shadow: inset 0 0 0 5px #edf1e8, 0 3px 5px #2b423411; }
.vacuum-light { position: absolute; top: 76px; left: 76px; width: 5px; height: 5px; border-radius: 50%; background: #7aaf96; box-shadow: 0 0 0 3px #deeadf; }
.vacuum-label { position: absolute; bottom: 24px; width: 100%; text-align: center; letter-spacing: .04em; font-size: 8px; color: #adb7a6; }
.scene-caption { position: absolute; bottom: 0; left: 50px; display: flex; align-items: center; gap: 7px; color: #8a978b; font-size: 11px; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; display: inline-block; flex-shrink: 0; }
.scene-caption .status-dot { color: #76a68c; }
.dashboard { max-width: 1232px; margin: auto; padding: 45px 52px 28px; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 30px; }
.page-heading h1 { font-size: 34px; margin-bottom: 8px; }
.page-heading .muted { font-size: 13px; }
.page-heading > .button { align-self: flex-end; margin-bottom: 3px; }
.notice { padding: 13px 17px; margin-bottom: 22px; background: #fff8e9; border: 1px solid #eee2c6; border-radius: 9px; color: #8d6a31; font-size: 13px; }
.overview-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 22px; }
.card { border: 1px solid var(--border); border-radius: 15px; background: #fff; }
.card-heading { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.card-heading .eyebrow { margin-bottom: 6px; }
.pill { display: inline-flex; align-items: center; gap: 7px; padding: 5px 10px; border-radius: 6px; font-size: 11px; font-weight: 550; white-space: nowrap; }
.neutral { background: #f1f3ef; color: #7b877b; }
.good { background: #e8f3ec; color: #31795f; }
.warning { background: #fff1da; color: #9b6a25; }
.bad { background: #fbece4; color: #a3623f; }
.vacuum-card, .connection-card { padding: 26px 28px 0; }
.vacuum-content { display: flex; align-items: center; justify-content: center; gap: 31px; min-height: 221px; padding: 20px 0 24px; }
.device-display { display: grid; place-items: center; position: relative; width: 185px; height: 180px; background: radial-gradient(ellipse, #f0f3eb 0%, #f8faf4 55%, transparent 71%); }
.device-display .vacuum-illustration { width: 146px; height: 146px; }
.device-display .vacuum-sensor { left: 52px; top: 24px; }
.device-display .vacuum-light { left: 70px; top: 75px; }
.device-reading { min-width: 140px; }
.reading-label { font-size: 11px; color: #939d94; margin-bottom: 5px; }
.vacuum-status { font-size: 24px; letter-spacing: -.03em; line-height: 1.4; margin-bottom: 18px; overflow-wrap: anywhere; }
.battery-reading { display: flex; align-items: baseline; gap: 9px; font-size: 11px; }
.battery-reading > span:first-child { font-size: 23px; font-variant-numeric: tabular-nums; font-weight: 500; }
.battery-reading .muted { font-size: 10px; }
meter { display: block; width: 99px; height: 5px; margin-top: 5px; border: 0; appearance: none; -webkit-appearance: none; background: #edf0e8; border-radius: 8px; overflow: hidden; }
meter::-webkit-meter-bar { background: #edf0e8; border: 0; border-radius: 8px; height: 5px; }
meter::-webkit-meter-optimum-value { background: #9cbba0; border-radius: 8px; }
meter::-moz-meter-bar { background: #9cbba0; }
.card-footer { display: flex; align-items: center; gap: 6px; border-top: 1px solid #eff1ec; padding: 15px 0; font-size: 10px; color: #98a093; }
.small-dot { width: 4px; height: 4px; border-radius: 50%; background: #a4b39f; flex-shrink: 0; }
.connection-icon { width: 27px; height: 27px; color: #9eaea0; stroke-width: 1.3; }
.connection-reading { padding: 23px 0 21px; }
.connection-reading h3 { font-size: 20px; margin: 14px 0 7px; }
.connection-reading > p { color: #899488; font-size: 12px; line-height: 1.8; min-height: 43px; }
.connection-times { border-top: 1px solid #eff1ec; padding: 11px 0 15px; margin: 0; }
.connection-times > div { display: flex; justify-content: space-between; gap: 15px; font-size: 10px; line-height: 2.2; }
.connection-times dt { color: #95a08f; }
.connection-times dd { margin: 0; color: #64715f; font-variant-numeric: tabular-nums; text-align: right; }
.reconnect-card { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding: 28px; margin-top: 22px; border-color: #eadfc9; background: #fffdf7; }
.reconnect-intro > p { font-size: 13px; color: #8c826e; max-width: 330px; margin: 12px 0 22px; line-height: 1.9; }
.qr-area { display: flex; align-items: center; gap: 20px; }
.qr-area img { width: 170px; height: 170px; object-fit: contain; border: 1px solid #e8e3d8; background: white; border-radius: 9px; padding: 9px; flex-shrink: 0; }
.qr-area .muted { font-size: 11px; margin: 5px 0 10px; }
.qr-status { font-size: 13px; font-weight: 600; }
.reconnect-card > .form-message { grid-column: 1/-1; min-height: 0; margin: 0; }
.activity-card { margin-top: 24px; padding: 25px 28px 0; }
.activity-count { font-size: 11px; color: #9aa392; background: #f4f6f0; padding: 4px 10px; border-radius: 5px; }
.activity-description { font-size: 11px; color: #98a18f; margin: 11px 0 20px; }
.activity-list { list-style: none; padding: 0; margin: 0; }
.activity-list li { display: flex; align-items: center; gap: 14px; padding: 17px 0; border-top: 1px solid #eff1ec; }
.event-dot { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 50%; background: #eef4eb; color: #87a47b; flex-shrink: 0; }
.event-dot::after { content: ""; width: 6px; height: 6px; background: currentColor; border-radius: 50%; }
.event-dot.warning { color: #b3894b; background: #fbf2e4; }
.event-copy { flex: 1; min-width: 0; }
.event-title { font-size: 13px; color: #495843; overflow-wrap: anywhere; }
.event-source { font-size: 10px; color: #a0aa95; margin-top: 2px; }
.event-time { font-size: 10px; color: #9aa48f; white-space: nowrap; font-variant-numeric: tabular-nums; }
.empty-state { padding: 30px 15px 40px; text-align: center; color: #8e9b85; }
.empty-state svg { width: 28px; height: 28px; stroke-width: 1.3; margin-bottom: 12px; }
.empty-state p { font-size: 13px; margin-bottom: 4px; }
.empty-state span { font-size: 11px; color: #a8b19f; }
.history-warning { font-size: 12px; color: #9a6d32; padding: 18px 0 25px; }
.dashboard-footer { display: flex; justify-content: space-between; gap: 20px; font-size: 10px; color: #a0aa96; margin-top: 25px; }
.dashboard-footer span { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (min-width: 1200px) {
  .login-view { padding-top: 105px; }
  .login-card { margin-top: -20px; }
}
@media (max-width: 900px) {
  .topbar { padding: 0 32px; }
  .dashboard { padding: 35px 32px 25px; }
  .login-view { gap: 44px; padding: 65px 32px; }
  .login-card { padding: 30px 26px; }
  .overview-grid { gap: 16px; grid-template-columns: 1.1fr 1fr; }
  .vacuum-card, .connection-card { padding: 23px 22px 0; }
  .vacuum-content { gap: 15px; }
  .device-display { width: 150px; }
  .device-reading { min-width: 115px; }
  .vacuum-status { font-size: 21px; }
  .reconnect-card { grid-template-columns: 1fr; }
  .qr-area { justify-content: flex-start; }
  .qr-area img { width: 185px; height: 185px; }
  .home-scene { transform: translateX(-18px); }
}
@media (max-width: 680px) {
  .topbar { height: 72px; padding: 0 22px; }
  .brand { font-size: 21px; }
  .brand-mark { width: 31px; height: 31px; border-radius: 9px; }
  .topbar-end { gap: 20px; }
  .private-label { font-size: 10px; }
  .login-view { display: flex; flex-direction: column; gap: 31px; padding: 39px 24px 42px; }
  .login-intro { width: 100%; text-align: center; }
  .login-intro h1 { font-size: 34px; margin-bottom: 15px; }
  .login-intro h1 br { display: none; }
  .intro-copy { font-size: 12px; }
  .home-scene { display: none; }
  .login-card { width: 100%; max-width: 390px; padding: 28px; }
  .card-icon { width: 35px; height: 35px; margin-bottom: 18px; }
  .card-icon svg { width: 21px; height: 21px; }
  .login-card h2 { font-size: 23px; }
  .dashboard { padding: 29px 20px 22px; }
  .page-heading { align-items: flex-start; gap: 12px; margin-bottom: 24px; }
  .page-heading h1 { font-size: 26px; margin-bottom: 8px; }
  .page-heading .eyebrow { font-size: 8px; letter-spacing: .12em; }
  .page-heading .muted { font-size: 12px; max-width: 210px; }
  .page-heading > .button { font-size: 11px; min-height: 38px; padding: 8px 11px; gap: 6px; align-self: center; flex-shrink: 0; }
  .page-heading > .button svg { width: 14px; height: 14px; }
  .overview-grid { grid-template-columns: 1fr; gap: 16px; }
  .vacuum-card, .connection-card { padding: 23px 23px 0; }
  .vacuum-content { justify-content: flex-start; gap: 30px; min-height: 201px; }
  .device-display { width: 156px; height: 160px; margin-left: 8px; }
  .device-display .vacuum-illustration { transform: scale(.95); }
  .vacuum-status { font-size: 24px; }
  .device-reading { min-width: 100px; }
  .connection-reading { padding: 22px 0 17px; }
  .connection-reading > p { min-height: 0; }
  .connection-times { padding: 12px 0 18px; }
  .connection-times > div { font-size: 11px; line-height: 2.2; }
  .connection-reading h3 { font-size: 21px; }
  .activity-card { padding: 23px 22px 0; margin-top: 16px; }
  .activity-description { line-height: 1.8; }
  .event-time { font-size: 9px; max-width: 68px; white-space: normal; text-align: right; }
  .event-title { font-size: 12px; }
  .activity-list li { gap: 10px; }
  .event-dot { width: 27px; height: 27px; }
  .dashboard-footer { flex-direction: column; gap: 7px; margin-top: 22px; font-size: 9px; }
  .reconnect-card { padding: 23px; margin-top: 16px; }
  .qr-area { flex-direction: column; align-items: flex-start; gap: 15px; }
  .qr-area img { width: 208px; height: 208px; align-self: center; }
  .qr-area > div { width: 100%; text-align: center; }
  .notice { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
