html,
body {
    margin: 0;
    min-height: 100%;
    background: #f5f7f8;
    color: #17211f;
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

.is-hidden {
    display: none !important;
}

a {
    color: #285d7a;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

button,
input,
textarea,
select {
    font: inherit;
}

.login-page {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 440px;
    min-height: 100vh;
    background:
        linear-gradient(115deg, rgba(14, 73, 87, 0.9), rgba(27, 44, 48, 0.82)),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='900' viewBox='0 0 900 900'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.16' stroke-width='2'%3E%3Cpath d='M0 180h150l34-62 58 182 54-110 44 74h164l30-48 42 96 42-132 48 86h234'/%3E%3Cpath d='M0 442h220l44-96 52 172 56-122 48 74h120l34-54 42 104 48-154 44 76h192'/%3E%3Cpath d='M0 704h176l46-84 58 180 56-116 44 72h154l32-48 40 98 46-140 48 86h200'/%3E%3C/g%3E%3C/svg%3E");
    background-size: cover;
}

.login-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    background:
        linear-gradient(115deg, rgba(14, 73, 87, 0.18), rgba(27, 44, 48, 0.08)),
        url("images/active-vitals-auth.png") center / min(88vw, 900px) auto no-repeat;
}

.vitals-card {
    width: min(560px, 100%);
    padding: 28px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.14);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.25);
    color: #ffffff;
    backdrop-filter: blur(16px);
}

.login-visual .vitals-card {
    visibility: hidden;
}

.vitals-card__header,
.dashboard-header,
.form-options,
.brand-row {
    display: flex;
    align-items: center;
}

.vitals-card__header,
.dashboard-header,
.form-options {
    justify-content: space-between;
}

.vitals-card__header span,
.metric-grid span,
.eyebrow {
    color: rgba(255, 255, 255, 0.76);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.vitals-card__header strong {
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(173, 230, 196, 0.24);
    color: #d8f7e3;
    font-size: 0.85rem;
}

.pulse-line {
    height: 130px;
    margin: 34px 0;
    border-radius: 8px;
    background:
        linear-gradient(90deg, transparent 0 8%, #9ee6bd 8% 12%, transparent 12% 18%, #9ee6bd 18% 22%, transparent 22% 30%, #ffffff 30% 32%, transparent 32% 40%, #9ee6bd 40% 44%, transparent 44% 52%, #9ee6bd 52% 56%, transparent 56% 66%, #ffffff 66% 69%, transparent 69%),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.09) 0 1px, transparent 1px 44px),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 32px);
    background-position: center;
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.metric-grid div {
    min-width: 0;
    padding: 14px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.14);
}

.metric-grid strong {
    display: block;
    margin-top: 8px;
    font-size: 1.35rem;
}

.login-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;
    padding: 48px;
    background: #ffffff;
    box-shadow: -18px 0 50px rgba(0, 0, 0, 0.14);
}

.brand-row {
    gap: 16px;
    margin-bottom: 34px;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border-radius: 8px;
    background: #173f4a;
    color: #ffffff;
    font-weight: 800;
}

.eyebrow {
    margin: 0 0 5px;
    color: #5f7270;
}

.brand-home-link {
    display: inline-block;
    margin-bottom: 5px;
    color: inherit;
    text-decoration: none;
}

.brand-home-link .eyebrow {
    margin: 0;
}

.brand-home-link:hover .eyebrow,
.brand-home-link:focus-visible .eyebrow {
    color: #173f4a;
    text-decoration: underline;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 0;
    font-size: 2.15rem;
    line-height: 1.05;
}

.login-form {
    display: grid;
    gap: 18px;
}

.field-group {
    display: grid;
    gap: 7px;
}

.field-group label {
    color: #384846;
    font-size: 0.94rem;
    font-weight: 700;
}

.field-hint {
    margin: -2px 0 0;
    color: #5d6a68;
    font-size: 0.88rem;
}

.form-input {
    width: 100%;
    min-height: 46px;
    border: 1px solid #c9d3d1;
    border-radius: 8px;
    padding: 10px 12px;
    background: #fbfcfc;
    color: #17211f;
}

.form-input:focus {
    border-color: #2d6f7d;
    box-shadow: 0 0 0 3px rgba(45, 111, 125, 0.16);
    outline: none;
}

.checkbox-row {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #384846;
}

.show-password-row {
    margin-top: -4px;
}

.password-action-row {
    display: block;
    margin-top: -4px;
}

.password-action-row .show-password-row {
    margin-top: 0;
}

.recovery-link-row {
    display: flex;
    justify-content: flex-start;
    gap: 18px;
    margin-top: -8px;
    font-weight: 700;
}

.remember-device-row {
    display: grid;
    gap: 6px;
    justify-content: flex-start;
    margin-top: 20px;
}

.remember-device-duration {
    margin-left: 28px;
    color: #5d6a68;
    font-size: 0.95rem;
    font-weight: 700;
}

.login-message {
    border-radius: 8px;
    padding: 11px 12px;
    background: #eaf6ef;
    color: #25553b;
}

.login-message--success-with-icon {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #a7dac0;
    background: #e9f8ef;
    color: #173f2d;
    font-weight: 700;
}

.login-message--error {
    background: #f8dddd;
    color: #8f2329;
}

.primary-button {
    min-height: 48px;
    border: 0;
    border-radius: 8px;
    background: #173f4a;
    color: #ffffff;
    cursor: pointer;
    font-weight: 800;
}

.primary-button:hover {
    background: #215463;
}

.validation-message {
    color: #b11c25;
    font-size: 0.88rem;
}

.form-link {
    justify-self: center;
    font-weight: 800;
}

.account-panel {
    justify-content: flex-start;
    overflow-y: auto;
}

.account-form {
    gap: 16px;
}

.account-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.form-grid-span-all {
    grid-column: 1 / -1;
}

.gender-options {
    display: flex;
    align-items: center;
    gap: 18px;
    margin: 0;
    border: 0;
    padding: 0;
}

.gender-options legend {
    margin-right: 4px;
    color: #384846;
    font-size: 0.94rem;
    font-weight: 700;
}

.gender-options label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #384846;
    font-weight: 700;
}

.height-picker {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
}

.dashboard-shell {
    display: grid;
    grid-template-columns: 244px minmax(0, 1fr);
    min-height: 100vh;
    background: #eef3f2;
}

