/* MDI Updates pilot: bounded test-page section; no observers or global UI changes. */
.mdi-updates { margin-block: 2rem 3rem; padding-block: 1.75rem; border-top: 1px solid #dce6ef; }
.mdi-updates__head { display: flex; justify-content: space-between; gap: 1rem; align-items: start; }
.mdi-updates__head h2 { margin: .35rem 0 0; }
.mdi-updates__head > span { font-size: .78rem; color: #41627a; white-space: nowrap; }
.mdi-updates__grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,290px),1fr)); gap: 1rem; margin-top: 1rem; }
.mdi-updates__card { border: 1px solid #dce6ef; border-radius: .8rem; padding: 1.15rem; background: #fff; }
.mdi-updates__card h3 { font-size: 1.1rem; line-height: 1.4; margin: .65rem 0; }
.mdi-updates__meta { display: flex; gap: .6rem; justify-content: space-between; flex-wrap: wrap; color: #49647a; font-size: .79rem; }
.mdi-updates__version { font-size: .8rem; color: #37556a; }
.mdi-updates__card a { font-weight: 600; }
@media(max-width:640px) { .mdi-updates__head { flex-direction:column; } }

/* Latest approved updates: progressive enhancement; hidden when there are no reviewed records. */
.mdi-home-updates[hidden]{display:none}
.mdi-home-updates{margin-block:20px 28px;padding:22px 24px;border:1px solid #d5e2ee;border-radius:16px;background:#f8fbff}
.mdi-home-updates__head{display:flex;justify-content:space-between;align-items:end;gap:20px}
.mdi-home-updates__head h2{margin:4px 0 0;color:#133d65;font-size:clamp(24px,3vw,30px)}
.mdi-home-updates__head p{margin:0;max-width:420px;color:#55718a;font-size:13px;line-height:1.55}
.mdi-home-updates__grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:14px;margin-top:18px}
.mdi-home-updates__card{min-width:0;background:#fff;border:1px solid #dce6ef;border-radius:12px;padding:18px}
.mdi-home-updates__meta{display:flex;justify-content:space-between;flex-wrap:wrap;gap:6px;color:#526f87;font-size:12px}
.mdi-home-updates__meta strong{color:#194c79}
.mdi-home-updates__card h3{margin:12px 0 9px;font-size:18px;line-height:1.35}
.mdi-home-updates__card h3 a{text-decoration:none;color:#143f68}
.mdi-home-updates__card h3 a:hover,.mdi-home-updates__card h3 a:focus-visible{text-decoration:underline}
.mdi-home-updates__card p{margin:0 0 12px;color:#435e75;font-size:13.5px;line-height:1.6}
.mdi-home-updates__source{color:#58758b;font-size:12px}
.mdi-home-updates__link{display:inline-flex;margin-top:13px;font-size:13px;font-weight:700;text-decoration:none}
.mdi-home-updates__link:hover,.mdi-home-updates__link:focus-visible{text-decoration:underline}
.mdi-updates-jump--hero{display:inline-flex;align-items:center;max-width:max-content;margin-top:13px;padding:7px 12px;border-radius:9px;border:1px solid #b5d1ed;background:#eef6ff;color:#13518e;font-size:13px;font-weight:700;text-decoration:none}
.mdi-updates-jump--hero:hover,.mdi-updates-jump--hero:focus-visible{background:#e0efff;text-decoration:underline}
.patient-record-nav .mdi-updates-jump{color:#13518e;font-weight:700;border-left-color:#89b7e6}
#research-updates{scroll-margin-top:95px}
@media(max-width:640px){.mdi-home-updates{padding:17px;margin-block:16px 22px}.mdi-home-updates__head{display:block}.mdi-home-updates__head p{margin-top:8px}.mdi-home-updates__card{padding:16px}.mdi-updates-jump--hero{font-size:14px;min-height:42px}}

/* Optional, small hero link only after approved homepage updates have loaded. */
.home-updates-quick-link[hidden],.home-updates-new-badge[hidden]{display:none}
.home-updates-quick-link{margin:12px 0 0;position:relative;z-index:3}
.home-updates-quick-link a{display:inline-flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:10px;max-width:100%;min-height:46px;cursor:pointer;pointer-events:auto;padding:9px 16px;border:1px solid #155eef;border-radius:11px;background:#155eef;color:#fff;font-size:14px;font-weight:750;line-height:1.35;text-decoration:none;box-shadow:0 3px 10px rgba(21,94,239,.14);transition:background-color .18s ease,box-shadow .18s ease}
.home-updates-quick-link a:hover{background:#104cc8;border-color:#104cc8;box-shadow:0 5px 12px rgba(21,94,239,.19);color:#fff}
.home-updates-quick-link a:focus-visible{outline:3px solid #ffbe45;outline-offset:3px;color:#fff}
.home-updates-quick-link__arrow{font-size:19px;font-weight:700;line-height:1}
.home-updates-new-badge{display:inline-flex;align-items:center;justify-content:center;min-width:42px;padding:3px 7px;border-radius:5px;background:#ffbe45;color:#593400;font-size:11px;font-weight:850;letter-spacing:.055em;animation:mdi-new-pulse .85s ease-in-out 3}
@keyframes mdi-new-pulse{0%,100%{transform:scale(1);box-shadow:0 0 0 0 rgba(255,190,69,0)}50%{transform:scale(1.08);box-shadow:0 0 0 4px rgba(255,190,69,.32)}}
.mdi-home-updates__head .eyebrow{border-left:4px solid #e6a23c;padding-left:10px}
#mdi-latest-updates-title{scroll-margin-top:100px}
@media(prefers-reduced-motion:reduce){.home-updates-new-badge{animation:none}.home-updates-quick-link a{transition:none}}
@media(max-width:430px){.home-updates-quick-link a{font-size:13px;gap:8px;padding:10px 12px}}

/* Static highlighting only for manually approved records added to MDI within 30 days. */
.mdi-home-updates__identity{display:inline-flex;flex-wrap:wrap;align-items:center;gap:8px;min-width:0}
.mdi-home-updates__card--new{border-color:#e7c687;border-top:3px solid #e6a23c;background:linear-gradient(180deg,#fffcf4 0,#fff 112px)}
.mdi-home-updates__new{display:inline-flex;align-items:center;white-space:nowrap;padding:3px 7px;border-radius:5px;background:#ffbe45;color:#593400;font-size:10px;font-weight:800;letter-spacing:.035em}
.mdi-home-updates__card--new .mdi-home-updates__link{color:#155eef}
.mdi-home-updates__card--new .mdi-home-updates__link:hover{text-decoration:underline}

/* Research updates keep editorial publication distinct from scientific integration. */
.mdi-updates__review-state{margin-top:12px}
.mdi-home-updates__review-state{margin-top:10px}
.mdi-evidence-status{display:inline-flex;align-items:center;max-width:100%;border:1px solid;border-radius:999px;padding:3px 10px;font-size:11px;line-height:1.5;font-weight:750;white-space:normal}
.mdi-evidence-status--context-only{background:#eff5fa;border-color:#d4e2ec;color:#345870}
.mdi-evidence-status--evidence-review-pending{background:#fff7e8;border-color:#efc98d;color:#80520b}
.mdi-evidence-status--integrated-in-evidence{background:#edf8f1;border-color:#9ed0ae;color:#205d38}
