/* Matmap's installable shell: quiet paper, purple belt, generous touch targets. */
:root{--app-belt:#7955b5;--app-mat:#f5f6fa;--app-paper:#fff;--app-lavender:#f0eaf8;--app-success:#28766b}
body{background:var(--app-mat)}button,a,input,select,textarea{-webkit-tap-highlight-color:transparent}button:focus-visible,a:focus-visible{outline:3px solid #7955b5;outline-offset:3px}button:active{filter:brightness(.97)}
.pwa-bar{display:flex;align-items:center;gap:10px;justify-content:space-between;font-size:12px;padding:9px 32px;background:#edf5f3;color:#275e54;line-height:1.6}.pwa-bar[hidden]{display:none}.pwa-bar.offline{background:#fff3e3;color:#795225}.pwa-bar button{min-height:36px;flex-shrink:0}.pwa-bar .icon{width:16px;height:16px}.pwa-bar>span{display:flex;align-items:center;gap:7px}
.home-page{width:100%;max-width:1240px;margin:auto;padding:36px 40px 48px}.home-heading{display:flex;gap:24px;align-items:center;justify-content:space-between;margin-bottom:30px}.home-date{font-size:13px;font-weight:600;color:var(--app-belt);font-variant-numeric:tabular-nums;margin-bottom:12px}.home-heading h1{font-size:34px;letter-spacing:-1.5px;line-height:1.25;margin:0 0 12px;font-weight:750}.home-heading p:last-child{font-size:14px;color:#687080;line-height:1.7}.home-record-button{background:var(--ink);color:white;min-height:50px;padding:0 22px;flex-shrink:0;border-color:var(--ink)}.home-record-button:hover{background:#283753;color:#fff}
.home-grid{display:grid;grid-template-columns:1.05fr 1fr;gap:24px;align-items:start}.home-capture,.home-review,.home-journal{background:var(--app-paper);border:1px solid var(--line);border-radius:16px;padding:24px}.section-title{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:20px}.section-title h2{font-size:17px;letter-spacing:-.4px;margin:0}.section-title>span{font-size:11px;color:var(--muted)}.section-title .text-button{font-size:12px;min-height:36px}.capture-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.capture-grid button{display:flex;align-items:flex-start;flex-direction:column;text-align:left;border:1px solid #e2d9ee;background:#faf8fd;border-radius:12px;padding:20px 16px;min-height:142px;gap:9px}.capture-grid button:hover{background:var(--app-lavender);border-color:var(--app-belt)}.capture-grid .icon{color:var(--app-belt);width:24px;height:24px;margin-bottom:9px}.capture-grid strong{font-size:14px}.capture-grid span{font-size:11px;color:var(--muted);line-height:1.5}.home-week{display:flex;justify-content:space-between;padding-top:24px;margin-top:20px;border-top:1px solid var(--line)}.week-day{display:flex;align-items:center;flex-direction:column;gap:7px;width:32px;font-variant-numeric:tabular-nums}.week-day small{font-size:11px;color:var(--muted)}.week-day b{display:grid;place-items:center;width:30px;height:30px;font-size:12px;font-weight:500;border-radius:50%;color:#848899}.week-day.recorded b{background:var(--app-lavender);color:var(--app-belt);font-weight:700}.week-day.today b{outline:1px solid var(--app-belt);outline-offset:2px}
.home-empty{padding:15px 8px 10px;text-align:center}.empty-mark{display:grid;place-items:center;width:52px;height:52px;background:var(--app-mat);border-radius:14px;margin:0 auto 16px;color:var(--app-belt)}.home-empty h3,.home-empty h2{font-size:16px;margin-bottom:10px}.home-empty p{font-size:13px;color:var(--muted);line-height:1.8;margin-bottom:18px;max-width:300px;margin-inline:auto}.review-grid{display:grid;gap:10px}.review-card{display:flex;flex-direction:column;align-items:flex-start;text-align:left;gap:12px;width:100%;border:1px solid var(--line);border-radius:11px;padding:16px;background:#fff;overflow-wrap:anywhere}.review-card:hover{border-color:var(--app-belt);background:#faf8fd}.review-type{display:flex;align-items:center;gap:7px;font-size:11px;color:var(--app-belt)}.review-type .icon{width:15px;height:15px}.review-card strong{font-size:15px;line-height:1.6}.review-card>span:last-child{font-size:11px;color:var(--muted);display:flex;justify-content:space-between;width:100%;align-items:center}.review-card>span:last-child .icon{width:16px;height:16px}
.home-journal{grid-column:1/-1}.practice-entry{padding:20px 0;border-top:1px solid var(--line);overflow-wrap:anywhere}.entry-date{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}.entry-date time{font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums}.entry-date button{min-height:44px}.practice-entry h3{font-size:16px;margin-bottom:10px}.practice-entry>p{font-size:14px;line-height:1.9;color:#4e596b}.home-journal .practice-entry>p{display:-webkit-box;-webkit-line-clamp:4;-webkit-box-orient:vertical;overflow:hidden}.entry-techniques{display:flex;flex-wrap:wrap;gap:7px;margin-top:12px}.entry-techniques button{min-height:36px;background:var(--app-lavender);color:var(--app-belt);font-size:12px;border:0;border-radius:7px;padding:6px 10px}.journal-empty{padding:12px 0 8px}.journal-empty p{font-size:14px;line-height:1.9;color:var(--muted);margin-bottom:16px}.home-footnote{grid-column:1/-1;display:flex;align-items:center;gap:12px;padding:0 8px;color:var(--muted);font-size:12px;line-height:1.8}.home-footnote>span{color:var(--app-success)}.home-footnote button{margin-left:auto;flex-shrink:0}.practice-page,.more-page{width:100%;max-width:900px;margin:0 auto;padding:32px}.practice-page h1,.more-page h1{font-size:26px;letter-spacing:-.8px}.practice-page .section-title p{font-size:13px;color:var(--muted);margin-top:8px;line-height:1.7}.practice-page .practice-entry{background:white;border:1px solid var(--line);border-radius:12px;padding:20px;margin-bottom:14px}.more-grid{display:grid;gap:10px;margin:24px 0}.more-item{display:flex;align-items:center;justify-content:flex-start;gap:14px;border:1px solid var(--line);border-radius:12px;padding:18px;text-align:left;background:white;min-height:76px}.more-item>span{display:flex;flex-direction:column;gap:6px}.more-item strong{font-size:14px}.more-item small{font-size:12px;color:var(--muted);line-height:1.7}.more-item>.icon{color:var(--app-belt)}.more-item:hover{border-color:var(--app-belt)}
.favorite-button{min-width:44px;min-height:44px;flex-shrink:0;background:white;border:1px solid var(--line);border-radius:8px;color:var(--muted);font-size:20px}.favorite-button[aria-pressed=true]{color:#806018;background:#fff7de;border-color:#e9d699}.notebook-header .favorite-button{margin-left:auto}.practice-techniques{display:flex;flex-wrap:wrap;gap:8px;max-height:180px;overflow:auto;border:1px solid var(--line);padding:12px;border-radius:8px}.practice-techniques label{display:flex;align-items:center;gap:8px;font-size:13px;min-height:44px;padding:4px 8px;background:#f8f9fb;border-radius:6px}.practice-techniques input{width:18px;height:18px}.install-steps{padding:0 0 0 23px;font-size:14px;line-height:1.9}.install-steps li{padding:6px 0}.app-status-row{display:flex;justify-content:space-between;gap:16px;padding:14px 0;border-bottom:1px solid var(--line);font-size:13px;line-height:1.7}.app-status-row strong{color:var(--app-success)}.backup-progress{font-size:13px;line-height:1.8;color:var(--muted);margin:12px 0}.backup-summary{padding:16px;background:var(--app-lavender);border-radius:10px;font-size:13px;line-height:1.9}.device-note{font-size:12px;color:var(--muted);line-height:1.8;margin-top:20px}.quick-search-results{display:grid;gap:8px;max-height:48vh;overflow:auto}.quick-search-results button{border:1px solid var(--line);border-radius:8px;background:#fff;text-align:left;padding:12px;min-height:52px}.quick-search-results button:hover{background:var(--app-lavender)}.quick-search-results small{display:block;color:var(--muted);font-size:11px;margin-top:5px}
@media(max-width:1000px){.home-page{padding:28px 24px}.home-grid{gap:16px}.home-capture,.home-review,.home-journal{padding:20px}.home-heading h1{font-size:30px}.section-title>span{display:none}}
@media(max-width:760px){.practice-heading-fields{flex-direction:column;gap:0}.home-grid{grid-template-columns:1fr}.home-page{padding:24px 18px 28px}.home-heading{align-items:flex-start;flex-direction:column;gap:18px;margin-bottom:22px}.home-heading h1{font-size:30px}.home-record-button{width:100%;justify-content:center;min-height:50px}.home-capture,.home-review,.home-journal{border-radius:13px;padding:20px}.home-footnote{align-items:flex-start}.home-footnote button{min-height:44px}.practice-page,.more-page{padding:24px 18px}.practice-page .section-title{align-items:flex-start}.practice-page .section-title>.button{white-space:nowrap}.pwa-bar{padding:10px 16px}.shell{padding-bottom:calc(74px + env(safe-area-inset-bottom))}.workspace{margin-left:0!important;width:100%}.topbar{padding-top:calc(12px + env(safe-area-inset-top))}.topbar .top-actions>.button[data-action=import]{display:none}.graph-picker{max-width:42vw}.notebook{padding-bottom:env(safe-area-inset-bottom)}.notebook-header{padding-top:calc(16px + env(safe-area-inset-top))}.notebook-footer{padding-bottom:calc(14px + env(safe-area-inset-bottom))}dialog{max-height:calc(100dvh - 24px - env(safe-area-inset-top));}.modal-body{overscroll-behavior:contain}.form-field input,.form-field textarea,.form-field select{font-size:16px}.button,.text-button{min-height:44px}.practice-entry>p{font-size:14px}}
@media(max-width:359px){.home-page,.practice-page,.more-page{padding-left:12px;padding-right:12px}.home-capture,.home-review,.home-journal{padding:16px}.capture-grid button{padding:15px 11px}.capture-grid strong{font-size:13px}.capture-grid span{font-size:10px}.home-heading h1{font-size:28px}.home-footnote{flex-wrap:wrap}.home-footnote button{margin-left:28px}.topbar .account-button{font-size:11px;padding:7px 9px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition:none!important;animation:none!important}}
@media(max-width:1000px){.workspace{width:100%;height:auto;min-height:calc(100dvh - 74px)}.shell{display:block;padding-bottom:calc(74px + env(safe-area-inset-bottom))}.sidebar{display:contents!important}.sidebar>:not(.main-nav){display:none!important}.sidebar .main-nav{display:flex;position:fixed;inset:auto 0 0;z-index:25;width:100%;height:auto;margin:0;gap:2px;justify-content:space-around;padding:7px 6px calc(7px + env(safe-area-inset-bottom));background:#fffffff7;border-top:1px solid var(--line);backdrop-filter:blur(16px);overflow:visible}.sidebar .main-nav .nav-button[data-page=videos],.sidebar .main-nav .nav-button[data-page=explore]{display:none}.sidebar .main-nav .nav-button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:44px;min-height:48px;flex:1;padding:3px 4px;margin:0;font-size:10px;line-height:1.3;border-radius:9px;color:#737b89}.sidebar .main-nav .nav-button .icon{width:21px;height:21px;margin:0}.sidebar .main-nav .nav-button.active{background:var(--app-lavender);color:var(--app-belt)}}

@media(max-width:1000px){.icon-button{min-width:44px;min-height:44px}.top-actions .icon-button{width:44px;height:44px}#toast{bottom:calc(82px + env(safe-area-inset-bottom))}}