.dashboard-rail {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    height: 100vh;
    padding: 22px 16px;
    overflow-y: auto;
    scrollbar-gutter: stable;
    border-right: 1px solid #d7e1df;
    background: #ffffff;
}

.rail-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 6px 24px;
    color: #173f4a;
    font-weight: 800;
}

.brand-mark--compact {
    width: 38px;
    height: 38px;
    font-size: 0.82rem;
}

.rail-nav {
    display: grid;
    gap: 4px;
}

.rail-subnav {
    display: grid;
    gap: 2px;
    margin: -2px 0 4px 12px;
    border-left: 2px solid #d7e1df;
    padding-left: 10px;
}

.rail-subnav-button {
    min-height: 32px;
    border: 0;
    border-radius: 8px;
    padding: 7px 9px;
    background: transparent;
    color: #53635f;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 700;
    text-align: left;
}

.rail-subnav-button:hover,
.rail-subnav-button.is-active {
    background: #f0f6f4;
    color: #173f4a;
}

.rail-subnav a.rail-subnav-button {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.rail-subpanel {
    display: grid;
    gap: 8px;
    margin: 4px 0 14px 28px;
    color: #173f4a;
}

.rail-subpanel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 154px;
    border: 0;
    padding: 0;
    background: transparent;
    max-width: 154px;
    color: #175a87;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 800;
    text-align: left;
}

.rail-subpanel-heading:hover {
    color: #0d3f63;
}

.rail-subpanel label {
    display: flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    cursor: pointer;
    color: #142427;
    font-size: 0.9rem;
    font-weight: 500;
}

.rail-range-option.is-disabled {
    cursor: not-allowed;
    color: #8a9693;
}

.rail-range-option.is-disabled input {
    cursor: not-allowed;
}

.rail-subpanel input[type="radio"] {
    width: 18px;
    height: 18px;
    margin: 0;
}

.rail-nav a,
.rail-nav-toggle,
.rail-signout,
.rail-profile {
    border-radius: 8px;
    padding: 11px 12px;
    color: #43514f;
    font: inherit;
    font-weight: 700;
}

.rail-nav a:hover,
.rail-nav a.is-active,
.rail-nav-toggle:hover,
.rail-nav-toggle.is-active,
.rail-profile:hover,
.rail-profile.is-active {
    background: #e8f2f0;
    color: #173f4a;
    text-decoration: none;
}

.rail-nav-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    border: 0;
    background: transparent;
    cursor: pointer;
    text-align: left;
}

.rail-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: auto;
}

.profile-icon {
    position: relative;
    display: inline-block;
    width: 26px;
    height: 28px;
}

.profile-icon::before,
.profile-icon::after {
    position: absolute;
    left: 50%;
    content: "";
    transform: translateX(-50%);
}

.profile-icon::before {
    top: 1px;
    width: 12px;
    height: 12px;
    border: 3px solid currentColor;
    border-radius: 50%;
}

.profile-icon::after {
    bottom: 0;
    width: 22px;
    height: 14px;
    border: 3px solid currentColor;
    border-bottom: 0;
    border-radius: 16px 16px 0 0;
}

.rail-signout {
    display: block;
    margin-top: 10px;
    border: 1px solid #d7e1df;
    background: #ffffff;
    cursor: pointer;
    text-align: left;
    text-decoration: none;
}

.rail-signout:hover {
    background: #f6f9f8;
    color: #173f4a;
    text-decoration: none;
}

.dashboard-main {
    min-width: 0;
    padding: 28px;
}

.demo-login-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-top: 1px solid #d7e1df;
    padding-top: 16px;
}

.demo-login-panel div {
    min-width: 0;
}

.demo-login-panel strong,
.demo-login-panel span {
    display: block;
}

.demo-login-panel span {
    margin-top: 3px;
    overflow-wrap: anywhere;
    color: #5d6a68;
    font-size: 0.9rem;
}

.demo-mode-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
    border: 1px solid #d4ad50;
    border-radius: 8px;
    padding: 10px 14px;
    background: #fff8e8;
    color: #594515;
}

.demo-mode-banner strong {
    color: #173f4a;
}

.demo-mode-banner span {
    font-weight: 700;
}

.dashboard-shell.demo-mode .primary-action,
.dashboard-shell.demo-mode .danger-action,
.dashboard-shell.demo-mode button[type="submit"] {
    cursor: not-allowed;
    opacity: 0.52;
    pointer-events: none;
}

.dashboard-topbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.dashboard-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.person-switcher {
    min-width: 148px;
    border: 1px solid #d5dfdd;
    border-radius: 8px;
    padding: 8px 12px;
    background: #ffffff;
}

.person-switcher span,
.card-heading > span,
.card-heading div > span,
.progress-stack span {
    display: block;
    color: #63706e;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
}

.person-switcher strong {
    display: block;
    color: #17211f;
}

.secondary-link,
.primary-action {
    min-height: 42px;
    border-radius: 8px;
    padding: 10px 14px;
    cursor: pointer;
    font-weight: 800;
}

.secondary-link {
    border: 1px solid #bfd0ce;
    background: #ffffff;
    color: #173f4a;
}

.primary-action {
    border: 0;
    background: #173f4a;
    color: #ffffff;
}

.status-band {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
    border: 1px solid #cfe0dc;
    border-radius: 8px;
    padding: 16px 18px;
    background: #dff1e8;
}

.status-band--ok {
    background: #dff1e8;
}

.status-band--watch {
    border-color: #ead9ad;
    background: #fff4d8;
}

.status-band--high {
    border-color: #e3b5b7;
    background: #f8dddd;
}

.status-band > div:first-child {
    display: grid;
    grid-template-columns: auto auto;
    column-gap: 10px;
    align-items: center;
}

.bmi-status-heading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.bmi-help-button {
    width: 24px;
    height: 24px;
    border-color: transparent;
    background: transparent;
    color: #184652;
    font-size: 0.9rem;
}

.status-band p {
    grid-column: 2;
    margin: 2px 0 0;
    color: #4f625d;
}

.status-band > div:last-child {
    text-align: right;
}

.status-band > div:last-child span {
    display: block;
    color: #5c6a66;
    font-size: 0.82rem;
    font-weight: 700;
}

.renal-fluid-notice {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 14px;
    margin-bottom: 18px;
    border: 1px solid #e2bd75;
    border-left: 5px solid #b87313;
    border-radius: 8px;
    padding: 16px 18px;
    background: #fff8e8;
    color: #392f1d;
}

