:root {
  --forest: #173f36;
  --forest-2: #245a4d;
  --mint: #dceae2;
  --mint-soft: #edf4ef;
  --coral: #e76f51;
  --coral-soft: #fbe8e1;
  --ink: #17201d;
  --muted: #6e7773;
  --line: #e4e7e2;
  --cream: #f8f7f2;
  --white: #fff;
  --shadow: 0 22px 60px rgba(35, 53, 46, .12);
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--cream); color: var(--ink); font-family: "DM Sans", sans-serif; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 245px 1fr; }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 35px 24px 24px; background: #f0f1eb; border-right: 1px solid #e1e3dc; display: flex; flex-direction: column; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--forest); font-size: 23px; font-weight: 700; text-decoration: none; letter-spacing: -.7px; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; background: var(--forest); color: white; border-radius: 11px; transform: rotate(-5deg); }
.brand-mark svg { width: 19px; }
.side-nav { margin-top: 62px; display: grid; gap: 8px; }
.nav-item { width: 100%; border: 0; background: transparent; border-radius: 11px; color: #65706b; display: flex; align-items: center; gap: 14px; padding: 12px 14px; text-align: left; transition: .2s ease; }
.nav-item svg { width: 19px; }
.nav-item:hover { background: rgba(23,63,54,.06); color: var(--forest); }
.nav-item.active { background: var(--forest); color: white; box-shadow: 0 8px 16px rgba(23,63,54,.16); }
.sidebar-bottom { margin-top: auto; display: grid; gap: 12px; }
.streak-card { display: flex; align-items: center; gap: 10px; padding: 13px; background: #fff7e7; border: 1px solid #f3e8cc; border-radius: 13px; }
.streak-icon { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #ffe9bd; color: #d57935; }
.streak-icon svg { width: 17px; fill: currentColor; }
.streak-card strong, .streak-card span { display: block; }
.streak-card strong { font-size: 12px; }
.streak-card span { font-size: 10px; color: #98765d; margin-top: 2px; }
.profile-row { padding: 15px 0 0; border: 0; border-top: 1px solid #dfe1dc; background: none; display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; text-align: left; }
.avatar { width: 35px; height: 35px; display: grid; place-items: center; color: white; background: #d48a6b; border-radius: 50%; font-size: 11px; font-weight: 700; }
.avatar.small { width: 33px; height: 33px; }
.profile-row strong, .profile-row small { display: block; }
.profile-row strong { font-size: 11px; }.profile-row small { font-size: 10px; color: var(--muted); margin-top: 2px; }.profile-row svg { width: 15px; color: #a2aaa5; }

.main-content { width: min(1180px, calc(100vw - 245px)); margin: 0 auto; padding: 48px 54px 70px; }
.mobile-header, .mobile-nav { display: none; }
.page-header { display: flex; justify-content: space-between; align-items: center; gap: 30px; }
.eyebrow, .card-kicker { margin: 0 0 8px; color: var(--coral); font-size: 10px; font-weight: 700; letter-spacing: 1.5px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-family: "Newsreader", serif; font-size: clamp(36px, 4vw, 49px); font-weight: 500; letter-spacing: -1.6px; margin-bottom: 2px; line-height: 1.1; }
.subhead { color: var(--muted); font-size: 14px; margin: 0; }
.header-actions { display: flex; gap: 10px; align-items: center; }
.icon-button { width: 43px; height: 43px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 11px; background: white; color: var(--forest); position: relative; }
.icon-button svg { width: 18px; }
.notification-dot { position: absolute; width: 6px; height: 6px; right: 9px; top: 8px; border-radius: 50%; background: var(--coral); border: 1px solid white; }
.primary-button, .secondary-button { min-height: 43px; border-radius: 11px; padding: 0 17px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; font-weight: 600; font-size: 13px; }
.primary-button { background: var(--forest); color: white; box-shadow: 0 8px 17px rgba(23,63,54,.14); }.primary-button:hover { background: #0f332b; }.primary-button svg { width: 17px; }
.secondary-button { background: white; color: var(--ink); border: 1px solid var(--line); }

.week-strip { margin: 34px 0 38px; padding: 0 12px; height: 78px; background: white; border: 1px solid var(--line); border-radius: 15px; display: grid; grid-template-columns: repeat(7, 1fr); align-items: center; box-shadow: 0 6px 30px rgba(40,55,50,.035); }
.day-button { align-self: stretch; border: 0; background: none; color: #8a918d; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 7px; position: relative; }
.day-button span:first-child { font-size: 9px; font-weight: 700; letter-spacing: 1px; }
.day-button strong { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; font-size: 13px; color: #4e5954; }
.day-button.has-dose::after { content: ""; position: absolute; bottom: 7px; width: 3px; height: 3px; border-radius: 50%; background: #9bb2a9; }
.day-button.active { color: var(--forest); }.day-button.active strong { background: var(--forest); color: white; }.day-button.active::after { background: var(--coral); }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.48fr) minmax(285px, .82fr); gap: 42px; }
.section-title-row { display: flex; align-items: end; justify-content: space-between; margin-bottom: 27px; }
.section-title-row h2 { font-family: "Newsreader", serif; font-size: 25px; font-weight: 600; margin: 0 0 4px; }.section-title-row span { color: var(--muted); font-size: 11px; }
.text-button { border: 0; background: none; color: var(--forest); padding: 0; display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; }.text-button svg { width: 13px; }
.timeline { position: relative; display: grid; gap: 13px; }
.timeline::before { content: ""; position: absolute; left: 76px; top: 17px; bottom: 20px; width: 1px; background: #dfe4e0; }
.dose-row { display: grid; grid-template-columns: 59px 18px 1fr; gap: 9px; align-items: center; position: relative; }
.dose-time { font-size: 10px; color: #818985; text-align: right; }.dose-time strong { display: block; font-size: 12px; color: #545e59; }.dose-time span { font-size: 8px; }
.timeline-dot { width: 9px; height: 9px; border: 2px solid var(--cream); outline: 1px solid #cbd3cf; border-radius: 50%; background: #c6d0cb; z-index: 1; justify-self: center; }
.dose-row.taken .timeline-dot { background: var(--forest); outline-color: var(--forest); }.dose-row.due .timeline-dot { background: var(--coral); outline-color: var(--coral); box-shadow: 0 0 0 4px var(--coral-soft); }
.dose-card { min-height: 75px; background: white; border: 1px solid var(--line); border-radius: 13px; padding: 12px 15px; display: flex; align-items: center; gap: 13px; transition: .2s ease; }
.dose-row.due .dose-card { border-color: #efc2b5; box-shadow: 0 7px 20px rgba(195,96,69,.07); }
.pill-icon { flex: 0 0 auto; width: 38px; height: 38px; display: grid; place-items: center; background: var(--mint-soft); color: var(--forest); border-radius: 10px; }.pill-icon svg { width: 18px; }.dose-row.due .pill-icon { color: var(--coral); background: var(--coral-soft); }
.dose-info { min-width: 0; flex: 1; }.dose-info h3 { margin: 0 0 3px; font-size: 13px; }.dose-info p { margin: 0; color: var(--muted); font-size: 10px; }.status-pill { white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; font-size: 9px; font-weight: 700; color: #628174; }.status-pill svg { width: 12px; }.status-pill.upcoming { color: #8e9692; }.status-pill.due { color: var(--coral); }
.dose-actions { display: flex; gap: 7px; }.dose-action { border: 1px solid var(--line); background: white; border-radius: 8px; padding: 7px 9px; color: #68716d; font-size: 9px; font-weight: 700; }.dose-action.take { color: white; border-color: var(--forest); background: var(--forest); }

.right-rail { display: grid; align-content: start; gap: 15px; }
.score-card, .insight-card, .quote-card { border-radius: 15px; }
.score-card { padding: 22px; color: white; background: var(--forest); box-shadow: 0 14px 35px rgba(23,63,54,.14); }
.score-card-top { display: flex; justify-content: space-between; gap: 20px; align-items: center; }.score-card .card-kicker { color: #a9c8bb; }.score-card h3 { font-family: "Newsreader", serif; font-size: 21px; margin: 0; }.score-card > p { color: #c4d6cf; font-size: 10px; line-height: 1.6; margin: 17px 0; }
.progress-ring { --progress: 60; width: 62px; height: 62px; flex: 0 0 auto; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(#f4b184 calc(var(--progress) * 1%), rgba(255,255,255,.13) 0); position: relative; }.progress-ring::after { content: ""; position: absolute; inset: 6px; background: var(--forest); border-radius: 50%; }.progress-ring span { position: relative; z-index: 1; font-size: 12px; font-weight: 700; }
.mini-stats { display: grid; grid-template-columns: 1fr 1fr; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.13); gap: 10px; }.mini-stats > div { display: flex; align-items: center; gap: 8px; }.mini-stat-icon { width: 29px; height: 29px; border-radius: 8px; display: grid; place-items: center; }.mini-stat-icon svg { width: 14px; }.mini-stat-icon.flame { background: #365e50; color: #f7a86f; }.mini-stat-icon.check { background: #365e50; color: #a9c8bb; }.mini-stats strong, .mini-stats small { display: block; }.mini-stats strong { font-size: 10px; }.mini-stats small { color: #9eb8ae; font-size: 8px; margin-top: 2px; }
.insight-card { padding: 20px; background: #fff9ed; border: 1px solid #eee4cb; }.insight-heading { display: flex; gap: 10px; }.spark-icon { width: 31px; height: 31px; display: grid; place-items: center; flex: 0 0 auto; color: #b17035; background: #f9e8c8; border-radius: 9px; }.spark-icon svg { width: 15px; }.insight-card .card-kicker { color: #a9794f; margin-bottom: 4px; }.insight-card h3 { font-family: "Newsreader", serif; font-size: 16px; line-height: 1.2; margin: 0; }.insight-card p { color: #7f776c; font-size: 9px; line-height: 1.6; margin: 13px 0; }
.quote-card { position: relative; padding: 17px 19px 17px 46px; background: var(--mint); color: var(--forest); }.quote-card svg { position: absolute; left: 18px; top: 18px; width: 17px; opacity: .65; }.quote-card p { font-family: "Newsreader", serif; font-size: 13px; font-style: italic; line-height: 1.45; margin: 0; }

.modal-backdrop { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; background: rgba(19,31,27,.52); backdrop-filter: blur(7px); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .2s ease, visibility 0s linear .2s; }.modal-backdrop.open { opacity: 1; visibility: visible; pointer-events: auto; transition-delay: 0s; }.modal { width: min(540px, 100%); max-height: calc(100vh - 35px); overflow-y: auto; background: var(--cream); border-radius: 19px; padding: 27px; box-shadow: var(--shadow); transform: translateY(15px) scale(.98); transition: .2s ease; }.modal-backdrop.open .modal { transform: none; }.modal-header { display: flex; justify-content: space-between; align-items: start; margin-bottom: 23px; }.modal-header h2 { font-family: "Newsreader", serif; font-size: 28px; margin: 0; }.modal form { display: grid; gap: 17px; }.modal label, .modal legend { color: #4b5551; font-size: 11px; font-weight: 700; }.modal input[type="text"], .modal input[type="time"], .modal select { width: 100%; height: 45px; margin-top: 7px; padding: 0 13px; border: 1px solid #dfe3de; border-radius: 10px; background: white; color: var(--ink); outline: 0; }.modal input:focus, .modal select:focus { border-color: #6c9988; box-shadow: 0 0 0 3px rgba(63,112,94,.1); }.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }.modal fieldset { padding: 0; border: 0; margin: 0; }.segmented-control { display: grid; grid-template-columns: repeat(3, 1fr); background: #eaede8; border-radius: 10px; padding: 3px; margin-top: 7px; }.segmented-control input { position: absolute; opacity: 0; }.segmented-control span { display: grid; place-items: center; min-height: 36px; border-radius: 8px; font-size: 10px; color: #6a736f; }.segmented-control input:checked + span { color: var(--forest); background: white; box-shadow: 0 2px 8px rgba(30,50,42,.08); }.toggle-row { display: flex; align-items: center; position: relative; gap: 12px; padding: 13px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }.toggle-row > span:first-child { flex: 1; }.toggle-row strong, .toggle-row small { display: block; }.toggle-row small { color: var(--muted); font-weight: 400; margin-top: 4px; }.toggle-row input { position: absolute; opacity: 0; }.toggle { width: 40px; height: 23px; border-radius: 20px; background: #c9cfcb; position: relative; transition: .2s; }.toggle::after { content: ""; position: absolute; width: 17px; height: 17px; top: 3px; left: 3px; border-radius: 50%; background: white; transition: .2s; box-shadow: 0 1px 4px rgba(0,0,0,.15); }.toggle-row input:checked + .toggle { background: var(--forest); }.toggle-row input:checked + .toggle::after { transform: translateX(17px); }.modal-note { display: flex; gap: 10px; padding: 12px; border-radius: 10px; color: #557368; background: var(--mint-soft); font-size: 10px; line-height: 1.5; }.modal-note svg { width: 16px; flex: 0 0 auto; }.modal-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 3px; }
.toast { position: fixed; z-index: 80; right: 25px; bottom: 25px; background: #172d27; color: white; border-radius: 13px; padding: 13px 17px; display: flex; align-items: center; gap: 11px; box-shadow: var(--shadow); transform: translateY(120px); opacity: 0; transition: .3s ease; }.toast.show { transform: none; opacity: 1; }.toast-icon { width: 29px; height: 29px; display: grid; place-items: center; background: #31594d; color: #b9d6c9; border-radius: 50%; }.toast-icon svg { width: 15px; }.toast strong, .toast small { display: block; }.toast strong { font-size: 11px; }.toast small { color: #adc0b8; font-size: 9px; margin-top: 3px; }
.site-footer { grid-column: 2; width: min(1180px, calc(100vw - 245px)); margin: 0 auto; padding: 0 54px 28px; color: var(--muted); font-size: 11px; display: flex; justify-content: space-between; gap: 16px; }.footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 14px; }.site-footer a { color: var(--forest); text-decoration: none; }.site-footer a:hover { text-decoration: underline; }
.legal-body { min-height: 100vh; padding: 42px 20px 72px; }.legal-page { width: min(720px, 100%); margin: 0 auto; }.legal-page .brand { margin-bottom: 58px; }.legal-page h1 { margin-bottom: 10px; }.legal-updated, .legal-lead { color: var(--muted); font-size: 14px; line-height: 1.6; }.legal-lead { font-size: 17px; margin-bottom: 37px; }.legal-page section { margin-top: 31px; }.legal-page h2 { font-family: "Newsreader", serif; font-size: 25px; font-weight: 600; margin-bottom: 9px; }.legal-page p { color: #4f5b55; font-size: 15px; line-height: 1.7; }.legal-page a { color: var(--forest); font-weight: 600; }.legal-page .eyebrow { margin-top: 0; }

@media (max-width: 980px) {
  .app-shell { grid-template-columns: 88px 1fr; }.sidebar { padding: 30px 16px; align-items: center; }.sidebar .brand > span:last-child, .nav-item span, .streak-card, .profile-row span:not(.avatar) { display: none; }.side-nav { width: 100%; }.nav-item { justify-content: center; }.sidebar-bottom { width: 100%; }.profile-row { display: flex; justify-content: center; }.profile-row svg { display: none; }.main-content { width: calc(100vw - 88px); padding: 42px 36px 70px; }.site-footer { grid-column: 2; width: calc(100vw - 88px); padding: 0 36px 28px; }.dashboard-grid { gap: 24px; }
}
@media (max-width: 720px) {
  body { background: #faf9f5; padding-bottom: 76px; }.app-shell { display: block; }.sidebar { display: none; }.main-content { width: 100%; padding: 0 19px 35px; }.site-footer { width: 100%; padding: 0 19px 94px; flex-direction: column; }.footer-links { justify-content: flex-start; }.mobile-header { display: flex; justify-content: space-between; align-items: center; padding: 17px 0 23px; }.mobile-header .icon-button { border: 0; background: transparent; }.page-header { align-items: end; }.page-header h1 { font-size: 37px; }.page-header .subhead { font-size: 13px; }.header-actions .icon-button { display: none; }.header-actions .primary-button { width: 43px; padding: 0; font-size: 0; }.header-actions .primary-button svg { width: 20px; }.week-strip { margin: 25px -4px 29px; height: 72px; padding: 0 3px; }.day-button strong { width: 30px; height: 30px; }.dashboard-grid { display: block; }.section-title-row { margin-bottom: 21px; }.timeline::before { left: 53px; }.dose-row { grid-template-columns: 38px 14px 1fr; gap: 8px; }.dose-time strong { font-size: 10px; }.dose-time span { display: none; }.dose-card { padding: 11px; }.status-pill { display: none; }.pill-icon { width: 34px; height: 34px; }.right-rail { margin-top: 31px; grid-template-columns: 1fr; }.score-card { padding: 21px; }.insight-card, .quote-card { display: none; }.mobile-nav { position: fixed; display: grid; grid-template-columns: repeat(5, 1fr); left: 0; right: 0; bottom: 0; z-index: 30; height: 68px; padding: 8px 8px max(8px, env(safe-area-inset-bottom)); background: rgba(255,255,255,.96); border-top: 1px solid var(--line); backdrop-filter: blur(10px); }.mobile-nav button { border: 0; background: none; color: #909894; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 8px; }.mobile-nav svg { width: 18px; }.mobile-nav button.active { color: var(--forest); }.mobile-nav .mobile-add { width: 45px; height: 45px; margin: -17px auto 0; border-radius: 50%; background: var(--forest); color: white; box-shadow: 0 7px 18px rgba(23,63,54,.25); }.modal-backdrop { align-items: end; padding: 0; }.modal { width: 100%; max-height: 92vh; border-radius: 21px 21px 0 0; padding: 25px 20px 28px; transform: translateY(100%); }.form-row { grid-template-columns: 1fr 1fr; }.toast { left: 17px; right: 17px; bottom: 83px; }
}
@media (max-width: 390px) { .dose-info p { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.dose-actions { display: block; }.dose-action:not(.take) { display: none; } }
