:root {
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #17324d;
  background: #f7faff;
  font-synthesis: none;
  color-scheme: light;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-soft: #eff6ff;
  --text: #17324d;
  --muted: #6b7c93;
  --border: #dce7f3;
  --surface: #fff;
}
* { box-sizing: border-box; }
body { margin: 0; background: #f7faff; color: var(--text); }
#app { min-height: 100vh; display: flex; flex-direction: column; }
#app > main { flex: 1; }
button, input, textarea, select { font: inherit; }
button { color: inherit; cursor: pointer; border: 0; background: none; }
a { color: var(--primary); }
button, a, input, textarea, select { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid #93c5fd; outline-offset: 3px; }
button:disabled { cursor: default; opacity: .65; }
.hidden { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; clip-path: inset(50%); }
.app-header { min-height: 82px; display: flex; align-items: center; gap: 24px; padding: 14px max(24px, calc((100vw - 1280px) / 2)); background: #fff; border-bottom: 1px solid var(--border); position: relative; z-index: 5; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 21px; letter-spacing: -.8px; text-decoration: none; color: var(--text); flex-shrink: 0; }
.logo-box { width: 36px; height: 36px; display: grid; place-items: center; background: var(--primary); color: #fff; border-radius: 11px; font-size: 24px; font-weight: 700; box-shadow: 0 4px 12px #2563eb20; }
.logo-box.mini { margin: auto; width: 44px; height: 44px; }
.segments { display: flex; align-items: center; justify-content: center; gap: 4px; margin: 0 auto; padding: 5px; background: #f3f7fd; border: 1px solid #e6eef8; border-radius: 13px; white-space: nowrap; }
.segments a { font-size: 13px; font-weight: 600; padding: 10px 13px; border-radius: 9px; color: var(--muted); text-decoration: none; transition: .2s; }
.segments a:hover { color: var(--primary); background: #e8f0ff; }
.segments a.active { background: var(--primary); color: #fff; box-shadow: 0 3px 8px #2563eb22; }
.header-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.icon-btn, .avatar { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); }
.icon-btn:hover { background: var(--primary-soft); color: var(--primary); }
.avatar, .profile-avatar, .mini-avatar { background: #dbeafe; color: var(--primary-dark); font-size: 11px; font-weight: 700; }
.account { position: relative; }
.account-menu { position: absolute; right: 0; top: 45px; width: 190px; border: 1px solid var(--border); background: #fff; border-radius: 12px; padding: 6px; box-shadow: 0 12px 30px #17324d12; }
.account-menu a, .account-menu button { display: block; width: 100%; text-align: left; padding: 10px; border-radius: 7px; font-size: 12px; text-decoration: none; color: inherit; }
.account-menu a:hover, .account-menu button:hover { background: var(--primary-soft); color: var(--primary); }
.quiet-btn { font-size: 12px; font-weight: 500; color: var(--muted); padding: 9px; }
.mint-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--primary); color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 13px; font-weight: 600; text-decoration: none; transition: .2s; }
.mint-btn:hover { background: var(--primary-dark); box-shadow: 0 5px 12px #2563eb20; }
.mint-btn.small { padding: 10px 14px; }
.outline-btn { border: 1px solid var(--border); background: #fff; padding: 11px 14px; border-radius: 10px; font-size: 12px; display: inline-flex; justify-content: center; gap: 7px; align-items: center; color: var(--text); text-decoration: none; }
.outline-btn:hover { background: var(--primary-soft); color: var(--primary); border-color: #a9c7fb; }
.section-page { width: min(1180px, calc(100% - 64px)); margin: 44px auto 64px; }
.page-title { max-width: 700px; }
.eyebrow { font-size: 11px; letter-spacing: 1.6px; color: var(--primary); font-weight: 700; }
.page-title h1, .forum-head h1 { margin: 12px 0 12px; font-size: clamp(30px, 3.3vw, 42px); letter-spacing: -1.5px; line-height: 1.2; }
.page-title p, .forum-head p { font-size: 14px; color: var(--muted); line-height: 1.75; margin: 0; }
.card { background: #fff; border: 1px solid var(--border); border-radius: 16px; padding: 24px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.card h2 { font-size: 17px; margin: 0; }
.card-head span, .card-head button { font-size: 11px; color: var(--muted); }
.search { height: 44px; min-width: 270px; display: flex; align-items: center; gap: 10px; padding: 0 14px; background: #fff; border: 1px solid var(--border); border-radius: 10px; color: var(--muted); }
.search:focus-within { border-color: #93b8f9; }
.search input { width: 100%; min-width: 0; border: 0; background: transparent; outline: 0; color: var(--text); font-size: 13px; }
.search input::placeholder, textarea::placeholder { color: #8495ab; }
.filters, .category-row { display: flex; gap: 8px; overflow: auto; padding: 3px 0 18px; }
.filters button, .category-row button, .chips button { font-size: 12px; color: var(--muted); padding: 10px 15px; border: 1px solid var(--border); border-radius: 100px; background: #fff; white-space: nowrap; transition: .2s; }
.filters button:hover, .category-row button:hover, .chips button:hover { color: var(--primary); border-color: #93b8f9; }
.filters button.selected, .category-row button.selected { background: var(--primary); color: #fff; border-color: var(--primary); font-weight: 600; }
.map-tools { display: flex; gap: 10px; margin: 28px 0 14px; }
.map-tools .search { flex: 1; }
.map-layout { display: grid; grid-template-columns: 340px 1fr; min-height: 480px; border: 1px solid var(--border); border-radius: 17px; overflow: hidden; background: #fff; }
.facility-list { border-right: 1px solid var(--border); overflow: auto; padding: 16px; }
.demo-label { font-size: 10px; color: var(--primary); letter-spacing: 1px; margin: 3px 5px 14px; }
.facility { display: flex; gap: 12px; padding: 17px 7px; border-bottom: 1px solid #edf2f8; }
.facility-dot { flex-shrink: 0; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; background: #e8f1ff; color: var(--primary); font-weight: 600; }
.facility b { font-size: 13px; }
.facility small { display: block; margin: 6px 0 0; color: var(--primary); font-size: 11px; }
.facility p { font-size: 12px; color: var(--muted); line-height: 1.6; margin: 8px 0; }
.facility-meta { font-size: 11px; color: var(--muted); }
.facility-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; }
.facility-actions button { font-size: 11px; color: var(--primary); }
.map-canvas { position: relative; overflow: hidden; background: #edf4fb; }
.map-grid { inset: 0; position: absolute; opacity: .65; background-image: linear-gradient(#cadceb 1px, transparent 1px), linear-gradient(90deg, #cadceb 1px, transparent 1px); background-size: 48px 48px; transform: skewY(-7deg) scale(1.2); }
.map-note { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; font-size: 14px; color: var(--primary-dark); line-height: 1.8; background: #ffffffed; border: 1px solid #c8dcf6; padding: 16px 20px; border-radius: 12px; box-shadow: 0 8px 20px #17324d08; }
.map-note small { color: var(--muted); font-size: 11px; }
.map-pin { position: absolute; background: var(--primary); color: #fff; height: 34px; width: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; box-shadow: 0 4px 12px #2563eb30; }
.map-pin.one { top: 25%; left: 24%; }
.map-pin.two { bottom: 23%; right: 21%; }
.forum-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; }
.forum-bar { display: flex; gap: 10px; margin: 28px 0 14px; }
.forum-bar .search { flex: 1; }
.forum-grid { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 24px; }
.post { border: 1px solid var(--border); background: #fff; border-radius: 15px; padding: 23px; margin-bottom: 14px; transition: .2s; }
.post:hover { border-color: #bed4f7; }
.post-top { display: flex; justify-content: space-between; align-items: center; }
.post-top > span { font-size: 10px; color: var(--primary); background: var(--primary-soft); padding: 6px 9px; border-radius: 6px; }
.post-top button { color: var(--muted); }
.post h2 { font-size: 18px; letter-spacing: -.5px; margin: 16px 0 9px; }
.post > p { font-size: 13px; color: var(--muted); line-height: 1.8; margin: 0 0 20px; overflow-wrap: anywhere; }
.post footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 11px; color: var(--muted); }
.post-author { display: flex; align-items: center; gap: 8px; }
.mini-avatar { height: 25px; width: 25px; display: grid; place-items: center; border-radius: 50%; font-size: 10px; flex-shrink: 0; }
.post footer button { font-size: 12px; color: var(--muted); margin-left: 8px; display: inline-flex; align-items: center; gap: 4px; }
.post footer .liked { color: var(--primary); }
.community-note { height: max-content; border: 1px solid #cfe0fa; background: var(--primary-soft); border-radius: 15px; padding: 22px; }
.community-note > svg { color: var(--primary); }
.community-note h3 { font-size: 15px; margin: 13px 0 9px; }
.community-note p { color: var(--muted); font-size: 12px; line-height: 1.8; margin: 0 0 17px; }
.site-footer { border-top: 1px solid var(--border); background: #fff; padding: 22px max(24px, calc((100vw - 1280px) / 2)); display: flex; justify-content: space-between; gap: 24px; color: var(--muted); font-size: 11px; line-height: 1.8; }
.site-footer b { color: var(--primary); font-size: 13px; }
.footer-note { text-align: right; }
.modal-backdrop { z-index: 20; position: fixed; inset: 0; background: #17324d66; display: grid; place-items: center; padding: 20px; backdrop-filter: blur(5px); }
.auth-modal { position: relative; width: min(420px, 100%); max-height: 90vh; overflow: auto; background: #fff; border: 1px solid var(--border); border-radius: 20px; padding: 32px; box-shadow: 0 24px 70px #17324d20; }
.close { position: absolute; right: 14px; top: 12px; color: var(--muted); width: 30px; height: 30px; border-radius: 8px; font-size: 24px; }
.close:hover { background: var(--primary-soft); }
.auth-modal h2 { text-align: center; font-size: 24px; letter-spacing: -.8px; margin: 20px 0 9px; }
.auth-modal > p { text-align: center; font-size: 13px; color: var(--muted); line-height: 1.7; margin: 0 0 24px; }
.auth-modal form { display: grid; gap: 15px; }
.auth-modal label { font-size: 12px; color: var(--text); display: grid; gap: 8px; }
.auth-modal input { height: 44px; border: 1px solid var(--border); border-radius: 9px; background: #f8fbff; color: var(--text); padding: 0 12px; }
.wide { width: 100%; margin-top: 4px; }
.text-link, .switcher button { color: var(--primary); font-size: 12px; }
.text-link { display: block; margin: 17px auto; }
.switcher { margin: 16px 0 0 !important; }
.prototype-note { display: block; text-align: center; margin-top: 20px; font-size: 10px; color: var(--muted); line-height: 1.6; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 50; max-width: calc(100% - 32px); width: max-content; padding: 14px 20px; border: 1px solid #c5d8f4; border-radius: 12px; background: #fff; color: var(--primary-dark); font-size: 13px; box-shadow: 0 8px 30px #17324d20; text-align: center; }
.status { font-size: 11px; color: var(--primary); display: inline-flex; align-items: center; gap: 7px; border: 1px solid #cfe0fa; padding: 7px 11px; border-radius: 100px; background: var(--primary-soft); }
.status i { height: 6px; width: 6px; background: var(--primary); border-radius: 50%; box-shadow: 0 0 0 3px #2563eb12; }
.health-checkin-page { min-height: calc(100vh - 155px); padding: 46px 24px 64px; }
.health-checkin { width: min(680px, 100%); margin: 0 auto; }
.checkin-heading { text-align: center; margin-bottom: 28px; }
.checkin-heading h1 { font-size: clamp(32px, 4vw, 44px); letter-spacing: -1.7px; line-height: 1.1; margin: 18px 0 12px; }
.checkin-heading p { color: var(--muted); line-height: 1.75; font-size: 14px; margin: 0; }
.checkin-form { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 28px; box-shadow: 0 8px 35px #17324d04; }
.form-group { display: block; margin: 0 0 24px; }
.field-title { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 11px; }
.field-title span { font-size: 11px; font-weight: 400; color: var(--muted); margin-left: 5px; }
.image-dropzone { height: 174px; border: 1px dashed #abc7ee; border-radius: 13px; background: #f5f9ff; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 8px; color: var(--muted); transition: .2s; position: relative; overflow: hidden; cursor: pointer; }
.image-dropzone:hover, .image-dropzone.dragging { border-color: var(--primary); background: #edf4ff; }
.image-dropzone .upload-symbol { height: 36px; width: 36px; border-radius: 11px; display: grid; place-items: center; color: var(--primary); background: #dfebff; font-size: 22px; }
.image-dropzone strong { font-size: 13px; color: var(--text); margin-top: 3px; }
.image-dropzone span, .upload-note { font-size: 11px; color: var(--muted); }
.image-dropzone.has-image { cursor: default; border-style: solid; }
.image-dropzone img { height: 100%; width: 100%; object-fit: contain; }
.remove-image { position: absolute; right: 10px; top: 10px; width: 30px; height: 30px; border-radius: 50%; background: #fff; color: var(--text); border: 1px solid var(--border); font-size: 20px; }
.image-actions { display: flex; gap: 10px; margin-top: 11px; }
.image-actions .outline-btn { flex: 1; }
.upload-note { margin: 9px 0 0; }
.text-field textarea, .note-label textarea { width: 100%; min-height: 88px; resize: vertical; border: 1px solid var(--border); border-radius: 10px; background: #fbfdff; color: var(--text); padding: 12px; font-size: 13px; line-height: 1.7; }
.text-field textarea:focus { border-color: #93b8f9; }
.start-checkin { width: 100%; min-height: 46px; font-size: 14px; }
.checkin-disclaimer, .disclaimer { font-size: 10px; color: var(--muted); text-align: center; margin: 14px 0 0; line-height: 1.7; }
.checkin-result { padding: 20px; margin-top: 20px; border-radius: 12px; background: var(--primary-soft); border: 1px solid #cfe0fa; }
.checkin-result h2 { font-size: 17px; margin: 0 0 8px; }
.checkin-result p { font-size: 13px; line-height: 1.75; color: var(--muted); margin: 0 0 16px; }
.journal-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 18px; margin-top: 30px; }
.field-label { font-size: 13px; color: var(--muted); margin: 26px 0 12px; }
.moods { display: flex; justify-content: space-between; gap: 7px; }
.moods button { border: 1px solid transparent; border-radius: 10px; flex: 1; padding: 12px 4px; color: var(--muted); font-size: 11px; }
.moods button span { font-size: 23px; display: block; margin-bottom: 6px; }
.moods .chosen { background: var(--primary-soft); border-color: #a9c7fb; color: var(--primary); }
.sliders { margin: 24px 0; display: grid; gap: 16px; }
.sliders label { font-size: 12px; display: grid; grid-template-columns: 75px 1fr 60px; gap: 9px; align-items: center; color: var(--muted); }
.sliders span { font-size: 11px; color: var(--primary); text-align: right; }
.sliders input, .settings input { accent-color: var(--primary); }
.note-label { display: block; font-size: 12px; color: var(--muted); }
.note-label textarea { margin-top: 9px; }
.checkin .mint-btn { margin-top: 14px; }
.chart { height: 200px; margin-top: 30px; position: relative; border-bottom: 1px solid var(--border); background: repeating-linear-gradient(0deg, transparent 0 47px, #edf2f8 48px); }
.line { position: absolute; left: 5%; width: 90%; top: 48%; height: 2px; background: var(--primary); transform: rotate(-5deg); }
.dots-chart { display: flex; justify-content: space-between; position: absolute; left: 5%; right: 5%; top: calc(48% - 5px); }
.dots-chart i { height: 10px; width: 10px; border-radius: 50%; background: var(--primary); border: 2px solid #fff; }
.days { display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; margin-top: 10px; }
.empty-mini { font-size: 11px; color: var(--muted); line-height: 1.7; margin-top: 25px; }
.auth-gate { text-align: center; display: flex; min-height: calc(100vh - 157px); padding: 36px 24px; align-items: center; justify-content: center; flex-direction: column; }
.auth-gate h1 { font-size: 30px; letter-spacing: -1px; margin: 22px 0 12px; }
.auth-gate p { max-width: 460px; color: var(--muted); font-size: 14px; line-height: 1.8; margin: 0 0 24px; }
.gate-icon { height: 64px; width: 64px; border: 1px solid #cfe0fa; background: var(--primary-soft); color: var(--primary); border-radius: 20px; display: grid; place-items: center; font-size: 23px; }
.profile-top { display: flex; align-items: center; gap: 18px; padding-bottom: 28px; border-bottom: 1px solid var(--border); }
.profile-avatar { width: 60px; height: 60px; border-radius: 20px; display: grid; place-items: center; font-size: 18px; }
.profile-top h1 { font-size: 28px; letter-spacing: -.8px; margin: 7px 0; }
.profile-top p { font-size: 13px; color: var(--muted); margin: 0; }
.profile-top .outline-btn { margin-left: auto; }
.settings { max-width: 720px; margin-top: 28px; }
.settings section { margin-bottom: 26px; }
.settings h2 { font-size: 13px; color: var(--primary); margin: 0 0 10px; }
.settings section > button { width: 100%; border-bottom: 1px solid var(--border); padding: 17px 4px; display: flex; justify-content: space-between; font-size: 13px; text-align: left; }
.settings section > button b { font-size: 12px; font-weight: 500; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.settings .danger h2, .danger b { color: #b94357; }