.renal-fluid-notice-icon {
    width: 1.5rem;
    height: 1.5rem;
    margin-top: 1px;
    fill: #8a570d;
}

.renal-fluid-notice h2 {
    margin: 0;
    font-size: 1rem;
}

.renal-fluid-notice p {
    margin: 6px 0 0;
    max-width: 1080px;
    line-height: 1.45;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #2f8a56;
}

.metric-card-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 14px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
    gap: 14px;
}

.dashboard-card {
    min-width: 0;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(34, 56, 55, 0.06);
}

.metric-card {
    padding: 18px;
}

.card-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.card-heading h2 {
    margin: 4px 0 0;
    font-size: 1.12rem;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    border-radius: 999px;
    padding: 4px 9px;
    font-size: 0.78rem;
    white-space: nowrap;
}

.status-ok {
    background: #e1f4e8;
    color: #23623f;
}

.status-info {
    background: #e5f0f5;
    color: #285d7a;
}

.status-watch {
    background: #fff1d8;
    color: #80611d;
}

.metric-value {
    margin: 20px 0 8px;
    color: #17211f;
    font-size: 2.18rem;
    font-weight: 850;
    line-height: 1;
}

.metric-value span {
    color: #64716e;
    font-size: 0.94rem;
    font-weight: 700;
}

.metric-card p {
    margin: 0;
    color: #5d6a68;
}

.trend-panel,
.attention-panel,
.nutrition-panel,
.nutrition-trend-panel,
.fluid-summary-panel,
.activity-panel,
.weight-sparkline-panel,
.exercise-trend-panel,
.exercise-month-panel {
    padding: 20px;
}

.bar-chart {
    display: grid;
    grid-template-columns: repeat(7, minmax(42px, 1fr));
    gap: 12px;
    height: 260px;
    margin-top: 22px;
}

.bar-column {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 8px;
    min-width: 0;
    text-align: center;
}

.bar-value,
.bar-label {
    color: #60706d;
    font-size: 0.82rem;
    font-weight: 700;
}

.bar-track {
    position: relative;
    align-self: stretch;
    border-radius: 8px;
    background: #eef4f2;
    overflow: hidden;
}

.bar-fill {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    border-radius: 8px 8px 0 0;
    background: linear-gradient(180deg, #6bbf93, #2f756e);
}

.attention-list,
.activity-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.attention-row,
.activity-row {
    display: grid;
    gap: 12px;
    border-top: 1px solid #edf2f1;
    padding-top: 12px;
}

.attention-row {
    grid-template-columns: auto minmax(0, 1fr);
}

.attention-row p,
.activity-row p {
    margin: 3px 0 0;
    color: #64716e;
}

.attention-marker {
    width: 10px;
    height: 10px;
    margin-top: 6px;
    border-radius: 50%;
}

.marker-watch {
    background: #d39b2d;
}

.marker-info {
    background: #4288a4;
}

.nutrition-panel {
    grid-column: 1;
}

.nutrition-trend-grid {
    display: grid;
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.nutrition-trend-panel {
    padding: 20px;
}

.nutrition-trend-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 16px;
    margin-top: 18px;
    color: #5d6a68;
    font-size: 0.82rem;
    font-weight: 700;
}

.nutrition-trend-legend span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.nutrition-trend-legend i {
    width: 16px;
    height: 4px;
    border-radius: 999px;
}

.nutrition-daily-key {
    background: #23776e;
}

.nutrition-goal-key {
    border-top: 2px dashed #a26a16;
}

.nutrition-average-key {
    background: #6f55aa;
}

.nutrition-percent-chart {
    position: relative;
    margin-top: 12px;
    padding-left: 34px;
}

.nutrition-percent-chart svg {
    width: 100%;
    height: 210px;
    border-radius: 8px;
    background: linear-gradient(180deg, #f8fbfa 0%, #eef5f3 100%);
}

.nutrition-percent-chart polyline {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

.nutrition-daily-line {
    stroke: #23776e;
    stroke-width: 2.2;
}

.nutrition-average-line {
    stroke: #6f55aa;
    stroke-width: 2;
}

.nutrition-goal-line {
    stroke: #a26a16;
    stroke-width: 1.5;
    stroke-dasharray: 5 4;
    vector-effect: non-scaling-stroke;
}

.nutrition-point {
    fill: #23776e;
    stroke: #ffffff;
    stroke-width: 0.8;
    vector-effect: non-scaling-stroke;
}

.nutrition-point--partial {
    fill: #ffffff;
    stroke: #d28722;
    stroke-width: 1.5;
}

.nutrition-axis-top,
.nutrition-axis-goal {
    position: absolute;
    left: 0;
    color: #71807d;
    font-size: 0.72rem;
    font-weight: 750;
}

.nutrition-axis-top {
    top: 0;
}

.nutrition-axis-goal {
    top: 34%;
    color: #8b641f;
}

.nutrition-trend-labels {
    display: grid;
    gap: 2px;
    margin-top: 7px;
}

.nutrition-trend-labels span,
.nutrition-trend-labels strong,
.nutrition-trend-labels small,
.nutrition-trend-labels em {
    display: block;
    min-width: 0;
    text-align: center;
}

.nutrition-trend-labels strong {
    color: #22302d;
    font-size: 0.7rem;
}

.nutrition-trend-labels small {
    color: #71807d;
    font-size: 0.62rem;
}

.nutrition-trend-labels em {
    margin-top: 2px;
    color: #9a681a;
    font-size: 0.58rem;
    font-style: normal;
    font-weight: 750;
}

.nutrition-trend-labels .is-missing strong {
    color: #97a29f;
}

.nutrition-trend-summary {
    margin: 16px 0 0;
    color: #1f302d;
    font-weight: 850;
}

.nutrition-trend-note {
    margin: 6px 0 0;
    color: #66736f;
    font-size: 0.82rem;
    line-height: 1.45;
}

.fluid-summary-panel {
    grid-column: 1;
}

.fluid-heading-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.fluid-droplet-icon {
    width: 0.9rem;
    height: 0.9rem;
    color: #000;
    fill: currentColor;
    flex: 0 0 auto;
}

.fluid-summary-content {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-top: 12px;
}

.fluid-summary-main {
    flex: 1;
    min-width: 0;
}

.fluid-total-value {
    margin-top: 8px;
}

.metric-value .fluid-us-conversion {
    margin-left: 0.25rem;
    white-space: nowrap;
}

.fluid-summary-content p {
    margin: 0;
    color: #5d6a68;
}

.fluid-progress-summary {
    max-width: 520px;
    margin-top: 18px;
}

.fluid-progress-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 8px;
    color: #293936;
    font-size: 0.88rem;
}

.fluid-progress-heading span {
    font-weight: 800;
}

.fluid-progress-track {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: #dfe9e6;
}

.fluid-progress-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #184652;
}

.fluid-summary-content .fluid-target-missing {
    margin-top: 14px;
    font-size: 0.88rem;
}

.fluid-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 18px;
}

