:root {
  --green: #145f46;
  --green-dark: #134e3a;
  --text: #243c35;
  --muted: #5a6e64;
  --line: #d0e0d8;
  --bg: #f5f8f6;
  --mint: #e8f0ea;
  --white: #fff;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: var(--text);
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  font-size: 15px;
  line-height: 1.5;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button,
a {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
a {
  color: var(--green);
  text-decoration: none;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #166e60;
  outline-offset: 3px;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 29px;
  letter-spacing: -1px;
  line-height: 1.25;
  font-weight: 650;
}
h2 {
  font-size: 20px;
  letter-spacing: -0.5px;
  font-weight: 650;
}
h3 {
  font-size: 16px;
  font-weight: 650;
}
p {
  line-height: 1.65;
}
small,
.small {
  font-size: 12px;
}
.muted {
  color: var(--muted);
}
.eyebrow {
  display: block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.9px;
  color: var(--green);
  margin-bottom: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 25px;
  letter-spacing: -1px;
  font-weight: 750;
}
.brand-dot {
  color: #48936a;
}
.layout {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 252px;
  background: white;
  border-right: 1px solid var(--line);
  padding: 32px 23px 18px;
  display: flex;
  flex-direction: column;
  z-index: 10;
}
.workspace {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f6f8f5;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 13px 11px;
  margin: 36px 0 30px;
  font-size: 12px;
}
.workspace small,
.user small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-top: 3px;
}
.workspace-icon {
  width: 32px;
  height: 32px;
  border: 1px solid #d4e7d7;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: var(--green);
  font-size: 25px;
  background: #eaf3e7;
}
.workspace-dot,
.online-dot {
  height: 6px;
  width: 6px;
  background: #679b75;
  border-radius: 50%;
  display: inline-block;
}
.workspace-dot {
  margin-left: auto;
}
.nav-label {
  font-size: 9px;
  letter-spacing: 1.7px;
  font-weight: 700;
  color: #a0a9a5;
  margin: 0 14px 12px;
}
nav {
  display: grid;
  gap: 7px;
}
nav a,
.settings-link {
  display: flex;
  align-items: center;
  gap: 13px;
  border-radius: 8px;
  color: var(--muted);
  padding: 12px 14px;
  font-size: 12px;
  font-weight: 550;
}
nav a.active {
  background: var(--green);
  color: white;
  box-shadow: 0 4px 12px #166e601a;
}
nav a:hover,
.settings-link:hover {
  background: #f1f5f1;
}
.ico {
  font-size: 20px;
  line-height: 1;
  width: 21px;
  height: 21px;
  flex-shrink: 0;
  display: inline-flex;
  justify-content: center;
  font-weight: 400;
}
.nav-count {
  margin-left: auto;
  border-radius: 5px;
  padding: 1px 6px;
  background: #d7e7d9;
  color: var(--green);
  font-size: 10px;
}
.sidebar-bottom {
  margin-top: auto;
  padding-top: 36px;
}
nav a.active:hover {
  background: var(--green-dark);
}
.settings-link.active {
  background: var(--mint);
  color: var(--green-dark);
}
.care-note {
  border-radius: 10px;
  background: #f7f8f1;
  padding: 15px;
  margin-bottom: 23px;
}
.care-note > span {
  font-size: 27px;
  color: #69936b;
  display: block;
  margin-bottom: 8px;
}
.care-note strong {
  font-size: 11px;
}
.care-note p {
  font-size: 11px;
  color: #8a9286;
  margin-top: 5px;
}
.user {
  display: flex;
  gap: 10px;
  align-items: center;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  margin-top: 16px;
  font-size: 11px;
}
.user strong {
  display: block;
  max-width: 119px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.avatar {
  width: 49px;
  height: 49px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #e6eee2;
  color: #587755;
  font-size: 17px;
  font-weight: 600;
  flex-shrink: 0;
}
.avatar.tiny {
  width: 33px;
  height: 33px;
  font-size: 10px;
}
.avatar.large {
  width: 85px;
  height: 85px;
  font-size: 27px;
  margin: 28px auto 18px;
}
.color-1 {
  background: #e7edf3;
  color: #688198;
}
.color-2 {
  background: #f2e9df;
  color: #a18a68;
}
.color-3 {
  background: #f0e7ed;
  color: #9a7490;
}
.icon-btn {
  border: 0;
  background: none;
  color: #8b9790;
  font-size: 22px;
  margin-left: auto;
  padding: 3px 7px;
}
.main-wrap {
  margin-left: 252px;
  width: calc(100% - 252px);
}
.topbar {
  height: 77px;
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  color: #84918b;
}
.breadcrumb {
  margin-left: 15px;
  color: #bac3be;
}
.breadcrumb span {
  color: #43574d;
  margin-left: 13px;
}
.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
}
.topbar-right .avatar {
  margin-left: 17px;
}
#content {
  padding: 36px 40px;
  max-width: 1600px;
  margin: auto;
  min-height: calc(100vh - 133px);
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}
.page-heading p {
  margin-top: 10px;
  font-size: 12px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 10px;
  padding: 11px 17px;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  min-height: 41px;
}
.primary {
  background: var(--green);
  color: white;
}
.primary:hover {
  background: var(--green-dark);
}
.secondary {
  background: white;
  color: var(--text);
  border-color: #dce5de;
}
.white {
  background: white;
  color: var(--green);
}
.full {
  width: 100%;
}
.small-btn {
  padding: 6px 11px;
  min-height: 34px;
  font-size: 11px;
}
.welcome-banner {
  background: linear-gradient(115deg, #174f46, #237564);
  border: 1px solid #1d6153;
  min-height: 251px;
  border-radius: 20px;
  position: relative;
  display: flex;
  justify-content: space-between;
  overflow: hidden;
  padding: 30px 34px;
  margin-bottom: 25px;
}
.banner-tag {
  display: block;
  color: #d0e8c8;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 1.6px;
  margin-bottom: 12px;
}
.welcome-banner h2 {
  font-size: 27px;
  color: #fff;
  letter-spacing: -0.7px;
  line-height: 1.35;
}
.welcome-banner p {
  font-size: 12px;
  color: #e0eee7;
  margin: 12px 0 19px;
}
.welcome-banner .btn {
  font-size: 11px;
  padding: 8px 13px;
  min-height: 36px;
}
.banner-art {
  width: 300px;
  position: relative;
  flex-shrink: 0;
}
.art-circle {
  width: 280px;
  height: 280px;
  border: 1px solid #ffffff26;
  border-radius: 50%;
  position: absolute;
  top: -13px;
  right: -5px;
  box-shadow:
    0 0 0 35px #ffffff08,
    0 0 0 36px #ffffff14;
}
.art-card {
  width: 145px;
  height: 199px;
  background: #fffef9;
  border-radius: 12px;
  position: absolute;
  top: 0;
  right: 65px;
  transform: rotate(9deg);
  display: flex;
  align-items: center;
  flex-direction: column;
  box-shadow: 0 12px 24px #4c744019;
  padding: 15px;
  gap: 6px;
}
.art-card img {
  width: 24px;
  height: 24px;
}
.art-card strong {
  font-size: 11px;
}
.art-card small {
  font-size: 6px;
  color: #929b86;
  letter-spacing: 1px;
}
.art-qr {
  font-size: 95px;
  line-height: 1;
  color: #49674b;
}
.art-heart,
.art-check {
  position: absolute;
  display: grid;
  place-items: center;
  background: #fffef8;
  box-shadow: 0 4px 12px #496c4110;
  border-radius: 13px;
  transform: rotate(-10deg);
  color: #819968;
}
.art-heart {
  left: 24px;
  top: 110px;
  width: 51px;
  height: 51px;
  font-size: 32px;
}
.art-check {
  right: 20px;
  top: 38px;
  width: 43px;
  height: 43px;
  font-size: 25px;
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 34px;
}
.stat {
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px 19px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.stat span:not(.ico) {
  font-size: 10px;
  color: #7f8b84;
}
.stat strong {
  display: block;
  font-size: 29px;
  font-weight: 600;
  line-height: 1.8;
}
.stat small {
  font-size: 9px;
  color: #9ba49d;
}
.stat-icon {
  width: 33px;
  height: 33px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.mint {
  background: #eaf3e8;
  color: #769576;
}
.blue {
  background: #edf2f9;
  color: #7188a7;
}
.peach {
  background: #fcf0e4;
  color: #c49a6d;
}
.lilac {
  background: #f0eef8;
  color: #9b8bae;
}
.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}
.section-heading h2 {
  font-size: 18px;
}
.section-heading p {
  font-size: 11px;
  margin-top: 4px;
}
.text-btn {
  border: 0;
  background: none;
  padding: 6px 0;
  font-size: 11px;
  font-weight: 600;
  color: var(--green);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.person-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.person-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
  padding: 24px 22px 0;
  box-shadow: 0 4px 18px #203c3805;
  min-width: 0;
}
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 15px;
  gap: 8px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #37633d;
  background: #eff5eb;
  padding: 4px 8px;
  border-radius: 5px;
  font-size: 9px;
  font-weight: 550;
  white-space: nowrap;
}
.badge span {
  font-size: 7px;
}
.badge.gray {
  background: #f1f1f1;
  color: #626262;
}
.person-card h3 {
  font-size: 15px;
}
.person-age {
  font-size: 11px;
  color: #909991;
  margin: 4px 0 17px;
}
.person-age span {
  margin: 0 5px;
}
.person-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  color: #8a948e;
  margin: 10px 0;
}
.person-meta .ico {
  font-size: 16px;
  color: #9aa69e;
}
.person-meta > span:last-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 7px;
  border-top: 1px solid #edf0eb;
  margin-top: 18px;
  padding: 13px 0;
}
.card-bottom .small {
  font-size: 8px;
}
.card-bottom .text-btn {
  font-size: 10px;
  white-space: nowrap;
}
.info-strip {
  display: flex;
  gap: 16px;
  align-items: center;
  background: #f0f4ee;
  border: 1px solid #e5ebe1;
  border-radius: 10px;
  padding: 19px 22px;
  margin-top: 26px;
}
.info-icon {
  font-size: 25px;
  color: #809473;
}
.info-strip strong {
  font-size: 11px;
  color: #64805d;
}
.info-strip p {
  font-size: 10px;
  color: #95a08e;
  margin-top: 3px;
}
.info-strip a {
  margin-left: auto;
  white-space: nowrap;
  font-size: 9px;
  color: #758e68;
}
footer {
  padding: 17px 40px;
  border-top: 1px solid var(--line);
  color: #adb5af;
  font-size: 10px;
  display: flex;
  gap: 14px;
}
.footer-secure {
  margin-left: auto;
  font-size: 9px;
}
.toolbar {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin: 24px 0;
}
.search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 0 12px;
  width: 380px;
  margin: 0;
}
.search input {
  border: 0;
  margin: 0;
  box-shadow: none;
}
.toolbar select {
  width: 190px;
  margin: 0;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
}
.panel h3 {
  margin-bottom: 12px;
}
.rfid-panel {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.rfid-panel p {
  font-size: 12px;
}
.inline-form {
  display: flex;
  gap: 10px;
}
.inline-form input {
  margin: 0;
}
.qr-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.qr-card {
  text-align: center;
}
.qr-code {
  width: 180px;
  max-width: 100%;
  margin: 20px auto;
}
.qr-code svg {
  display: block;
  width: 100%;
  height: auto;
}
.qr-card .btn {
  margin: 8px 0;
}
.qr-card p {
  font-size: 12px;
}
.table-wrap {
  overflow: auto;
  padding: 0;
}
table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
}
th {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #8c988f;
  background: #fbfcfa;
}
td,
th {
  padding: 19px 23px;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
}
.activities article {
  display: flex;
  gap: 17px;
  align-items: center;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}
