.mdh-portal [hidden]{display:none!important}
.mdh-portal{padding-block:clamp(1.5rem,5vw,4.5rem)}
.mdh-portal-grid{max-width:700px}
.mdh-account-card{overflow:hidden;background:white;border:1px solid var(--line,#efd2df);border-radius:1.75rem;box-shadow:0 16px 40px #1f355b14}
.mdh-account-card{padding:clamp(1.1rem,3.5vw,2.25rem)}
.mdh-account-card h1{margin:0 0 .55rem;color:var(--navy);font-size:clamp(1.9rem,4vw,3rem);line-height:1.12}
.mdh-account-card h2,.mdh-account-card h3{color:var(--navy)}
.mdh-account-card #intro{color:var(--muted);margin:0 0 1.2rem}
.mdh-account-card #modes{display:flex;flex-wrap:wrap;gap:.55rem;margin-bottom:1.1rem}
.mdh-account-card form,.mdh-account-card #password-group{display:grid;gap:.55rem}
.mdh-account-card label{font-weight:800;color:var(--navy)}
.mdh-account-card input,.mdh-account-card button{font:inherit;min-height:44px}
.mdh-account-card input{width:100%;border:1px solid #c897ac;border-radius:.7rem;background:#fff;padding:.65rem .8rem;color:var(--navy)}
.mdh-account-card button{cursor:pointer}
.mdh-account-card button:not(.button){border:1px solid #efd2df;border-radius:999px;padding:.55rem 1rem;background:#fff4f9;color:var(--navy);font-weight:800}
.mdh-account-card button[aria-pressed=true]{background:#853253;color:white;border-color:transparent}
.mdh-account-card button:disabled{opacity:.65;cursor:default}
.mdh-account-card .text-button{justify-self:center;text-decoration:underline;background:white!important;border-color:transparent!important}
.mdh-account-card :focus-visible{outline:3px solid #315971;outline-offset:3px}
.mdh-account-card #submit{justify-content:center;margin-top:.45rem}
.mdh-account-card #status:empty{display:none}
.mdh-account-card #status{padding:.7rem .85rem;background:#fff1f7;border-radius:.65rem;overflow-wrap:anywhere}
.mdh-account-card #session button{margin:.3rem .25rem .1rem 0}
.mdh-account-card #authenticator-key,.mdh-account-card #accounts{overflow-wrap:anywhere}
.hero-art.mdh-product-art{display:grid;grid-template-rows:auto 1fr;gap:1rem;min-height:0;padding:clamp(.8rem,2vw,1.35rem);background:linear-gradient(160deg,#fff3f9,#eaf7f7)}
.mdh-product-art img.mdh-hero-banner{height:auto;border-radius:1rem}
.mdh-hero-screens{display:flex;justify-content:center;align-items:start;gap:clamp(.6rem,2vw,1.2rem)}
.mdh-product-art .mdh-hero-screens img{width:auto;height:clamp(12rem,25vw,19rem);max-width:46%;object-fit:contain;border:4px solid #23324d;border-radius:1.15rem;box-shadow:0 8px 20px #1f355b25}
.mdh-account-card #authenticator-qr{display:block;width:min(100%,250px);height:auto;margin:.5rem auto;background:white;border:1px solid var(--line,#efd2df);border-radius:.45rem;image-rendering:pixelated}
.mdh-account-card #authenticator-manual{padding:.45rem 0;color:var(--navy)}
.mdh-account-card #authenticator-manual summary{cursor:pointer;font-weight:700}
.mdh-account-card .mdh-staff-link{display:inline-flex;align-items:center;min-height:44px;margin-inline-start:auto;padding:.55rem 1rem;border:1px solid #efd2df;border-radius:999px;background:#fff4f9;color:var(--navy);font-weight:800;text-decoration:none}
.mdh-account-card .mdh-staff-link:hover{background:#ffe8f2}

.mdh-portal-banner{display:block;width:100%;height:auto;margin:0 0 1.1rem;border-radius:1rem}
.mdh-account-card .mdh-staff-link[aria-current="page"]{background:#853253;color:white;border-color:transparent}

#dashboards fieldset {
  margin: 1rem 0;
  padding: .85rem;
  border: 1px solid #bd9e78;
  border-radius: .75rem;
}

#dashboards label {
  margin-inline-end: .5rem;
}

#dashboards input[type="checkbox"] {
  width: auto;
  min-height: 0;
  margin-inline-end: .25rem;
}

#dashboards button {
  margin: .25rem;
}

#caregiver-sections:not([hidden]) {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin: 1.25rem 0;
  border-bottom: 1px solid #bd9e78;
  padding-bottom: .75rem;
}

#caregiver-sections button[aria-pressed="true"] {
  background: #6b4636;
  color: #fff;
}

#portal-community article,
#portal-messages article {
  margin: .75rem 0;
  padding: .85rem;
  border: 1px solid #bd9e78;
  border-radius: .75rem;
  background: #fffaf0;
  overflow-wrap: anywhere;
}

#portal-community article p,
#portal-messages article p {
  white-space: pre-wrap;
}

#portal-community textarea,
#portal-messages textarea,
#portal-community select {
  display: block;
  box-sizing: border-box;
  width: 100%;
  padding: .65rem;
  border: 1px solid #bd9e78;
  border-radius: .5rem;
  font: inherit;
  color: inherit;
  background: #fff;
}

#portal-community textarea,
#portal-messages textarea {
  min-height: 5rem;
  resize: vertical;
}

.mdh-portal-grid:has(.mdh-workspace){max-width:1180px}
.mdh-workspace{background:#fffaf7;border-color:#ead8d0}
.mdh-workspace .mdh-portal-banner{aspect-ratio:3/1;object-fit:contain;background:#fff0f5}
.mdh-workspace #caregiver-sections{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:.55rem;border-color:#efdae4}
.mdh-workspace #caregiver-sections button{margin:0;border-radius:.8rem}
.mdh-workspace #caregiver-sections button[aria-pressed=true],.mdh-workspace #session .mdh-primary,.mdh-workspace .mdh-device-picker button[aria-pressed=true]{background:#853253;color:white;border-color:#853253}
.mdh-workspace #session>section:not([hidden]){padding:clamp(.85rem,3vw,1.6rem);border:1px solid #ead7d8;border-radius:1.2rem;background:#fff}
.mdh-workspace #session h3{margin:0 0 .75rem}
.mdh-device-picker,.mdh-section-actions{display:flex;flex-wrap:wrap;gap:.5rem;margin-block:.5rem .85rem}
.mdh-workspace #dashboards .mdh-device{min-inline-size:0;border-color:#e8d1bb;background:#fffaf0;padding:clamp(.65rem,2vw,1.25rem)}
.mdh-device legend{padding-inline:.45rem;font-weight:800;color:var(--navy)}
.mdh-device-sync{width:fit-content;padding:.25rem .65rem;border-radius:999px;background:#e5f2e8;color:#28533c}
.mdh-device details,.mdh-workspace #portal-post-form,.mdh-workspace #portal-new-message{margin-block:.75rem;padding:1rem;background:#fff;border:1px solid #ead7d0;border-radius:.85rem}
.mdh-device summary{cursor:pointer;font-weight:800}
.mdh-device details label:has(input[type=checkbox]){display:flex;align-items:center;gap:.55rem;min-height:44px}
.mdh-device details input[type=checkbox]{width:1.2rem;height:1.2rem;accent-color:#853253}
.mdh-tools ul{list-style:none;margin:0;padding:0;display:grid;gap:.5rem}
.mdh-tools li{display:flex;align-items:center;gap:.65rem;min-height:64px;background:#fff;border:1px solid #ebd9cb;border-radius:.75rem;padding:.4rem .65rem}
.mdh-tools img{object-fit:contain;flex:none}
.mdh-tool-actions{display:flex;flex-wrap:wrap;gap:.3rem;margin-inline-start:auto}
.mdh-workspace #dashboards .mdh-tools button{margin:0;padding:.4rem .7rem}
.mdh-message-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.5fr);gap:1rem}
.mdh-message-layout:has(#portal-conversation:empty){grid-template-columns:minmax(0,1fr)}
.mdh-message-layout #portal-conversation:not(:empty){padding:1rem;border:1px solid #ead7d0;border-radius:.85rem;overflow-wrap:anywhere}
@media(max-width:640px){
  .mdh-workspace #caregiver-sections{grid-template-columns:repeat(2,minmax(0,1fr))}
  .mdh-message-layout{grid-template-columns:minmax(0,1fr)}
  .mdh-tools li{flex-wrap:wrap}
  .mdh-tool-actions{width:100%;margin:0}
}

.mdh-account-heading,.mdh-device-actions{display:flex;align-items:center;justify-content:space-between;gap:.75rem;flex-wrap:wrap}
.mdh-account-heading #sign-out,.mdh-device-actions .mdh-primary{margin-inline-start:auto}
.mdh-device-actions{margin-block-start:.75rem}
.mdh-device details form,.mdh-message-user form{margin-top:.65rem}
.mdh-message-user{margin-block:.75rem;padding:.8rem;border:1px solid #ead7d0;border-radius:.85rem;background:#fffaf0}
.mdh-message-user summary{cursor:pointer;font-weight:800}

#staff-navigation{display:flex;flex-wrap:wrap;gap:.5rem;border-bottom:1px solid #efdae4;padding-bottom:.7rem}
#staff-navigation button[aria-pressed=true]{background:#853253;color:#fff;border-color:#853253}
#staff-accounts article,#staff-accounts details,.mdh-support,.mdh-support article{margin:.65rem 0;padding:.75rem;border:1px solid #ead7d8;border-radius:.8rem;background:#fffaf7;overflow-wrap:anywhere}
#staff-accounts article p,.mdh-support article p{white-space:pre-wrap}
#staff-accounts summary,.mdh-support summary{font-weight:800;cursor:pointer}
#staff-accounts h4,.mdh-support h4{margin:.1rem 0}
#staff-accounts textarea,.mdh-support textarea{display:block;box-sizing:border-box;width:100%;border:1px solid #c897ac;border-radius:.7rem;padding:.65rem .8rem;font:inherit}
.mdh-staff-search{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap}
.mdh-staff-search input{flex:1 1 13rem;width:auto;min-width:0}
.mdh-support form{margin-top:.65rem}