.fluid-stat-grid > div {
    border: 1px solid #dce6e3;
    border-radius: 8px;
    padding: 11px 12px;
    background: #f7faf9;
}

.fluid-stat-grid span,
.fluid-stat-grid strong {
    display: block;
}

.fluid-stat-grid span {
    color: #62706d;
    font-size: 0.76rem;
    font-weight: 750;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.fluid-stat-grid strong {
    margin-top: 4px;
    color: #17211f;
    font-size: 0.94rem;
}

.fluid-summary-empty {
    padding-bottom: 4px;
}

.activity-panel {
    grid-column: 2;
    grid-row: span 2;
}

.weight-sparkline-panel,
.exercise-trend-panel,
.exercise-month-panel {
    grid-column: 1 / -1;
}

.weight-sparkline-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 14px;
}

.weight-sparkline-heading p {
    margin: 5px 0 0;
    color: #5d6a68;
    font-size: 0.86rem;
}

.weight-sparkline-latest {
    display: flex;
    align-items: baseline;
    gap: 14px;
    color: #17211f;
    font-size: 2rem;
    font-weight: 850;
}

.weight-sparkline-latest .weight-sparkline-change {
    font-size: 0.92rem;
}

.weight-sparkline-chart {
    margin-top: 16px;
}

.weight-sparkline-chart svg {
    width: 100%;
    height: 170px;
    border-radius: 8px;
    background: linear-gradient(180deg, #f8fbfa 0%, #f2f7f6 100%);
}

.weight-sparkline-area {
    fill: rgba(30, 113, 211, 0.09);
}

.weight-sparkline-line {
    fill: none;
    stroke: #1e71d3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.2;
    vector-effect: non-scaling-stroke;
}

.weight-sparkline-chart circle {
    fill: #1e71d3;
    stroke: #ffffff;
    stroke-width: 0.7;
    vector-effect: non-scaling-stroke;
}

.weight-sparkline-labels {
    display: grid;
    gap: 8px;
    margin-top: 7px;
}

.weight-sparkline-labels span,
.weight-sparkline-labels strong,
.weight-sparkline-labels small {
    display: block;
    text-align: center;
}

.weight-sparkline-labels strong {
    color: #263633;
    font-size: 0.78rem;
}

.weight-sparkline-labels small {
    margin-top: 2px;
    color: #6b7775;
    font-size: 0.72rem;
}

.weight-sparkline-stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-top: 18px;
    border: 1px solid #dce6e3;
    border-radius: 8px;
    background: #f7faf9;
}

.weight-sparkline-stats > div {
    padding: 12px 14px;
    text-align: center;
}

.weight-sparkline-stats > div + div {
    border-left: 1px solid #dce6e3;
}

.weight-sparkline-stats span,
.weight-sparkline-stats strong {
    display: block;
}

.weight-sparkline-stats span {
    color: #62706d;
    font-size: 0.72rem;
    font-weight: 750;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.weight-sparkline-stats strong {
    margin-top: 5px;
    color: #17211f;
    font-size: 0.9rem;
}

.weight-sparkline-change--down {
    color: #18865a !important;
}

.weight-sparkline-change--up {
    color: #a36b08 !important;
}

.progress-stack {
    display: grid;
    gap: 16px;
    margin-top: 18px;
}

.progress-stack > div:not(.progress-track) {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.progress-track {
    height: 14px;
    border-radius: 999px;
    background: #edf3f1;
    overflow: hidden;
}

.progress-fill {
    display: block;
    width: 74%;
    height: 100%;
    border-radius: inherit;
    background: #2f756e;
}

.nutrition-target-caption {
    margin: 14px 0 12px;
    color: #5d6a68;
}

.nutrition-target-table {
    display: grid;
    overflow: hidden;
    border: 1px solid #d7e1df;
    border-radius: 8px;
}

.nutrition-target-row {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) repeat(3, minmax(120px, 0.9fr));
    border-top: 1px solid #e4ecea;
}

.nutrition-target-row:first-child {
    border-top: 0;
}

.nutrition-target-row > span,
.nutrition-target-row > strong {
    padding: 10px 12px;
    text-align: left;
}

.nutrition-target-head {
    background: #f1f6f4;
    color: #384846;
    font-size: 0.86rem;
    font-weight: 850;
    text-transform: uppercase;
}

.remaining-positive {
    color: #287b42;
}

.remaining-negative {
    color: #b3262e;
}

.activity-row {
    grid-template-columns: 82px minmax(0, 1fr);
}

.activity-row time {
    color: #64716e;
    font-size: 0.86rem;
    font-weight: 700;
}

.page-message {
    margin-bottom: 16px;
    border: 1px solid #cfe0dc;
    border-radius: 8px;
    padding: 11px 12px;
    background: #e7f5ed;
    color: #25553b;
    font-weight: 700;
}

.page-message--error {
    border-color: #e3b5b7;
    background: #f8dddd;
    color: #8f2329;
}

.entry-grid {
    display: grid;
    grid-template-columns: minmax(360px, 0.42fr) minmax(0, 0.58fr);
    gap: 14px;
}

.entry-panel,
.history-panel {
    padding: 20px;
}

.bp-form {
    display: grid;
    gap: 16px;
    margin-top: 18px;
}

.form-row {
    display: grid;
    gap: 7px;
}

.form-row label {
    color: #384846;
    font-size: 0.94rem;
    font-weight: 700;
}

.field-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.bp-number-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    align-items: start;
}

.glucose-number-grid {
    display: grid;
    grid-template-columns: minmax(180px, 0.45fr);
}

.fluid-amount-grid {
    display: grid;
    grid-template-columns: minmax(140px, 180px) minmax(100px, 130px);
    gap: 12px;
    align-items: start;
}

.fluid-conversion-preview {
    margin-top: -6px;
}

.fluid-normalized-amount {
    display: block;
    margin-top: 2px;
    color: #5d6a68;
    font-size: 0.78rem;
}