.activities article:last-child {
  border: 0;
}
.activity-icon {
  width: 35px;
  height: 35px;
  display: grid;
  place-items: center;
  background: var(--mint);
  border-radius: 50%;
  color: var(--green);
}
.activities strong {
  font-size: 13px;
}
.activities p {
  color: var(--muted);
  font-size: 11px;
}
.activities time {
  margin-left: auto;
  font-size: 11px;
  color: var(--muted);
}
.account {
  max-width: 550px;
}
.account h3 {
  margin-top: 10px;
}
.back {
  display: inline-block;
  margin-bottom: 20px;
  font-size: 12px;
}
.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 23px;
}
.detail-grid dl {
  display: grid;
  grid-template-columns: 185px 1fr;
  gap: 18px;
  font-size: 13px;
  margin: 20px 0 0;
}
.detail-grid dt {
  color: var(--muted);
}
.detail-grid dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.multiline {
  white-space: pre-line;
}
.contact-row,
.location-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
}
.contact-row:last-child,
.location-row:last-child {
  border: 0;
}
.contact-row p,
.location-row p {
  color: var(--muted);
  font-size: 11px;
}
.contact-row > a,
.location-row > a {
  margin-left: auto;
}
.danger {
  color: #b2584f;
}
.empty {
  text-align: center;
  border: 1px dashed #dbe5dc;
  border-radius: 12px;
  padding: 60px 20px;
  color: var(--muted);
  background: #fff;
}
.empty > span {
  font-size: 40px;
}
.empty h3 {
  margin: 12px;
}
.empty p {
  font-size: 12px;
}
.compact {
  padding: 20px;
  margin-top: 15px;
}
label {
  display: block;
  font-size: 12px;
  font-weight: 550;
  margin: 18px 0;
}
label small {
  display: block;
  color: var(--muted);
  font-weight: 400;
  margin-top: 5px;
}
input,
select,
textarea {
  display: block;
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #dce4dc;
  border-radius: 7px;
  color: var(--text);
  background: white;
  margin-top: 7px;
  outline: none;
  min-height: 42px;
}
input:focus,
select:focus,
textarea:focus {
  border-color: #8cac8b;
  box-shadow: 0 0 0 3px #eaf2e7;
}
input::placeholder,
textarea::placeholder {
  color: #a2aca5;
}
textarea {
  resize: vertical;
  min-height: 80px;
}
.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 400;
  font-size: 11px;
}
.check input {
  width: 16px;
  min-height: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--green);
}
.check small {
  margin: 0;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-row label {
  margin-bottom: 0;
}
.contact-fields {
  border: 1px solid var(--line);
  background: #fafcf9;
  padding: 0 16px;
  border-radius: 9px;
  margin-bottom: 14px;
}
.contact-consent {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}
.family-checks {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 15px;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  border-top: 1px solid var(--line);
  margin-top: 25px;
  padding-top: 20px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 15px;
  max-width: 640px;
  width: calc(100% - 30px);
  max-height: 90vh;
  padding: 30px;
  color: var(--text);
  box-shadow: 0 20px 80px #203c3833;
}
dialog::backdrop {
  background: #1e352f66;
  backdrop-filter: blur(3px);
}
dialog h2 {
  margin-bottom: 12px;
}
dialog h3 {
  margin-top: 24px;
}
.modal-close {
  float: right;
  font-size: 26px;
}
.error {
  padding: 12px;
  background: #fff0ed;
  border: 1px solid #f5d3ca;
  color: #a64f3e;
  border-radius: 7px;
  font-size: 12px;
  margin: 15px 0;
}
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translate(-50%, 20px);
  background: #263f35;
  color: white;
  padding: 14px 24px;
  border-radius: 9px;
  box-shadow: 0 8px 25px #0002;
  opacity: 0;
  pointer-events: none;
  transition: 0.2s;
  z-index: 100;
  max-width: 90%;
  font-size: 13px;
}
#toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}
hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 22px 0;
}
.login {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
}
.login-story {
  padding: 50px 65px;
  background: #eaf1e5;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}
.login-story > .brand {
  margin-bottom: 60px;
}
.login-story h1 {
  font-size: 65px;
  line-height: 1.1;
  letter-spacing: -3px;
  color: #345740;
}
.login-story p {
  max-width: 350px;
  color: #7c8f73;
  margin: 24px 0;
  font-size: 15px;
}
.login-story > small {
  font-size: 10px;
  color: #8b9e83;
  margin-top: 20px;
}
.orbit {
  width: 260px;
  height: 220px;
  border: 1px solid #ccddc4;
  border-radius: 50%;
  margin: 30px auto 15px;
  position: relative;
}
.orbit-heart {
  position: absolute;
  inset: 50px 70px;
  display: grid;
  place-items: center;
  font-size: 65px;
  background: #fffdf6;
  border-radius: 24px;
  color: #8ba679;
  transform: rotate(-10deg);
  box-shadow: 0 10px 40px #456e4314;
}
.orbit-person {
  position: absolute;
  background: #fdfbf4;
  box-shadow: 0 10px 20px #456e4309;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 15px;
  color: #8a987d;
}
.orbit-person.one {
  top: 10px;
  left: 8px;
}
.orbit-person.two {
  bottom: 20px;
  right: 0;
  background: #e0e7db;
}
.orbit-label {
  position: absolute;
  bottom: -10px;
  left: 50px;
  background: white;
  padding: 7px 20px;
  font-size: 10px;
  border-radius: 20px;
  color: #698360;
}
.login-form {
  display: grid;
  place-items: center;
  background: #fff;
  padding: 50px;
}
.login-form-inner {
  width: 100%;
  max-width: 370px;
}
.login-form h2 {
  font-size: 27px;
  margin: 15px 0;
}
.login-form .muted {
  font-size: 13px;
}
.login-form form {
  margin: 30px 0;
}
.login-form .btn {
  margin-top: 9px;
}
.help-note {
  display: flex;
  gap: 14px;
  background: #f6f8f3;
  border-radius: 9px;
  padding: 17px;
  margin: 35px 0 20px;
}
.help-note .ico {
  color: #6b8a62;
  font-size: 25px;
}
.help-note p {
  font-size: 11px;
  color: #8c9786;
}
.help-note strong {
  color: #647c5e;
  font-size: 11px;
}
.public-page {
  max-width: 620px;
  padding: 32px 20px;
  margin: auto;
}
.public-page > .brand {
  justify-content: center;
  margin-bottom: 40px;
}
.public-intro {
  text-align: center;
  padding-bottom: 30px;
}
.public-intro h2 {
  font-size: 20px;
  margin-top: 22px;
}
.public-intro p {
  font-size: 14px;
  margin: 10px 0;
}
.public-contact {
  display: flex;
  gap: 15px;
  align-items: center;
  justify-content: space-between;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}
.public-contact p {
  font-size: 12px;
  color: var(--muted);
}
.public-contact .btn {
  font-size: 11px;
}
.public-page .panel > p {
  margin: 14px 0;
}
.public-footer {
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  padding: 10px;
}
.loading {
  display: grid;
  place-items: center;
  height: 100vh;
  color: var(--green);
}
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 12px 20px;
  border-radius: 10px;
  background: white;
  color: var(--green-dark);
  transform: translateY(-180%);
}
.skip-link:focus { transform: translateY(0); }
[hidden] { display: none !important; }
#content:focus { outline: none; }
.results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 44px;
  margin: -10px 0 20px;
  color: var(--muted);
  font-size: 13px;
}
.password-toggle { margin-top: 4px; }
.mobile-account { display: none; }
.empty .ico { width: 40px; height: 40px; color: var(--green); }
.empty .btn { margin-top: 22px; }
.search:focus-within { border-color: var(--green); box-shadow: 0 0 0 3px #166e601a; }
.search input:focus { box-shadow: none; }
@media (min-width: 1500px) {
  #content {
    padding: 45px 55px;
  }
  .welcome-banner {
    padding: 35px 45px;
  }
  .person-card {
    padding: 25px 23px 0;
  }
  .card-bottom .small {
    font-size: 10px;
  }
  .stat span:not(.ico) {
    font-size: 12px;
  }
  .stat small {
    font-size: 10px;
  }
}
@media (max-width: 1200px) {
  .sidebar {
    width: 220px;
    padding: 25px 17px;
  }
  .main-wrap {
    margin-left: 220px;
    width: calc(100% - 220px);
  }
  #content {
    padding: 30px 25px;
  }
  .topbar {
    padding: 0 25px;
  }
  .stats {
    gap: 10px;
  }
  .stat {
    padding: 15px 12px;
  }
  .stat-icon {
    width: 27px;
    height: 27px;
  }
  .person-grid {
    gap: 12px;
  }
  .card-bottom {
    flex-wrap: wrap;
  }
  .info-strip a {
    white-space: normal;
  }
  .banner-art {
    width: 240px;
  }
  .art-card {
    right: 40px;
  }
  .art-heart {
    left: 0;
  }
  .page-heading h1 {
    font-size: 25px;
  }
}
@media (max-width: 1000px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .person-grid,
  .qr-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .person-grid .person-card:last-child:nth-child(3) {
    grid-column: 1/-1;
  }
  .detail-grid {
    grid-template-columns: 1fr;
  }
  .detail-grid > aside {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
  }
  .rfid-panel {
    align-items: stretch;
    flex-direction: column;
  }
  .page-heading {
    align-items: flex-start;
  }
  .banner-art {
    width: 185px;
  }
  .art-card {
    right: 5px;
  }
  .art-check {
    right: -15px;
  }
  .login-story {
    padding: 40px;
  }
  .login-story h1 {
    font-size: 52px;
  }
  .login-form {
    padding: 35px;
  }
  .info-strip a {
    display: none;
  }
}
@media (max-width: 760px) {
  .sidebar {
    position: static;
    width: 100%;
    padding: 18px 20px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .layout {
    display: block;
  }
  .sidebar .brand {
    font-size: 22px;
  }
  .sidebar .brand img {
    width: 32px;
    height: 32px;
  }
  .workspace,
  .nav-label,
  .sidebar-bottom {
    display: none;
  }
  .sidebar nav {
    display: flex;
    overflow: auto;
    margin-top: 18px;
    gap: 7px;
  }
  .sidebar nav a {
    padding: 9px 11px;
    white-space: nowrap;
    font-size: 11px;
  }
  .sidebar nav .ico {
    font-size: 16px;
  }
  .nav-count {
    display: none;
  }
  .main-wrap {
    margin: 0;
    width: 100%;
  }
  .topbar {
    height: 50px;
    padding: 0 20px;
  }
  .topbar-right > span {
    display: none;
  }
  .topbar-right .avatar {
    margin: 0;
  }
  .topbar-right .avatar {
    cursor: pointer;
  }
  #content {
    padding: 25px 20px;
  }
  .page-heading {
    flex-wrap: wrap;
    gap: 18px;
    margin-bottom: 22px;
  }
  .page-heading h1 {
    font-size: 25px;
  }
  .page-heading .eyebrow {
    font-size: 9px;
  }
  .welcome-banner {
    padding: 25px 23px;
    min-height: 236px;
  }
  .welcome-banner h2 {
    font-size: 23px;
  }
  .welcome-banner p {
    max-width: 220px;
    font-size: 11px;
  }
  .banner-art {
    width: 135px;
    margin-right: -25px;
  }
  .art-card {
    width: 112px;
    height: 172px;
    right: 12px;
    top: 13px;
  }
  .art-circle {
    width: 210px;
    height: 210px;
    right: -60px;
  }
  .art-heart {
    width: 35px;
    height: 35px;
    font-size: 23px;
    left: -17px;
    top: 140px;
  }
  .art-check {
    display: none;
  }
  .art-qr {
    font-size: 72px;
  }
  .art-card small {
    font-size: 5px;
  }
  .art-card strong {
    font-size: 9px;
  }
  .stats {
    gap: 12px;
    margin-bottom: 27px;
  }
  .stat {
    padding: 16px 13px;
  }
  .stat strong {
    font-size: 27px;
  }
  .stat span:not(.ico) {
    font-size: 10px;
  }
  .stat small {
    font-size: 8px;
  }
  .stat-icon {
    width: 27px;
    height: 27px;
  }
  .person-grid,
  .qr-grid {
    grid-template-columns: 1fr;
  }
  .person-grid .person-card:last-child:nth-child(3) {
    grid-column: auto;
  }
  .person-card {
    padding: 21px 20px 0;
  }
  .card-bottom {
    flex-wrap: nowrap;
  }
  .card-bottom .small {
    font-size: 10px;
  }
  .person-meta {
    font-size: 12px;
  }
  .person-card h3 {
    font-size: 17px;
  }
  .person-age {
    font-size: 12px;
  }
  .badge {
    font-size: 10px;
  }
  .info-strip {
    padding: 16px;
  }
  .section-heading h2 {
    font-size: 17px;
  }
  .section-heading .text-btn {
    font-size: 10px;
    white-space: nowrap;
  }
  .toolbar {
    flex-direction: column;
  }
  .toolbar .search,
  .toolbar select {
    width: 100%;
  }
  .detail-grid > aside {
    display: block;
  }
  .detail-grid dl {
    grid-template-columns: 1fr;
    gap: 7px;
  }
  .detail-grid dd {
    margin-bottom: 13px;
  }
  .detail-grid .section-heading {
    flex-wrap: wrap;
  }
  .contact-row {
    flex-wrap: wrap;
  }
  .contact-row > a {
    margin-left: 45px;
  }
  .location-row {
    flex-wrap: wrap;
  }
  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .contact-consent {
    align-items: flex-start;
  }
  .check {
    align-items: flex-start;
  }
  .check input {
    flex-shrink: 0;
  }
  .check small {
    display: none;
  }
  .activities time {
    font-size: 9px;
    max-width: 95px;
    text-align: right;
  }
  .activities article {
    gap: 10px;
  }
  .inline-form {
    flex-wrap: wrap;
  }
  .inline-form .btn {
    width: 100%;
  }
  footer {
    padding: 15px 20px;
    font-size: 9px;
  }
  .footer-secure {
    display: none;
  }
  .login {
    display: block;
  }
  .login-story {
    padding: 25px 30px 32px;
  }
  .login-story > .brand {
    margin-bottom: 35px;
  }
  .login-story h1 {
    font-size: 43px;
  }
  .login-story h1 br {
    display: none;
  }
  .login-story p {
    margin: 15px 0 0;
    font-size: 13px;
  }
  .login-story .eyebrow {
    font-size: 9px;
  }
  .orbit,
  .login-story > small {
    display: none;
  }
  .login-form {
    padding: 35px 28px;
  }
  .login-form h2 {
    font-size: 24px;
  }
  .login-form-inner {
    max-width: 450px;
  }
  .public-contact {
    flex-wrap: wrap;
  }
  .public-contact .btn {
    width: 100%;
  }
  dialog {
    padding: 24px 20px;
  }
  .contact-fields {
    padding: 0 12px;
  }
  .account {
    max-width: none;
  }
}
@media (max-width: 480px) {
  .banner-art {
    display: none;
  }
  .welcome-banner h2 {
    font-size: 24px;
  }
  .welcome-banner p {
    max-width: none;
  }
  .welcome-banner {
    min-height: 0;
  }
  .stat small {
    font-size: 9px;
  }
  .person-age {
    font-size: 12px;
  }
  .info-strip p {
    font-size: 11px;
  }
  .sidebar nav {
    scrollbar-width: thin;
  }
}
@media print {
  body {
    background: white;
  }
  .sidebar,
  .skip-link,
  .topbar,
  footer,
  .page-heading,
  .back,
  .detail-grid > div,
  .detail-grid > aside > .panel:not(.qr-card),
  .qr-card .btn,
  .qr-card .text-btn,
  #toast,
  dialog {
    display: none !important;
  }
  .main-wrap {
    margin: 0;
    width: 100%;
  }
  #content {
    padding: 0;
    min-height: 0;
  }
  .detail-grid,
  .detail-grid > aside {
    display: block;
  }
  .qr-card {
    width: 300px;
    margin: 20px auto;
    border: 2px dashed #777;
    break-inside: avoid;
  }
  .qr-code {
    width: 210px;
  }
  .qr-card .badge {
    display: none;
  }
}

