.wl-sleep-page { max-width:980px; margin:0 auto; padding:28px 18px 56px; color:var(--wl-text); }
.wl-sleep-head { display:flex; align-items:flex-end; justify-content:space-between; gap:18px; margin-bottom:18px; }
.wl-sleep-head > div > span { color:var(--wl-accent); font-size:11px; font-weight:800; letter-spacing:.11em; }
.wl-sleep-head h1 { margin:5px 0 7px; font-size:30px; }
.wl-sleep-head p { margin:0; color:var(--wl-text-muted); font-size:14px; }
.wl-sleep-growth-link { color:var(--wl-accent); font-size:13px; font-weight:700; }
.wl-sleep-overview { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-bottom:16px; }
/* 2026-08-22 大圆角 + 玻璃态已上移到 unified-ui.css 统一面板声明块。 */
.wl-sleep-overview article, .wl-sleep-calendar-panel { padding:17px; border:1px solid var(--wl-border-light); background:var(--wl-bg-card); }
.wl-sleep-overview span { display:block; color:var(--wl-text-muted); font-size:12px; }
.wl-sleep-overview b { display:block; margin-top:6px; color:var(--wl-accent); font-size:26px; line-height:1; }
.wl-sleep-overview b small { color:var(--wl-text-muted); font-size:12px; font-weight:500; }
.wl-sleep-overview p { min-height:18px; margin:8px 0 0; color:var(--wl-text-muted); font-size:11px; line-height:1.45; }
.wl-sleep-calendar-head { display:flex; align-items:center; justify-content:center; gap:15px; margin-bottom:14px; }
.wl-sleep-calendar-head h2 { min-width:150px; margin:0; text-align:center; font-size:18px; }
.wl-sleep-calendar-head button { display:grid; place-items:center; width:30px; height:30px; padding:0; border:0; border-radius:50%; background:var(--wl-bg-hover); color:var(--wl-text-secondary); font-size:23px; line-height:1; cursor:pointer; }
.wl-sleep-calendar-head button:hover { background:color-mix(in srgb,var(--wl-accent) 13%,var(--wl-bg-hover)); color:var(--wl-accent); }
.wl-sleep-weekdays, .wl-sleep-calendar { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:7px; }
.wl-sleep-weekdays { margin-bottom:7px; color:var(--wl-text-muted); font-size:11px; font-weight:700; text-align:center; }
.wl-sleep-day, .wl-sleep-calendar-blank { min-height:93px; border:1px solid var(--wl-border-light); border-radius:11px; background:var(--wl-bg-card); }
.wl-sleep-day { padding:8px; text-align:left; cursor:pointer; transition:border-color .16s ease, transform .16s ease, box-shadow .16s ease; }
.wl-sleep-day:hover { border-color:color-mix(in srgb,var(--wl-accent) 55%,var(--wl-border)); transform:translateY(-1px); box-shadow:0 5px 15px color-mix(in srgb,var(--wl-accent) 12%,transparent); }
.wl-sleep-day.is-today { border-color:var(--wl-accent); }
.wl-sleep-day.is-recorded { background:color-mix(in srgb,var(--wl-accent) 6%,var(--wl-bg-card)); }
.wl-sleep-day.is-future { opacity:.48; cursor:default; }
.wl-sleep-day b { display:block; margin-bottom:7px; color:var(--wl-text-secondary); font-size:13px; }
.wl-sleep-time { display:block; margin-top:3px; overflow:hidden; color:var(--wl-text-muted); font-size:10px; line-height:1.3; text-overflow:ellipsis; white-space:nowrap; }
.wl-sleep-day.is-recorded .wl-sleep-time { color:var(--wl-text-secondary); }
.wl-sleep-time::first-letter { color:var(--wl-accent); font-weight:800; }
.wl-sleep-duration { display:block; margin-top:5px; overflow:hidden; color:var(--wl-accent); font-size:10px; font-weight:800; line-height:1.25; text-overflow:ellipsis; white-space:nowrap; }
/* 2026-08-22 大圆角 + 玻璃态已上移到 unified-ui.css 统一面板声明块。 */
.wl-sleep-trend-panel { margin-top:16px; padding:17px; border:1px solid var(--wl-border-light); background:var(--wl-bg-card); }
.wl-sleep-trend-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:12px; flex-wrap:wrap; }
.wl-sleep-trend-head h2 { margin:0; font-size:18px; }
.wl-sleep-trend-tabs { display:flex; gap:6px; padding:3px; border-radius:11px; background:var(--wl-bg-hover); }
.wl-sleep-trend-tabs button { padding:6px 13px; border:0; border-radius:8px; background:transparent; color:var(--wl-text-muted); font-size:12px; font-weight:700; cursor:pointer; transition:background .15s ease,color .15s ease; }
.wl-sleep-trend-tabs button:hover { color:var(--wl-text-secondary); }
.wl-sleep-trend-tabs button.is-active { background:var(--wl-bg-card); color:var(--wl-accent); box-shadow:0 1px 4px rgba(31,35,42,.1); }
.wl-sleep-trend-head-controls { display:flex; align-items:center; gap:10px; flex-wrap:wrap; justify-content:flex-end; }
.wl-sleep-trend-range { display:flex; gap:4px; padding:3px; border-radius:11px; background:var(--wl-bg-hover); }
.wl-sleep-trend-range button { padding:6px 14px; border:0; border-radius:8px; background:transparent; color:var(--wl-text-muted); font-size:12px; font-weight:700; cursor:pointer; transition:background .15s ease,color .15s ease; }
.wl-sleep-trend-range button:hover { color:var(--wl-text-secondary); }
.wl-sleep-trend-range button.is-active { background:var(--wl-bg-card); color:var(--wl-accent); box-shadow:0 1px 4px rgba(31,35,42,.1); }
.wl-sleep-trend-chart svg { display:block; width:100%; height:auto; }
.wl-sleep-trend-grid { stroke:var(--wl-border-light); stroke-width:1; }
.wl-sleep-trend-ylabel, .wl-sleep-trend-xlabel { fill:var(--wl-text-muted); font-size:10px; }
.wl-sleep-trend-avg { stroke:var(--wl-accent); stroke-width:1; stroke-dasharray:5 4; opacity:.55; }
.wl-sleep-trend-avglabel { fill:var(--wl-accent); font-size:10px; font-weight:700; opacity:.8; }
.wl-sleep-trend-area { fill:color-mix(in srgb,var(--wl-accent) 10%,transparent); stroke:none; }
.wl-sleep-trend-line { fill:none; stroke:var(--wl-accent); stroke-width:2; stroke-linecap:round; stroke-linejoin:round; }
.wl-sleep-trend-dot { fill:var(--wl-bg-card); stroke:var(--wl-accent); stroke-width:2; }
.wl-sleep-trend-dot:hover { fill:var(--wl-accent); }
.wl-sleep-trend-empty { padding:34px 14px; color:var(--wl-text-muted); font-size:13px; text-align:center; }
.wl-sleep-trend-note { margin:10px 0 0; color:var(--wl-text-muted); font-size:11px; line-height:1.5; }
.wl-sleep-dialog[hidden], .wl-sleep-toast[hidden] { display:none!important; }
.wl-sleep-dialog { position:fixed; z-index:9999; inset:0; display:grid; place-items:center; padding:20px; }
.wl-sleep-dialog-backdrop { position:absolute; inset:0; background:rgba(31,35,42,.42); backdrop-filter:blur(3px); }
.wl-sleep-dialog-card { position:relative; z-index:1; width:min(100%,390px); padding:25px; border:1px solid var(--wl-border-light); border-radius:20px; background:var(--wl-bg-card); box-shadow:0 24px 70px rgba(33,36,43,.24); }
.wl-sleep-dialog-card > span { color:var(--wl-accent); font-size:11px; font-weight:800; letter-spacing:.11em; }
.wl-sleep-dialog-card h2 { margin:6px 0 18px; font-size:22px; }
.wl-sleep-dialog-card form { display:grid; gap:12px; }
.wl-sleep-dialog-card label { display:grid; grid-template-columns:88px 1fr; align-items:center; gap:10px; color:var(--wl-text-secondary); font-size:13px; font-weight:700; }
.wl-sleep-dialog-card input { box-sizing:border-box; width:100%; height:39px; padding:0 10px; border:1px solid var(--wl-border); border-radius:9px; background:var(--wl-bg-hover); color:var(--wl-text); font:inherit; }
.wl-sleep-dialog-card p { margin:1px 0 0; color:var(--wl-text-muted); font-size:11px; line-height:1.55; }
.wl-sleep-dialog-close { position:absolute; top:11px; right:12px; display:grid; place-items:center; width:30px; height:30px; padding:0; border:0; border-radius:50%; background:transparent; color:var(--wl-text-muted); font-size:22px; line-height:1; cursor:pointer; }
.wl-sleep-dialog-close:hover { background:var(--wl-bg-hover); color:var(--wl-text); }
.wl-sleep-dialog-actions { display:flex; justify-content:space-between; gap:9px; margin-top:5px; }
.wl-sleep-toast { position:fixed; z-index:10000; left:50%; bottom:25px; max-width:calc(100vw - 32px); padding:10px 14px; transform:translateX(-50%); border-radius:10px; background:#a54545; color:#fff; box-shadow:0 8px 25px rgba(0,0,0,.2); font-size:13px; line-height:1.5; }
@media (max-width:700px) { .wl-sleep-page { padding:20px 13px 42px; } .wl-sleep-head { align-items:flex-start; flex-direction:column; } .wl-sleep-head h1 { font-size:26px; } .wl-sleep-overview { grid-template-columns:1fr 1fr; } .wl-sleep-overview article:last-child { grid-column:1 / -1; } .wl-sleep-calendar-panel { padding:11px; } .wl-sleep-weekdays, .wl-sleep-calendar { gap:4px; } .wl-sleep-day, .wl-sleep-calendar-blank { min-height:76px; border-radius:8px; } .wl-sleep-day { padding:5px; } .wl-sleep-day b { margin-bottom:4px; font-size:11px; } .wl-sleep-time { margin-top:1px; font-size:8px; } .wl-sleep-duration { margin-top:3px; font-size:8px; } .wl-sleep-dialog { align-items:end; padding:12px; } .wl-sleep-dialog-card { width:100%; padding:22px 18px; border-radius:18px; } .wl-sleep-trend-panel { margin-top:12px; padding:13px 11px; } .wl-sleep-trend-head h2 { font-size:16px; } .wl-sleep-trend-tabs { width:100%; } .wl-sleep-trend-tabs button { flex:1; padding:6px 6px; font-size:11px; } .wl-sleep-trend-note { font-size:10px; } }