.weight-number-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px;
    gap: 12px;
}

.exercise-number-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    align-items: start;
}

.nutrition-entry-grid {
    grid-template-columns: minmax(420px, 0.45fr) minmax(0, 0.55fr);
}

.nutrition-section-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
}

.nutrition-overview-panel {
    padding: 20px;
}

.nutrition-total-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.nutrition-total-grid > div {
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 14px;
    background: #f8fbfa;
}

.nutrition-total-grid span {
    display: block;
    color: #5d6a68;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
}

.nutrition-total-grid strong {
    display: block;
    margin-top: 8px;
    font-size: 1.35rem;
}

.nutrition-section-actions {
    margin-top: 18px;
}

.helper-text {
    margin: 2px 0 0;
    color: #5d6a68;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.45;
}

.nutrition-inline-message {
    margin: 0;
}

.exercise-inline-message {
    margin: 0;
}

.food-lookup-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: end;
}

.estimate-action {
    min-height: 46px;
}

.estimate-action:disabled {
    border-color: #d7e0df;
    background: #f3f6f5;
    color: #8a9997;
    cursor: not-allowed;
    opacity: 0.75;
}

.estimate-guidance {
    display: grid;
    gap: 4px;
    border: 1px solid #c9dbd8;
    border-radius: 10px;
    padding: 14px 16px;
    background: #f3f8f7;
    color: #304542;
}

.estimate-guidance strong {
    color: #173f4a;
}

.estimate-guidance span {
    color: #5d6a68;
    font-size: 0.9rem;
}

.estimate-guidance p {
    margin: 8px 0 0;
    white-space: pre-line;
}

.nutrition-number-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.nutrition-notes-input {
    min-height: 96px;
}

.table-search {
    margin-top: 16px;
}

.nutrition-table-wrap {
    margin-top: 14px;
    max-height: 480px;
}

.history-heading-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.compact-action {
    min-height: 34px;
    padding: 7px 10px;
    font-size: 0.84rem;
}

.nutrition-history-modal {
    width: min(1180px, calc(100vw - 48px));
}

.nutrition-history-modal-toolbar {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto;
    gap: 16px;
    align-items: end;
    margin-bottom: 14px;
}

.nutrition-history-modal-table {
    max-height: min(620px, calc(100vh - 230px));
    margin-top: 0;
}

.nutrition-history-table td:nth-child(2) {
    min-width: 320px;
    max-width: 520px;
    white-space: normal;
}

.nutrition-history-table td:last-child {
    min-width: 180px;
}

.kidney-lab-entry-grid {
    grid-template-columns: minmax(460px, 0.48fr) minmax(0, 0.52fr);
}

.kidney-lab-number-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.kidney-lab-help-button {
    width: 28px;
    height: 28px;
}

.lab-reference-modal {
    width: min(460px, 100%);
}

.lab-reference-result {
    display: grid;
    justify-items: center;
    gap: 8px;
    margin: 8px 0 18px;
    text-align: center;
}

.lab-reference-result strong {
    color: #1c2d2a;
    font-size: 1.35rem;
}

.lab-reference-result > span:last-child {
    color: #53635f;
}

.lab-reference-icon {
    display: grid;
    place-items: center;
    width: 78px;
    height: 78px;
    border-radius: 50%;
    color: #ffffff;
    font-size: 3rem;
    font-weight: 850;
    line-height: 1;
}

.lab-reference-result--success .lab-reference-icon {
    background: #57c667;
}

.lab-reference-result--attention .lab-reference-icon {
    background: #d8892f;
}

.lab-reference-result--neutral .lab-reference-icon {
    background: #6f817d;
}

.lab-reference-goal {
    margin: 0 0 12px;
    color: #1c2d2a;
    font-size: 1.08rem;
    font-weight: 800;
    text-align: center;
}

.lab-reference-source {
    margin: 0;
    color: #6a7774;
    font-size: 0.82rem;
    text-align: center;
}

.kidney-lab-table-wrap {
    max-height: 560px;
}

.kidney-lab-trend-panel {
    grid-column: 2;
    padding: 20px;
}

.line-chart {
    display: grid;
    gap: 14px;
    margin-top: 18px;
}

.line-chart svg {
    width: 100%;
    height: 230px;
    border-radius: 8px;
    background: #f4f7f6;
}

.line-chart polyline {
    fill: none;
    stroke: #2f756e;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.5;
    vector-effect: non-scaling-stroke;
}

.line-chart-labels {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 8px;
}

.line-chart-labels span {
    display: grid;
    gap: 2px;
    color: #5d6a68;
    font-size: 0.82rem;
    font-weight: 700;
}

.bp-trend-panel,
.bp-trend-readings {
    padding: 20px;
}

.bp-trend-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(180px, 240px)) auto;
    align-items: end;
    gap: 12px;
    margin-top: 18px;
}

.bp-trend-chart {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.bp-trend-chart svg {
    width: 100%;
    height: 340px;
    border-radius: 8px;
    background: #f4f7f6;
}

.bp-trend-line {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.6;
    vector-effect: non-scaling-stroke;
}

.bp-trend-line--systolic {
    stroke: #d9272e;
}

.bp-trend-line--diastolic {
    stroke: #2459e6;
}

.bp-systolic-swatch {
    background: #d9272e;
}

.bp-diastolic-swatch {
    background: #2459e6;
}

.bp-trend-labels {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(76px, 1fr));
    gap: 8px;
}

.bp-trend-labels span {
    display: grid;
    gap: 2px;
    color: #5d6a68;
    font-size: 0.82rem;
    font-weight: 700;
}

.bp-trend-reading-table {
    max-height: 340px;
}

.weight-trend-panel,
.weight-trend-readings {
    padding: 20px;
}

