:root{--teal:#079b91;--teal2:#087d82;--deep:#07546a;--ink:#132d49;--muted:#718399;--line:#dce8ef;--bg:#edf5f8;--white:#fff;--mint:#e3fbf3;--shadow:0 5px 18px rgba(18,55,78,.09);--red:#ed4e70;--blue:#21a9e8;--green:#1bbd78;--amber:#f3b92f}*{box-sizing:border-box}body{margin:0;background:linear-gradient(145deg,#e6f2f6,#f6fafc 45%,#eaf5f7);color:var(--ink);font-family:system-ui,-apple-system,"Segoe UI",sans-serif;font-size:16px}.app-shell{width:min(100%,620px);min-height:100dvh;margin:auto;background:#f5f9fb;padding-bottom:calc(84px + env(safe-area-inset-bottom));box-shadow:0 0 35px #163d5510}.topbar{height:76px;padding:10px 18px;background:linear-gradient(110deg,#064f66,#087d87 60%,#0c9b91);color:#fff;display:flex;align-items:center;justify-content:space-between;position:sticky;top:0;z-index:5;box-shadow:0 3px 14px #063f5730}.brand{display:flex;align-items:center;gap:11px}.brand-icon{width:46px;height:46px;border-radius:16px;background:#fff;color:#ed5367;display:grid;place-items:center;font-size:29px;box-shadow:inset 0 0 0 3px #b5f1e6}.brand strong{display:block;font-size:17px;letter-spacing:.1px}.brand small{display:block;font-size:11px;opacity:.9}.icon-btn,.icon-action{width:44px;height:44px;border:1px solid #ffffff65;background:#ffffff20;color:#fff;border-radius:15px;font-size:22px}.page{display:none;padding:15px 13px 22px}.page.active{display:block;animation:fade .18s ease}@keyframes fade{from{opacity:.65;transform:translateY(3px)}to{opacity:1;transform:none}}.page-heading{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:3px 4px 13px}.page-heading h1{font-size:24px;margin:2px 0 0}.eyebrow{font-size:11px;font-weight:800;color:var(--teal);letter-spacing:.3px}.date-control{display:flex;align-items:center;gap:8px;background:#fff;border:1px solid var(--line);border-radius:30px;padding:5px 8px;box-shadow:var(--shadow)}.date-control strong{font-size:12px;white-space:nowrap}.round-btn{border:0;border-radius:50%;width:31px;height:31px;background:#e8f5f7;color:var(--deep);font-size:24px;line-height:1}.card{background:#fff;border:1px solid #e1ebf0;border-radius:21px;padding:15px;margin:11px 0;box-shadow:var(--shadow)}.hero-card{margin:0 0 12px;padding:17px 18px 14px;border-radius:23px;color:#fff;background:linear-gradient(125deg,#08a98b,#087e83 75%,#07596d);box-shadow:0 8px 20px #078e8340}.hero-top,.hero-bottom{display:flex;justify-content:space-between;align-items:center;gap:8px}.hero-top{font-weight:800;font-size:14px}.hero-top small,.hero-bottom small{font-size:11px;opacity:.85}.hero-reading{display:flex;justify-content:space-between;align-items:center;padding:12px 0 9px;gap:10px}.hero-reading>div:first-child strong{display:block;font-size:clamp(42px,12vw,58px);line-height:1;letter-spacing:-2px}.hero-reading>div:first-child span{font-size:13px;opacity:.85}.pulse-box{background:#ffffffed;color:var(--deep);border-radius:17px;padding:9px 13px;min-width:98px;text-align:center}.pulse-box span{display:block;color:#e64d68;font-size:12px;font-weight:800}.pulse-box strong{display:block;font-size:30px;line-height:1.15}.pulse-box small{font-size:10px;color:var(--muted)}.hero-bottom{border-top:1px solid #ffffff45;padding-top:10px}.status-pill{padding:6px 11px;border-radius:30px;background:#e8f1f5;color:#536b7e;font-size:12px;font-weight:800}.status-pill.warn{background:#fff0c8;color:#875b00}.status-pill.high{background:#ffe1e8;color:#a51d43}.status-pill.low{background:#e5efff;color:#245a9b}.section-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:12px}.section-head>div{display:flex;align-items:center;gap:10px}.section-head h2{font-size:16px;margin:0}.section-head small{display:block;font-size:11px;color:var(--muted);margin-top:2px}.section-icon{width:39px;height:39px;border-radius:14px;background:#e4f8f3;display:grid;place-items:center;font-size:21px}.text-btn{border:0;background:transparent;color:var(--teal2);font-weight:800;font-size:13px;padding:8px 3px;white-space:nowrap}.schedule-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.schedule-item{display:flex;align-items:center;gap:8px;padding:10px;background:#f5fafc;border:1px solid #e1edf2;border-radius:15px;min-width:0}.schedule-item.done{background:#edfbf5;border-color:#c7efdf}.schedule-emoji{font-size:23px}.schedule-info{min-width:0;flex:1}.schedule-info strong{display:block;font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.schedule-info small{color:var(--muted);font-size:11px}.schedule-check{font-size:18px;color:#16a66d}.quick-actions{display:grid;grid-template-columns:1.2fr 1fr;gap:8px;margin-top:12px}.primary-btn,.quick-btn,.soft-btn,.primary-small{min-height:48px;border-radius:15px;padding:8px 12px;font:inherit;font-weight:800;cursor:pointer}.primary-btn{border:0;color:#fff;background:linear-gradient(110deg,#08b995,#078c89);box-shadow:0 3px 0 #08756f}.quick-btn{border:1px solid #b9e5e8;background:#e9f8fa;color:#087b83}.soft-btn{border:1px solid #d3e1e9;background:#f4f8fa;color:var(--ink)}.primary-small{min-height:38px;border:0;background:#e2f8f1;color:#078b79;font-size:13px}.today-list{display:grid;gap:7px}.today-row,.history-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 11px;border:1px solid #e5edf2;background:#f9fbfc;border-radius:14px}.row-main{min-width:0}.row-main strong{display:block;font-size:13px}.row-main small{display:block;color:var(--muted);font-size:11px;margin-top:2px}.row-value{text-align:right;white-space:nowrap}.row-value strong{font-size:18px;color:#087f79}.row-value small{display:block;color:var(--muted);font-size:10px}.empty-state{padding:22px 10px;text-align:center;color:var(--muted);font-size:13px}.heading-icon{font-size:29px}.range-tabs{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;background:#edf4f7;padding:4px;border-radius:14px}.range-tabs button{border:0;border-radius:11px;background:transparent;min-height:39px;font-weight:800;font-size:12px;color:#617589}.range-tabs button.selected{background:linear-gradient(110deg,#08c5a5,#10a4a0);color:white;box-shadow:0 2px 7px #079b9140}.custom-range,.filter-row{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}.custom-range label,.filter-card label{font-size:12px;font-weight:700;color:#526b80;display:grid;gap:5px}.custom-range input,.filter-card input,.filter-card select,.modal-form input,.modal-form textarea,.modal-form select{width:100%;min-height:43px;border:1px solid #cfdee7;border-radius:12px;padding:9px 10px;background:#fff;color:var(--ink);font:inherit}.custom-range .soft-btn{align-self:end}.chart-legend{display:flex;justify-content:center;gap:19px;margin:16px 0 5px;font-size:12px;font-weight:700;color:#496176}.dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:5px}.dot.sys{background:var(--blue)}.dot.dia{background:var(--red)}.chart-wrap{width:100%;min-height:195px}.chart-wrap svg{display:block;width:100%;height:auto;overflow:visible}.chart-note,.helper-text{font-size:11px;color:var(--muted);line-height:1.5;margin:8px 2px 0}.stat-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin:11px 0}.stat-card{background:#e5f7fc;border:1px solid #c9eaf4;border-radius:18px;padding:13px;box-shadow:var(--shadow)}.stat-card span{display:block;color:#456579;font-size:12px;font-weight:800}.stat-card strong{display:block;font-size:25px;color:#087fa5;margin:4px 0 0}.stat-card small{font-size:10px;color:var(--muted)}.stat-card.pink{background:#fff0f4;border-color:#f9d9e2}.stat-card.pink strong{color:#e34e76}.stat-card.mint{background:#e9fbf4;border-color:#c9f1df}.stat-card.mint strong{color:#159b72}.stat-card.blue{background:#edf3ff;border-color:#d7e3ff}.stat-card.blue strong{color:#426bb5}.insight-card p{font-size:13px;line-height:1.55;margin:4px 0;color:#365269}.muted{font-size:11px;color:var(--muted)}.icon-action{background:#e3f7f2;color:#078a7e;border:0;font-size:23px}.filter-card{display:grid;gap:9px}.filter-card label{min-width:0}.filter-card input[type=search]{margin-top:1px}.filter-row{margin-top:0;align-items:end}.filter-row .soft-btn{min-height:43px}.history-summary{font-size:12px;font-weight:800;color:#61788b;margin:13px 4px 7px}.history-list{display:grid;gap:8px}.history-row{padding:12px}.history-actions{display:flex;gap:5px}.history-actions button{border:1px solid #dce8ee;background:#fff;border-radius:10px;min-width:36px;min-height:36px;color:#426074}.settings-slots{display:grid;gap:7px}.setting-slot{display:grid;grid-template-columns:1fr auto auto;gap:7px;align-items:center;padding:9px;background:#f7fafb;border:1px solid #e4edf1;border-radius:13px}.setting-slot strong{font-size:13px}.setting-slot small{display:block;color:var(--muted);font-size:11px}.setting-slot button{min-width:38px;min-height:38px;border:1px solid #dce7ed;background:white;border-radius:10px}.setting-slot button.delete{color:#c63e58}.backup-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}.full{width:100%}.about-card{display:grid;gap:4px;text-align:center;padding:17px;color:#61798c;font-size:12px}.about-card strong{color:#087d82;font-size:14px}.about-card small{font-size:10px}.bottom-nav{position:fixed;bottom:0;left:50%;transform:translateX(-50%);width:min(620px,100%);height:calc(72px + env(safe-area-inset-bottom));padding:6px 9px calc(6px + env(safe-area-inset-bottom));background:#fff;border-top:1px solid #dce7ed;display:grid;grid-template-columns:repeat(4,1fr);z-index:8;box-shadow:0 -5px 18px #143c5510}.nav-item{border:0;background:transparent;color:#73869a;border-radius:14px;display:grid;place-items:center;align-content:center;gap:1px;font-size:11px;font-weight:800}.nav-item span{font-size:22px;line-height:1.2}.nav-item.active{background:#e3f8f2;color:#078a7d}.modal-form{padding:19px;width:min(92vw,470px);max-height:min(86dvh,760px);overflow:auto;display:grid;gap:13px}.modal-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}.modal-head h2{margin:2px 0;font-size:20px}.modal-head p{font-size:12px;color:var(--muted);margin:2px 0}.close-btn{border:0;background:#edf3f6;border-radius:50%;width:38px;height:38px;font-size:24px;color:#52697c;flex-shrink:0}.modal-form label{display:grid;gap:6px;font-size:13px;font-weight:800;color:#3c566d}.number-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:7px}.number-grid input{text-align:center;font-size:21px;font-weight:800;padding:8px 4px}.modal-actions{display:grid;grid-template-columns:1fr 1.2fr;gap:8px;margin-top:3px}.modal-actions button{min-height:47px}.modal-form textarea{resize:vertical}.modal-form .choice-row{display:flex;gap:8px;flex-wrap:wrap}.choice-row label{display:flex;align-items:center;gap:6px;background:#f2f8fa;padding:9px 11px;border-radius:12px}.choice-row input{width:18px;min-height:18px}.toast{position:fixed;bottom:calc(85px + env(safe-area-inset-bottom));left:50%;transform:translate(-50%,15px);background:#153d50;color:white;border-radius:30px;padding:11px 17px;font-size:13px;opacity:0;pointer-events:none;transition:.2s;z-index:20;max-width:90%;text-align:center}.toast.show{opacity:1;transform:translate(-50%,0)}dialog{border:0;border-radius:22px;padding:0;max-width:calc(100% - 20px);box-shadow:0 20px 65px #0a2a4055}dialog::backdrop{background:#092b3c99}button{cursor:pointer}button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #67d8ca;outline-offset:2px}[hidden]{display:none!important}@media(min-width:700px){body{padding:20px 0}.app-shell{border-radius:25px;overflow:hidden;min-height:calc(100dvh - 40px)}.topbar{position:relative}.bottom-nav{bottom:20px;border-radius:0 0 25px 25px}.page{padding:20px 20px 26px}.schedule-list{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:380px){.page-heading h1{font-size:21px}.date-control{gap:4px}.date-control strong{font-size:11px}.schedule-list{grid-template-columns:1fr 1fr}.hero-reading>div:first-child strong{font-size:42px}.range-tabs button{font-size:10px;padding:0 2px}.number-grid{gap:4px}}
.slot-choice{width:100%;display:flex;justify-content:space-between;align-items:center;min-height:50px;padding:10px 13px;border:1px solid #dce9ef;background:#f7fbfc;border-radius:13px;color:var(--ink);font:inherit;font-weight:700}.slot-choice strong{color:var(--teal2)}.history-entry{display:grid;gap:5px}.history-entry .history-row{border-radius:14px 14px 8px 8px}.entry-actions{display:flex;justify-content:flex-end;gap:6px;padding:0 5px 4px}.entry-actions button{min-height:34px;font-size:12px;padding:4px 13px}.entry-actions .danger{color:#b82d4a;border-color:#f3d0d8;background:#fff7f8}