.person-photo {
  object-fit: cover;
  object-position: center;
}
.avatar.profile-photo {
  width: 112px;
  height: 112px;
  border-radius: 18px;
  font-size: 32px;
}
.photo-panel {
  display: flex;
  align-items: center;
  gap: 24px;
}
.photo-panel .btn {
  margin-top: 14px;
}
#photo-preview {
  display: flex;
  justify-content: center;
  margin: 24px 0;
}
input[type="file"] {
  max-width: 100%;
  font-size: 12px;
}
input[type="file"]::file-selector-button {
  padding: 8px 12px;
  border: 0;
  border-radius: 5px;
  background: #e6f2e9;
  color: #166e60;
  margin-right: 10px;
  cursor: pointer;
}
/* Screen rhythm and readable controls; printed identification keeps its own sizing. */
@media screen {
  .sidebar { overflow-y: auto; }
  .sidebar nav a, .settings-link { min-height: 48px; font-size: 14px; }
  .nav-label { color: var(--muted); font-size: 10px; }
  .care-note p, .care-note strong, .workspace small, .user small { font-size: 12px; color: var(--muted); }
  .topbar { font-size: 13px; color: var(--muted); }
  .topbar-right { font-size: 12px; }
  .topbar-right .avatar { width: 44px; height: 44px; font-size: 13px; }
  .page-heading h1 { font-size: clamp(26px, 2.3vw, 34px); letter-spacing: -1px; }
  .page-heading p, .section-heading p { font-size: 14px; }
  .eyebrow, .page-heading .eyebrow { font-size: 11px; letter-spacing: 1.5px; }
  .btn, .welcome-banner .btn, .public-contact .btn { min-height: 46px; font-size: 14px; border-radius: 10px; }
  .btn { white-space: normal; text-align: center; }
  .page-heading > .btn { flex-shrink: 0; }
  .text-btn, .card-bottom .text-btn, .section-heading .text-btn { min-height: 44px; font-size: 13px; }
  .icon-btn { min-width: 44px; min-height: 44px; color: var(--muted); }
  .btn, .person-card, nav a { transition: background-color .18s, border-color .18s, box-shadow .18s; }
  .secondary:hover { background: #eff6f2; border-color: #9ab9ac; }
  .text-btn:hover { text-decoration: underline; text-underline-offset: 4px; }
  .welcome-banner { padding: 32px; min-height: 260px; }
  .welcome-banner > div:first-child { position: relative; z-index: 1; }
  .welcome-banner h2 { font-size: clamp(25px, 2.2vw, 32px); }
  .welcome-banner p { font-size: 14px; }
  .banner-tag { font-size: 10px; }
  .stat { position: relative; padding: 22px 18px; }
  .stat span:not(.ico) { font-size: 13px; color: var(--muted); }
  .stat strong { font-size: 34px; line-height: 1.65; color: var(--text); }
  .stat small { display: block; font-size: 12px; color: var(--muted); }
  .stat-icon { width: 36px; height: 36px; }
  .mint { color: #416a45; }
  .blue { color: #45658a; }
  .peach { color: #865c2e; }
  .lilac { color: #73558f; }
  .person-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); }
  .person-grid .person-card:last-child:nth-child(3) { grid-column: auto; }
  .person-card { display: flex; flex-direction: column; }
  .person-card h3 { font-size: 19px; overflow-wrap: anywhere; }
  .person-card .avatar { width: 56px; height: 56px; font-size: 19px; }
  .person-age, .person-meta { font-size: 13px; color: var(--muted); }
  .person-meta .ico { color: var(--green); width: 18px; height: 18px; }
  .card-top { margin-bottom: 20px; }
  .badge { font-size: 11px; border-radius: 20px; padding: 5px 10px; }
  .card-bottom { flex-wrap: wrap; margin-top: auto; padding: 14px 0; }
  .person-meta:last-of-type { margin-bottom: 20px; }
  .card-bottom .small { font-size: 12px; flex: 1 1 140px; }
  .card-bottom .text-btn { padding: 8px 12px; border-radius: 8px; background: #eef6f1; }
  .info-strip strong, .help-note strong { font-size: 14px; color: var(--green-dark); }
  .info-strip p, .help-note p, .info-strip a { font-size: 13px; color: var(--muted); }
  .toolbar { padding: 18px; background: #eaf1ed; border-radius: 14px; gap: 12px; }
  .toolbar .search { flex: 1; width: auto; min-width: 0; border-radius: 9px; }
  .toolbar select { width: 195px; }
  label, .check { font-size: 14px; }
  input, select, textarea { font-size: 16px; min-height: 46px; border-color: #aebfb5; border-radius: 9px; }
  input::placeholder, textarea::placeholder { color: #6a7a71; }
  input:focus, select:focus, textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px #166e6026; }
  .check { min-height: 44px; }
  .check input { width: 20px; height: 20px; min-height: 20px; flex-shrink: 0; }
  .form-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  dialog { padding: 28px; border-radius: 20px; }
  dialog h2 { padding-right: 40px; }
  .modal-close { position: sticky; top: 0; margin-top: -8px; margin-right: -8px; border-radius: 50%; background: #f0f5f2; z-index: 1; }
  .modal-actions { flex-wrap: wrap; }
  .check small { overflow-wrap: anywhere; }
  .detail-grid dl, .contact-row, .location-row { font-size: 14px; }
  .contact-row p, .location-row p, .qr-card p, .rfid-panel p { font-size: 13px; }
  .back { font-size: 14px; padding: 8px 0; }
  .panel, .detail-grid > *, .inline-form, .photo-panel > div { min-width: 0; }
  .panel h3 { font-size: 18px; }
  .panel p, .public-intro h1, .qr-card h3 { overflow-wrap: anywhere; }
  .photo-panel { flex-wrap: wrap; }
  .photo-panel > div:last-child { flex: 1 1 170px; }
  th { color: var(--muted); }
  td, th { font-size: 13px; }
  td { overflow-wrap: anywhere; }
  tbody tr:hover { background: #f6faf7; }
  .activities strong { font-size: 14px; }
  .activities p, .activities time { font-size: 13px; }
  .activity-icon { flex-shrink: 0; }
  .empty p { font-size: 14px; }
  .login-story { background: linear-gradient(145deg, #eaf3e8, #dcece4); }
  .login-story p, .login-story > small { color: #50694e; }
  .login-story > small { font-size: 12px; }
  .login-form-inner { max-width: 410px; }
  .login-form .muted { font-size: 14px; }
  .public-intro { padding: 24px 16px 32px; border-radius: 20px; background: #e7f1e9; margin-bottom: 24px; }
  .public-contact p, .public-footer { font-size: 13px; }
  footer, .footer-secure { font-size: 12px; color: var(--muted); }
  .error { font-size: 14px; }
  #toast { width: max-content; }
}
@media screen and (max-width: 1200px) {
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toolbar { flex-wrap: wrap; }
  .toolbar .search { flex-basis: 100%; }
  .toolbar select { flex: 1; }
}
@media screen and (max-width: 760px) {
  .sidebar { padding: 18px 16px 12px; overflow: visible; }
  .sidebar nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 4px 0 8px; margin-top: 14px; overflow: visible; gap: 6px; }
  .sidebar nav a { display: flex; flex-direction: column; justify-content: center; text-align: center; white-space: normal; font-size: 12px; min-height: 66px; padding: 8px 4px; gap: 6px; }
  .sidebar nav .ico { width: 18px; height: 18px; }
  .topbar { padding: 0 16px; height: 60px; }
  .breadcrumb { margin-left: 6px; }
  .breadcrumb span { margin-left: 4px; }
  #content { padding: 24px 16px; }
  .page-heading > .btn { width: 100%; }
  .welcome-banner { padding: 26px 24px; min-height: 0; }
  .banner-art { display: none; }
  .welcome-banner p { max-width: none; }
  .welcome-banner h2 { font-size: 26px; }
  .stat { padding: 17px 14px; }
  .stat-icon { position: absolute; right: 12px; top: 48px; width: 30px; height: 30px; }
  .stat strong { padding-right: 30px; }
  .stat span:not(.ico) { font-size: 12px; }
  .stat small { font-size: 11px; }
  .person-grid { grid-template-columns: 1fr; }
  .section-heading { flex-wrap: wrap; gap: 8px; }
  .section-heading h2 { font-size: 20px; }
  .toolbar { padding: 14px; flex-direction: row; }
  .toolbar .search { flex: 1 1 100%; }
  .toolbar select { flex: 1 1 100%; width: 100%; }
  .panel { padding: 20px; }
  .table-wrap { padding: 0; }
  .contact-row > div:not(.avatar) { flex: 1; min-width: 0; overflow-wrap: anywhere; }
  .contact-row > a { margin-left: 0; }
  .activities article { flex-wrap: wrap; }
  .activities article > div { flex: 1; min-width: 0; }
  .activities time { margin-left: 45px; text-align: left; max-width: none; }
  .form-row { grid-template-columns: 1fr; }
  dialog { padding: 24px 18px; max-height: 90vh; max-height: 90dvh; }
  .modal-actions .btn { flex: 1; }
  .contact-consent { flex-wrap: wrap; gap: 0; padding-bottom: 12px; }
  .contact-consent .check { margin-bottom: 0; }
  .login-story { padding: 24px; }
  .login-story > .brand { margin-bottom: 26px; }
  .login-story h1 { font-size: 38px; letter-spacing: -1.5px; }
  .login-form { padding: 30px 24px; }
  .help-note { margin-top: 24px; }
  .public-page { padding: 24px 16px; }
  .public-page > .brand { margin-bottom: 24px; }
  #toast { bottom: max(16px, env(safe-area-inset-bottom)); padding: 14px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
@media (max-width: 480px) {
  .photo-panel {
    align-items: flex-start;
    gap: 16px;
  }
  .avatar.profile-photo {
    width: 88px;
    height: 88px;
  }
  .photo-panel h3 {
    font-size: 14px;
  }
  .photo-panel .btn {
    white-space: normal;
  }
}

/* Identidad institucional suministrada por el usuario. */
.organization-logo { display: block; width: 100%; height: auto; object-fit: contain; }
.login-organization { width: min(280px, 100%); margin: 16px auto 0; }
.admin-organization { width: 156px; max-width: 100%; margin: 18px auto 0; flex-shrink: 0; }
.admin-organization + .workspace { margin-top: 16px; }
@media (max-width: 760px) {
  .login-organization { width: 152px; margin: 12px auto 0; }
  .admin-organization { width: 112px; margin: 8px auto 0; }
}

/* Pulseras y panel familiar */
.auth-links { display:grid; gap:12px; margin:18px 0; }
.recovery-code { white-space:pre-wrap; overflow-wrap:anywhere; padding:20px; background:var(--mint); color:var(--green-dark); font-size:17px; user-select:all; }
.notification-banner { padding:16px 32px; background:var(--mint); border-bottom:1px solid var(--line); }
.notification-banner[hidden] { display:none; }
.public-fields { border-top:1px solid var(--line); margin-top:24px; padding-top:16px; }
.bracelet-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:24px; }
.bracelet-card { min-width:0; padding:20px; border:1px solid var(--line); border-radius:12px; }
.bracelet-card h3 { overflow-wrap:anywhere; }
.emergency-button { min-height:60px; font-size:16px; margin:12px 0; white-space:normal; }
.child-public .public-intro h1 { font-size:30px; }
.child-public .panel p { margin-top:12px; }
.clipboard-helper { position:fixed; left:-10000px; }
#bracelet-print { display:none; }
@media(max-width:600px){ .notification-banner{padding:14px 20px;font-size:13px}.bracelet-grid{grid-template-columns:1fr}.check{flex-wrap:wrap}.child-public .public-intro h1{font-size:26px} }
@media print { body:has(#bracelet-print) > :not(#bracelet-print){display:none!important} #bracelet-print{display:block;text-align:center;width:280px;margin:20px auto;border:1px dashed #444;padding:16px} #bracelet-print h2{font-size:18px} #bracelet-print .qr-code{width:220px} }

/* Contacto por WhatsApp */
.contact-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: stretch;
}
.contact-actions .btn {
  text-align: center;
  justify-content: center;
}
.btn.whatsapp {
  background: #25d366;
  border-color: #25d366;
  color: #fff;
}
.btn.whatsapp:hover {
  background: #1ebe5a;
  border-color: #1ebe5a;
}