.weight-trend-chart {
    position: relative;
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.weight-trend-chart svg {
    width: 100%;
    height: 340px;
    border-radius: 8px;
    background: #f4f7f6;
}

.weight-trend-line {
    fill: none;
    stroke: #121a18;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.6;
    vector-effect: non-scaling-stroke;
}

.weight-trend-callout {
    position: absolute;
    color: #5d6a68;
    font-size: 0.9rem;
    font-weight: 800;
}

.weight-trend-callout--start {
    top: 18px;
    left: 14px;
}

.weight-trend-callout--current {
    right: 14px;
    bottom: 18px;
}

.weight-change-summary {
    margin: 12px 0 0;
    font-weight: 900;
}

.weight-change-summary--good {
    color: #147a2e;
}

.weight-change-summary--watch {
    color: #9b6a00;
}

.weight-trend-reading-table {
    max-height: 340px;
}

.exercise-line-chart {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.exercise-line-chart svg {
    width: 100%;
    height: 250px;
    border-radius: 8px;
    background: #f4f7f6;
}

.exercise-line-chart polyline {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.3;
    vector-effect: non-scaling-stroke;
}

.session-line {
    stroke: #f28a22;
}

.average-line {
    stroke: #3f88bd;
}

.chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    color: #5d6a68;
    font-size: 0.9rem;
    font-weight: 700;
}

.chart-legend span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.chart-legend i {
    width: 16px;
    height: 4px;
    border-radius: 999px;
}

.legend-orange {
    background: #f28a22;
}

.legend-blue {
    background: #3f88bd;
}

.monthly-bar-chart {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 18px;
    height: 300px;
    margin-top: 18px;
    padding: 8px 0 0;
}

.monthly-bar-column {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    gap: 5px;
    min-width: 0;
    color: #5d6a68;
    font-size: 0.84rem;
    font-weight: 800;
    text-align: center;
}

.monthly-bar-column small {
    min-height: 1.1rem;
    color: #6a7774;
    font-size: 0.76rem;
    font-weight: 700;
}

.monthly-bar-track {
    position: relative;
    align-self: stretch;
    border-radius: 8px;
    background: #f1f5f3;
    overflow: hidden;
}

.monthly-bar-fill {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    border-radius: 8px 8px 0 0;
    background: #2f8a56;
}

.advanced-toggle-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0 10px;
}

.advanced-toggle-row span {
    color: #5d6a68;
    font-size: 0.9rem;
}

.help-icon-button {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    border: 1px solid #c9d6d3;
    border-radius: 50%;
    background: #f6f9f8;
    color: #184652;
    font-weight: 850;
    cursor: pointer;
}

.help-icon-button:hover,
.help-icon-button:focus-visible {
    border-color: #184652;
    outline: none;
}

.inline-toast {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    border: 1px solid #cfe0dc;
    border-radius: 8px;
    padding: 11px 12px;
    background: #e7f5ed;
    color: #25553b;
    font-weight: 700;
}

.inline-toast button {
    border: 0;
    background: transparent;
    color: #184652;
    cursor: pointer;
    font-weight: 850;
}

.bmi-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 12px 14px;
    background: #f6f9f8;
}

.bmi-panel span {
    font-weight: 800;
}

.bmi-panel--ok {
    border-color: #bee0ca;
    background: #e1f4e8;
    color: #23623f;
}

.bmi-panel--watch {
    border-color: #ead9ad;
    background: #fff4d8;
    color: #80611d;
}

.bmi-panel--high {
    border-color: #e3b5b7;
    background: #f8dddd;
    color: #8f2329;
}

.notes-input {
    min-height: 116px;
    resize: vertical;
}

.audit-text {
    margin: -6px 0 0;
    color: #6b7775;
    font-size: 0.86rem;
    font-weight: 700;
}

.form-command-row {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}

.form-command-row .secondary-link,
.form-command-row .primary-action {
    min-width: 112px;
}

.form-command-row button:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.table-pager {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 12px;
}

.table-pager span {
    color: #5d6a68;
    font-size: 0.9rem;
    font-weight: 700;
}

.table-pager button:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.data-table-wrap {
    max-height: 560px;
    margin-top: 18px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    overflow: auto;
}

.blood-pressure-history-table {
    max-height: 430px;
}

.weight-history-table {
    max-height: 430px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
}

.data-table th,
.data-table td {
    border-bottom: 1px solid #e4ecea;
    padding: 10px 11px;
    text-align: left;
    vertical-align: top;
}

.data-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f3f7f6;
    color: #384846;
    font-size: 0.84rem;
    text-transform: uppercase;
}

.data-table tbody tr {
    cursor: pointer;
}

.data-table tbody tr:hover,
.data-table tbody tr.is-selected {
    background: #e8f2f0;
}

.data-table--readonly tbody tr {
    cursor: default;
}

.data-table--readonly tbody tr:hover {
    background: transparent;
}

.data-table td:last-child {
    min-width: 220px;
}

.renal-food-panel {
    overflow: hidden;
}

.renal-food-table-wrap {
    max-height: 640px;
    margin-top: 18px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    overflow: auto;
}

.renal-food-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 12px 14px;
    background: #f8fbfa;
}

.renal-food-actions > div:first-child {
    display: grid;
    gap: 2px;
}

.renal-food-actions span {
    color: #5d6a68;
    font-size: 0.88rem;
}

.renal-food-actions > div:last-child {
    display: flex;
    gap: 10px;
}

.renal-food-select-column {
    width: 58px;
    min-width: 58px;
    text-align: center;
}

.renal-food-select-column input {
    width: 18px;
    height: 18px;
    accent-color: #173f4a;
    cursor: pointer;
}

.renal-food-table td:nth-child(2) {
    min-width: 180px;
}

.renal-food-table td:last-child {
    min-width: 260px;
}

.renal-food-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 0.78rem;
    font-weight: 800;
}

.renal-food-pill--allowed {
    background: #dff1e8;
    color: #17633d;
}

.renal-food-pill--restricted {
    background: #f8dddd;
    color: #8f2329;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(23, 33, 31, 0.46);
}

.info-modal {
    width: min(760px, 100%);
    max-height: calc(100vh - 48px);
    overflow: auto;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 22px;
    background: #ffffff;
    box-shadow: 0 22px 70px rgba(23, 33, 31, 0.26);
}

.info-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.info-modal-header span {
    color: #5c6a66;
    font-size: 0.84rem;
    font-weight: 800;
    text-transform: uppercase;
}

.info-modal-header h2 {
    margin: 4px 0 0;
}

.modal-close-button {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    background: #f6f9f8;
    color: #243331;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: 800;
    line-height: 1;
}

.modal-close-button:hover,
.modal-close-button:focus-visible {
    border-color: #184652;
    outline: none;
}

.info-modal-note {
    margin-bottom: 16px;
    color: #53635f;
    line-height: 1.45;
}

.formula-panel {
    display: grid;
    gap: 8px;
    margin-bottom: 16px;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 14px 16px;
    background: #f6f9f8;
}

.formula-panel code {
    color: #173f4a;
    font-weight: 800;
    white-space: normal;
}

.formula-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 16px;
    margin-bottom: 16px;
}

.formula-grid span {
    color: #53635f;
}

.confirm-modal {
    width: min(520px, 100%);
}

.confirm-modal-detail {
    margin: 0;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 14px 16px;
    background: #f6f9f8;
    color: #17211f;
    font-weight: 800;
}

.confirm-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.danger-action {
    min-height: 42px;
    border: 0;
    border-radius: 8px;
    padding: 10px 16px;
    background: #a61f2b;
    color: #ffffff;
    cursor: pointer;
    font-weight: 800;
}

.danger-action:hover,
.danger-action:focus-visible {
    background: #861722;
    outline: none;
}

.bmi-chart-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.bmi-chart-column {
    border: 1px solid #d7e1df;
    border-radius: 8px;
    overflow: hidden;
}

.bmi-chart-column h3 {
    margin: 0;
    padding: 12px 14px;
    background: #eef5f3;
    color: #243331;
}

.bmi-reference-table {
    width: 100%;
    border-collapse: collapse;
}

.bmi-reference-table th,
.bmi-reference-table td {
    border-top: 1px solid #e4ecea;
    padding: 11px 14px;
    text-align: left;
}

.bmi-reference-table th {
    color: #384846;
    font-size: 0.82rem;
    text-transform: uppercase;
}

.compact-empty {
    margin-top: 18px;
    padding: 24px;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(260px, 0.32fr) minmax(0, 0.68fr);
    gap: 14px;
}

.profile-summary-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 22px;
}

.profile-avatar {
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    border-radius: 8px;
    background: #173f4a;
    color: #ffffff;
    font-size: 1.4rem;
    font-weight: 850;
}

.profile-summary-card h2 {
    margin: 0;
    font-size: 1.3rem;
}

.profile-summary-card p {
    margin: 0;
    color: #5d6a68;
}

.profile-gender-options {
    display: grid;
    grid-template-columns: auto auto;
    justify-content: start;
    column-gap: 16px;
}

.profile-gender-options legend {
    min-width: 84px;
}

.profile-radio-options {
    display: inline-flex;
    align-items: center;
    gap: 16px;
}

.profile-preferences-panel {
    display: grid;
    gap: 16px;
    margin-top: 4px;
    border-top: 1px solid #e4ecea;
    padding-top: 18px;
}

.profile-toggle-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.nutrition-goal-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.goal-field-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.goal-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.goal-toggle input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.goal-toggle span {
    min-width: 52px;
    border-radius: 999px;
    padding: 5px 10px;
    background: #dce6e4;
    color: #60706d;
    text-align: center;
}

.goal-toggle input:checked + span {
    background: #173f4a;
    color: #ffffff;
}

.goal-toggle input:focus-visible + span {
    outline: 3px solid rgba(23, 63, 74, 0.25);
    outline-offset: 2px;
}

.goal-toggle-field .form-input:disabled {
    background: #edf2f1;
    color: #879492;
    cursor: not-allowed;
    opacity: 0.75;
}

.profile-disclaimer {
    margin: 0;
    border-left: 4px solid #d39b2d;
    border-radius: 8px;
    padding: 12px 14px;
    background: #fff8e8;
    color: #5d4b22;
    font-weight: 700;
}

.app-disclosure {
    line-height: 1.45;
}

.app-disclosure--auth {
    margin: 0;
    border-left: 4px solid #d39b2d;
    border-radius: 8px;
    padding: 12px 14px;
    background: #fff8e8;
    color: #5d4b22;
    font-weight: 700;
}

.dashboard-disclosure {
    margin: 16px 0 0;
    border-top: 1px solid #d7e1df;
    padding-top: 12px;
    color: #5d6a68;
    font-size: 0.95rem;
    font-weight: 700;
}

.ai-coach-card {
    display: grid;
    gap: 18px;
    border-left: 4px solid #2f7d69;
    padding: 22px;
    background: #ffffff;
}

.ai-coach-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.ai-coach-heading span {
    display: block;
    color: #2f6f61;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.ai-coach-heading h2 {
    margin: 4px 0 0;
    font-size: 1.55rem;
}

.ai-coach-heading p,
.ai-coach-placeholder,
.ai-coach-summary,
.ai-coach-care-note,
.ai-coach-disclosure {
    margin: 6px 0 0;
}

.ai-coach-heading p,
.ai-coach-placeholder {
    color: #5d6a68;
    font-weight: 700;
}

.ai-coach-heading .ai-coach-saved {
    color: #2f6f61;
    font-size: 0.84rem;
}

.ai-coach-facts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    margin: 0;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    overflow: hidden;
    background: #d7e1df;
}

.ai-coach-facts div {
    min-width: 0;
    padding: 12px 14px;
    background: #f7faf9;
}

.ai-coach-facts dt {
    color: #5d6a68;
    font-size: 0.82rem;
    font-weight: 700;
}

.ai-coach-facts dd {
    margin: 4px 0 0;
    color: #071518;
    font-weight: 800;
}

.ai-coach-summary {
    max-width: 980px;
    color: #17211f;
    font-size: 1.05rem;
    line-height: 1.55;
}

.ai-coach-guidance {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.ai-coach-guidance section {
    border-top: 3px solid #b9d8ce;
    padding-top: 12px;
}

.ai-coach-guidance h3 {
    margin: 0;
    font-size: 1rem;
}

.ai-coach-guidance ul {
    display: grid;
    gap: 8px;
    margin: 10px 0 0;
    padding-left: 20px;
}

.ai-coach-guidance li {
    line-height: 1.45;
}

.ai-coach-care-note {
    border-left: 3px solid #d39b2d;
    padding: 10px 12px;
    background: #fff8e8;
    color: #4b4128;
    line-height: 1.45;
}

.ai-coach-error {
    border: 1px solid #e6b6b1;
    border-radius: 8px;
    padding: 11px 13px;
    background: #fff2f0;
    color: #8d2921;
    font-weight: 700;
}

.ai-coach-disclosure {
    border-top: 1px solid #edf2f1;
    padding-top: 12px;
    color: #5d6a68;
    font-size: 0.88rem;
    font-weight: 700;
}

.ai-coach-card .primary-action:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.report-card-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.report-card,
.report-detail-panel {
    padding: 20px;
}

.report-card {
    display: flex;
    flex-direction: column;
}

.report-card h2 {
    margin: 4px 0 0;
    font-size: 1.6rem;
}

.report-card-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
    margin: 0;
}

.report-card-action-row {
    margin-top: auto;
    padding-top: 16px;
}

.meal-sodium-note {
    margin: 16px 0 0;
    color: #5d6a68;
    font-size: 0.82rem;
    line-height: 1.45;
}

.report-metric-list {
    display: grid;
    gap: 10px;
    margin: 18px 0 0;
}

.report-metric-list div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    border-top: 1px solid #edf2f1;
    padding-top: 10px;
}

.report-metric-list dt {
    color: #5d6a68;
    font-weight: 700;
}

.report-metric-list dd {
    margin: 0;
    color: #071518;
    font-weight: 800;
    text-align: right;
}

.report-metric-list--narrative div {
    display: grid;
    align-items: start;
}

.report-metric-list--narrative dd {
    text-align: left;
}

.report-detail-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    gap: 14px;
    margin-top: 14px;
}

.report-table-wrap {
    max-height: 320px;
}

.report-note-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.nutrient-report-modal {
    max-height: min(760px, calc(100vh - 48px));
    overflow: auto;
}

.action-report-list {
    display: grid;
    gap: 14px;
    margin: 18px 0 0;
}

.action-report-list div {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    border-top: 1px solid #edf2f1;
    padding-top: 12px;
}

.action-report-list dt {
    color: #233c3f;
    font-weight: 800;
}

.action-report-list dd {
    margin: 0;
    color: #071518;
    font-weight: 800;
    text-align: right;
}

.action-source-list {
    display: grid;
    gap: 10px;
    margin-top: 22px;
    border-top: 1px solid #edf2f1;
    padding-top: 16px;
}

.action-source-list > strong {
    color: #233c3f;
}

.action-source-list p {
    margin: 0;
    color: #5d6a68;
    font-weight: 700;
}

.action-source-list ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.action-source-list li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
}

.action-source-list li::before {
    content: "•";
    color: #173f4a;
    font-weight: 900;
}

.action-source-list li span {
    flex: 1;
    min-width: 0;
    color: #071518;
}

.action-source-list li strong {
    white-space: nowrap;
}

.profile-toast {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    margin-right: auto;
    border: 1px solid #a7dac0;
    border-radius: 8px;
    padding: 9px 11px;
    background: #e9f8ef;
    color: #173f2d;
    box-shadow: 0 12px 28px rgba(34, 56, 55, 0.12);
    font-weight: 700;
}

.profile-last-updated {
    align-self: center;
    margin-right: auto;
    color: #5d6a68;
    font-size: 0.9rem;
    font-weight: 700;
}

.profile-toast-icon {
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #35b765;
    color: #ffffff;
    font-size: 0.82rem;
}

.profile-toast button {
    border: 0;
    background: transparent;
    color: #45615b;
    cursor: pointer;
    font-size: 1.1rem;
    line-height: 1;
}

.form-toast {
    margin-top: 12px;
    margin-right: 0;
}

.history-toast {
    display: flex;
    margin: 0 0 14px;
}

.history-toast-copy {
    display: grid;
    flex: 1;
    gap: 2px;
}

.history-toast-copy small {
    color: #4f625d;
    font-size: 0.82rem;
    font-weight: 600;
}

.profile-toast--error {
    border-color: #e3b5b7;
    background: #f8dddd;
    color: #74262a;
}

.profile-toast--error .profile-toast-icon {
    background: #b84449;
}

.toggle-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    border: 1px solid #d7e1df;
    border-radius: 8px;
    padding: 13px;
    background: #f8fbfa;
    cursor: pointer;
}

.toggle-card:hover {
    border-color: #9ab8b3;
    background: #f2f8f6;
}

.toggle-card input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #173f4a;
}

.toggle-card strong {
    display: block;
    color: #243331;
}

.toggle-card small {
    display: block;
    margin-top: 4px;
    color: #64716e;
    line-height: 1.35;
}

#blazor-error-ui {
    display: none;
}

@media (max-width: 860px) {
    .login-page {
        grid-template-columns: 1fr;
    }

    .login-visual {
        min-height: 330px;
        padding: 22px;
    }

    .login-panel {
        min-height: auto;
        padding: 32px 22px 42px;
        box-shadow: none;
    }

    .account-form-grid {
        grid-template-columns: 1fr;
    }

    .gender-options {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .height-picker {
        grid-template-columns: 1fr;
    }

    .metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-shell {
        grid-template-columns: 1fr;
    }

    .dashboard-rail {
        position: static;
        height: auto;
        border-right: 0;
        border-bottom: 1px solid #d7e1df;
    }

    .rail-nav {
        display: flex;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    .rail-nav a,
    .rail-nav-toggle {
        flex: 0 0 auto;
    }

    .rail-signout {
        display: none;
    }

    .dashboard-main {
        padding: 20px;
    }

    .dashboard-topbar,
    .dashboard-actions,
    .status-band,
    .ai-coach-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .ai-coach-facts,
    .ai-coach-guidance {
        grid-template-columns: 1fr;
    }

    .status-band > div:last-child {
        text-align: left;
    }

    .bmi-chart-grid {
        grid-template-columns: 1fr;
    }

    .metric-card-grid,
    .dashboard-grid,
    .entry-grid,
    .report-card-grid,
    .report-detail-grid,
    .profile-grid {
        grid-template-columns: 1fr;
    }

    .bp-number-grid,
    .weight-number-grid,
    .exercise-number-grid,
    .profile-toggle-grid,
    .nutrition-goal-fields {
        grid-template-columns: 1fr;
    }

    .form-command-row {
        flex-direction: column;
    }

    .nutrition-panel,
    .nutrition-trend-grid,
    .fluid-summary-panel,
    .activity-panel {
        grid-column: auto;
        grid-row: auto;
    }

    .nutrition-trend-grid {
        grid-template-columns: 1fr;
    }

    .nutrition-trend-labels strong,
    .nutrition-trend-labels em {
        display: none;
    }

    .fluid-summary-content {
        align-items: flex-start;
        flex-direction: column;
    }

    .fluid-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .weight-sparkline-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .weight-sparkline-stats {
        grid-template-columns: 1fr 1fr;
    }

    .weight-sparkline-stats > div + div {
        border-left: 0;
    }

    .weight-sparkline-stats > div {
        border-bottom: 1px solid #dce6e3;
    }

    .bar-chart {
        grid-template-columns: repeat(7, minmax(34px, 1fr));
        gap: 8px;
    }
}
