@font-face {
  font-family: Manrope;
  src: url('fonts/Manrope.ttf') format('truetype');
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --navy: #193c79;
  --navy-deep: #102a55;
  --sky: #70bcff;
  --ink: #10233d;
  --muted: #43536b;
  --green: #14785e;
  --border: #e1e9f1;
  --background: #f5f8fb;
  --radius: 22px;
}

* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); font-family: Manrope, system-ui, sans-serif; line-height: 1.6; background: var(--background); padding-bottom: 72px; }
a { color: var(--navy); text-underline-offset: 4px; }
button, input, textarea, select { font: inherit; }
input, textarea, select { color: var(--ink); }
input::placeholder, textarea::placeholder { color: #526078; opacity: 1; }
.management-nav { display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 12px max(20px, calc((100% - 1180px) / 2)); background: #eaf0f8; }
.management-nav a { min-height: 44px; display: inline-flex; align-items: center; font-size: 14px; font-weight: 750; }
.stack select { width: 100%; min-height: 48px; border: 1px solid #bac8d9; border-radius: 10px; background: #fff; padding: 10px 12px; font-size: 16px; }
.stack input, .stack textarea { font-size: 16px; }
button, a, input, textarea { -webkit-tap-highlight-color: transparent; }
button, summary { cursor: pointer; }
button:disabled { opacity: .65; cursor: wait; }
:focus-visible { outline: 3px solid #077abc; outline-offset: 4px; }
input:focus-visible, textarea:focus-visible { outline-offset: 1px; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(27px, 4vw, 40px); letter-spacing: -1.3px; line-height: 1.18; margin-bottom: 12px; font-weight: 800; }
h2 { font-size: 22px; line-height: 1.3; letter-spacing: -.6px; margin-bottom: 14px; }
p { margin-bottom: 18px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.eyebrow { display: block; color: var(--green); font-size: 11px; font-weight: 800; letter-spacing: 1.8px; margin-bottom: 12px; }
.eyebrow.light { color: #b8ddff; }
.container { width: min(1180px, calc(100% - 40px)); margin: 32px auto; }
.card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-bottom: 20px; box-shadow: 0 4px 20px #17334a03; }
.button { display: inline-flex; gap: 18px; align-items: center; justify-content: center; min-height: 48px; padding: 12px 22px; border-radius: 12px; text-decoration: none; border: 1px solid transparent; font-size: 14px; font-weight: 750; transition: background .15s; }
.button.primary { color: #fff; background: var(--navy); }
.button.primary:hover { background: var(--navy-deep); }
.button.secondary { background: #fff; color: var(--navy); border-color: #cbd9e8; }
.button.wide { width: 100%; justify-content: space-between; }
.text-button { background: none; border: 0; color: inherit; min-height: 44px; padding: 8px; font-size: 14px; }
.version-bar { position: fixed; z-index: 10; bottom: 0; left: 0; width: 100%; min-height: 44px; padding: 10px max(20px, calc((100% - 1180px) / 2)); padding-bottom: max(10px, env(safe-area-inset-bottom)); display: flex; justify-content: space-between; gap: 14px; background: #fff; border-top: 1px solid var(--border); font-size: 11px; color: var(--muted); }
.version-bar strong { white-space: nowrap; color: var(--navy); }
.footer-divider { margin: 0 8px; }
.auth-page { background: var(--navy-deep); background-image: radial-gradient(ellipse at 0 0, #235da0 0, transparent 65%), radial-gradient(ellipse at 100% 90%, #1d4c8d 0, transparent 60%); min-height: 100svh; }
.auth-page .version-bar { background: #102a55; color: #c2d5ed; border-color: #ffffff1c; }
.auth-page .version-bar strong { color: #fff; }
.auth-main { width: min(1080px, calc(100% - 48px)); margin: auto; display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 96px; min-height: calc(100svh - 72px); padding: 45px 0; }
.login-intro { color: #fff; }
.login-logo { width: 290px; max-width: 100%; height: auto; display: block; margin-left: -18px; }
.intro-copy { margin-top: 32px; }
.intro-copy h1 { font-size: clamp(36px, 4.3vw, 51px); letter-spacing: -1.7px; }
.intro-copy p { color: #c1d4e9; font-size: 16px; }
.intro-detail { display: flex; gap: 18px; align-items: center; color: #bdd8ef; font-size: 12px; margin-top: 42px; }
.path-mark { font-size: 40px; color: var(--sky); }
.login-card { padding: 42px 38px 30px; background: #fff; border-radius: 25px; box-shadow: 0 24px 70px #071b3860; }
.login-card h2 { font-size: 31px; letter-spacing: -1px; }
.login-card > .muted { margin-bottom: 27px; font-size: 14px; }
.stack { display: grid; gap: 18px; }
label { display: grid; gap: 7px; font-size: 13px; font-weight: 700; }
input, textarea, select { width: 100%; min-height: 48px; border: 1px solid #cbd7e4; border-radius: 10px; padding: 12px 14px; background: #fff; color: var(--ink); font-size: 16px; font-weight: 500; }
input::placeholder, textarea::placeholder { color: #526078; }
textarea { resize: vertical; min-height: 90px; }
.password-wrap { position: relative; }
.password-wrap input { padding-right: 75px; }
.toggle-password { position: absolute; top: 2px; right: 5px; border: 0; background: transparent; min-height: 44px; color: var(--navy); padding: 8px 10px; font-weight: 700; font-size: 12px; }
.forgot-link { font-size: 12px; text-align: right; margin-top: -6px; }
.access-note { border-top: 1px solid var(--border); padding-top: 20px; margin: 26px 0 0; text-align: center; font-size: 11px; color: var(--muted); }
.access-note span { margin-right: 6px; }
.auth-single { grid-column: 1 / -1; width: min(520px, 100%); margin: auto; }
.compact-logo { width: 210px; height: auto; display: block; margin: 0 auto 18px; }
.auth-box { padding: 34px; }
.auth-box h1 { font-size: 30px; }
.auth-box > .muted { font-size: 14px; }
fieldset { margin: 0; padding: 18px; border: 1px solid var(--border); border-radius: 12px; display: grid; gap: 16px; }
legend { padding: 0 7px; font-weight: 800; }
.notice { padding: 16px 20px; border-radius: 12px; margin-bottom: 20px; font-size: 14px; grid-column: 1 / -1; }
.notice.success { color: #0b563f; background: #e1f4eb; border: 1px solid #bee5d4; }
.notice.error { color: #8d2431; background: #fff1f2; border: 1px solid #edc7cb; }
.message-box { grid-column: 1 / -1; width: min(580px, 100%); margin: auto; }
.message-box h1 { font-size: 30px; }
.app-header { min-height: 85px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 15px max(20px, calc((100% - 1180px) / 2)); background: #fff; border-bottom: 1px solid var(--border); }
.brand { display: flex; align-items: center; flex-shrink: 0; text-decoration: none; line-height: 0; background: #fff; }
.brand-logo { display: block; width: 176px; height: auto; background: #fff; }
.brand small { display: block; letter-spacing: 0; font-size: 10px; color: var(--muted); margin-top: 5px; }
.brand-number { display: flex; align-items: center; font-size: 25px; color: var(--navy); letter-spacing: -2px; }
.brand-number span { color: #3d92d1; margin-left: 2px; font-size: 22px; }
.app-header nav { display: flex; align-items: center; gap: 24px; font-size: 13px; }
.app-header nav a { text-decoration: none; padding: 10px 0; }
.app-header form { margin: 0; }
.demo-strip { text-align: center; background: #eaf1f8; padding: 7px 18px; font-size: 10px; letter-spacing: .3px; color: #536a84; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #25856b; margin-right: 8px; }
.journey-hero { padding: 38px 42px; border-radius: 26px; background: linear-gradient(105deg, #e4f1f7 0%, #eef6f8 55%, #e3f0eb 100%); display: flex; justify-content: space-between; align-items: center; overflow: hidden; }
.journey-hero h1 { font-size: clamp(30px, 4.2vw, 45px); }
.journey-hero p { font-size: 14px; margin: 0 0 6px; font-weight: 700; }
.hero-note { color: var(--muted); font-size: 13px; }
.hero-path { display: flex; flex-direction: column; align-items: center; border: 1px solid #adcbd3; width: 165px; height: 165px; border-radius: 50%; justify-content: center; transform: rotate(-5deg); flex-shrink: 0; margin-left: 28px; }
.hero-path > span { font-size: 52px; color: #3976a7; letter-spacing: -5px; font-weight: 500; line-height: 1.2; }
.hero-path small { font-size: 8px; letter-spacing: 2px; text-align: center; color: #3976a7; }
.dashboard-actions, .section-head, .page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.dashboard-actions { margin: 24px 0; }
.patient-context { color: var(--muted); font-size: 13px; }
.action-links { display: flex; gap: 12px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.stat { display: flex; align-items: center; gap: 14px; margin-bottom: 0; padding: 23px 20px; }
.stat-icon { display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; flex-shrink: 0; border-radius: 14px; font-size: 25px; }
.blue { background: #e5f2ff; color: #2269a8; }
.green { background: #e0f5ed; color: #14785e; }
.purple { background: #eee9fc; color: #6950a6; }
.amber { background: #fff0d8; color: #9a651c; }
.stat-label { display: block; font-size: 10px; color: var(--muted); margin-bottom: 5px; }
.stat strong { display: block; font-size: 27px; line-height: 1.3; letter-spacing: -.8px; }
.stat strong small { font-size: 13px; font-weight: 600; }
.stat-date { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; }
.dashboard-grid { display: grid; grid-template-columns: 1.45fr 1fr; gap: 22px; margin-bottom: 22px; }
.dashboard-grid .card { margin: 0; }
.section-head { margin-bottom: 20px; }
.section-head h2 { margin: 0; }
.badge { display: inline-block; background: #edf4fa; color: #405d7b; font-size: 10px; font-weight: 700; padding: 6px 10px; border-radius: 8px; white-space: nowrap; }
.weight-chart { width: 100%; height: auto; margin-top: 8px; }
.grid-line { stroke: #e3eaf2; stroke-dasharray: 4 4; }
.chart-label { font-size: 11px; fill: #677c96; font-family: Manrope, sans-serif; }
.chart-area { fill: #dceff7; opacity: .7; }
.chart-line { stroke: #2585bf; stroke-width: 3; fill: none; stroke-linejoin: round; }
.chart-dot { fill: #fff; stroke: #2585bf; stroke-width: 3; }
.next-step { background: #f3f0fc; border-color: #e5def4; position: relative; }
.next-step .eyebrow { color: #6e519e; }
.step-symbol { position: absolute; right: 28px; top: 18px; color: #957cc0; font-size: 32px; }
.instruction { font-size: 17px; line-height: 1.65; margin-top: 22px; }
.step-options { display: grid; gap: 9px; margin-top: 24px; }
.step-options .button { font-size: 12px; min-height: 44px; }
.milestone { background: #ecf7f1; border-color: #d6e9df; }
.milestone-values { display: flex; gap: 25px; align-items: center; margin: 14px 0 20px; }
.milestone-values > strong { font-size: 63px; line-height: 1.1; letter-spacing: -3px; }
.milestone-values > strong small { font-size: 27px; }
.milestone-values > span { color: #547664; font-size: 12px; }
.milestone-values b { color: var(--green); font-size: 20px; }
.milestone > p { font-size: 13px; }
progress { width: 100%; height: 12px; border: 0; border-radius: 20px; overflow: hidden; background: #d2e3db; accent-color: var(--green); }
progress::-webkit-progress-bar { background: #d2e3db; border-radius: 20px; }
progress::-webkit-progress-value { background: #238665; border-radius: 20px; }
progress::-moz-progress-bar { background: #238665; }
.progress-caption { display: flex; justify-content: space-between; font-size: 11px; margin: 7px 0 14px; }
.waist-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 24px 0; }
.waist-grid > div { background: #edf4fa; padding: 14px 6px; text-align: center; border-radius: 13px; }
.waist-grid span { display: block; font-size: 9px; color: var(--muted); }
.waist-grid strong { display: block; font-size: 26px; margin: 8px 0 2px; }
.waist-grid small { font-size: 9px; color: var(--muted); }
summary { font-size: 13px; font-weight: 700; padding: 12px 0; min-height: 44px; }
details > p { font-size: 13px; color: var(--muted); }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: 12px; }
th { color: var(--muted); font-size: 10px; padding: 13px 12px; background: #f7f9fc; font-weight: 650; white-space: nowrap; }
td { padding: 17px 12px; border-bottom: 1px solid #edf1f5; vertical-align: middle; }
td a { display: inline-block; padding: 8px 0; min-height: 40px; }
caption { text-align: left; font-size: 18px; font-weight: 700; padding-bottom: 15px; }
.breadcrumb { display: flex; gap: 12px; color: var(--muted); font-size: 12px; margin: 0 0 20px; }
.breadcrumb a { text-decoration: none; }
.closing-line { text-align: center; color: var(--muted); font-size: 14px; padding: 20px; }
.previous-step { border-top: 1px solid var(--border); padding-top: 18px; margin-bottom: 18px; }
.previous-step p { margin: 10px 0; }
.form-card { max-width: 670px; margin: 0 auto; }
.form-card h1 { font-size: 32px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.page-heading { margin: 40px 0 30px; }
.date-pill { font-size: 12px; background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 10px 16px; }
.page-heading p { margin: 0; }
.admin-stats { grid-template-columns: repeat(3, 1fr); }
.admin-stats .stat strong { font-size: 34px; }
.search-label { max-width: 230px; }
.tabs { display: flex; gap: 8px; border-bottom: 1px solid var(--border); padding: 0 0 16px; flex-wrap: wrap; }
.tab { border: 0; border-radius: 9px; min-height: 44px; padding: 10px 18px; font-size: 12px; color: var(--muted); background: transparent; }
.tab.active { background: #eaf2fb; color: var(--navy); font-weight: 800; }
.patient-row { display: flex; align-items: center; gap: 18px; padding: 22px 4px; border-bottom: 1px solid #edf1f5; text-decoration: none; }
.patient-name { flex: 1; }
.patient-name strong { font-size: 15px; }
.patient-name small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }
.avatar { width: 45px; height: 45px; border-radius: 50%; background: #e5f0f5; color: #3f6d8a; display: inline-flex; align-items: center; justify-content: center; font-size: 21px; font-weight: 700; flex-shrink: 0; }
.avatar.large { width: 70px; height: 70px; font-size: 32px; }
.empty { color: var(--muted); padding: 22px 0; font-size: 13px; }
.profile-data { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.profile-data dt { color: var(--muted); font-size: 11px; margin-bottom: 6px; }
.profile-data dd { margin: 0; font-weight: 700; font-size: 14px; overflow-wrap: anywhere; }
.skip-link { position: absolute; left: 10px; top: -80px; background: #fff; color: #193c79; padding: 10px; z-index: 20; }
.skip-link:focus { top: 10px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 1000px) {
  .auth-main { gap: 45px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-stats { grid-template-columns: repeat(3, 1fr); }
  .dashboard-grid { grid-template-columns: 1.15fr 1fr; }
  .card { padding: 24px; }
}

@media (max-width: 700px) {
  body { padding-bottom: 65px; }
  .auth-main { display: flex; flex-direction: column; gap: 0; width: min(430px, calc(100% - 36px)); min-height: auto; padding: 20px 0 22px; }
  .login-intro { width: 100%; }
  .login-logo { width: 205px; margin: 0 auto; }
  .intro-copy { margin: 4px 0 20px; text-align: center; }
  .intro-copy .eyebrow, .intro-copy p, .intro-detail { display: none; }
  .intro-copy h1 { font-size: 23px; letter-spacing: -.6px; margin: 5px 0 20px; }
  .intro-copy h1 br { display: none; }
  .login-card { width: 100%; padding: 27px 23px 22px; border-radius: 20px; }
  .login-card h2 { font-size: 27px; }
  .login-card .muted { font-size: 13px; }
  .version-bar { font-size: 10px; padding-left: 16px; padding-right: 16px; }
  .version-bar > span { max-width: 65%; }
  .footer-divider { margin: 0 3px; }
  .app-header { min-height: 70px; gap: 12px; padding: 12px 18px; }
  .brand { gap: 8px; font-size: 12px; }
  .brand small { font-size: 8px; }
  .brand-number { font-size: 21px; }
  .app-header nav { gap: 12px; font-size: 11px; }
  .text-button { font-size: 11px; padding: 4px; }
  .container { width: calc(100% - 28px); margin: 20px auto; }
  .demo-strip { font-size: 9px; }
  .journey-hero { padding: 25px 23px; border-radius: 20px; }
  .journey-hero h1 { font-size: 30px; }
  .journey-hero .eyebrow { font-size: 9px; }
  .journey-hero p { font-size: 11px; }
  .hero-note { font-size: 11px; display: block; max-width: 250px; }
  .hero-path { display: none; }
  .dashboard-actions { flex-direction: column; gap: 13px; align-items: stretch; margin: 20px 0; }
  .patient-context { font-size: 11px; }
  .action-links { width: 100%; }
  .action-links .button { flex: 1; padding: 11px 10px; font-size: 12px; }
  .stat-grid { gap: 10px; margin-bottom: 15px; }
  .stat { gap: 9px; padding: 16px 12px; border-radius: 16px; }
  .stat-icon { width: 31px; height: 34px; border-radius: 10px; font-size: 21px; }
  .stat strong { font-size: 23px; }
  .stat-label { font-size: 10px; }
  .stat-date { font-size: 10px; }
  .stat strong small { font-size: 10px; }
  .dashboard-grid { display: flex; flex-direction: column; gap: 15px; margin-bottom: 15px; }
  .next-step { order: -2; }
  .milestone { order: -1; }
  .card { padding: 22px 18px; border-radius: 18px; margin-bottom: 15px; }
  h2 { font-size: 20px; }
  .section-head { gap: 12px; margin-bottom: 15px; align-items: flex-start; }
  .section-head .badge { font-size: 8px; }
  .eyebrow { font-size: 9px; margin-bottom: 9px; }
  .instruction { font-size: 16px; margin-top: 18px; }
  .milestone-values > strong { font-size: 54px; }
  .waist-grid strong { font-size: 24px; }
  td, th { padding-left: 8px; padding-right: 8px; }
  td { font-size: 11px; }
  .table-scroll { margin: 0 -8px; }
  .measurements-card .section-head a { font-size: 10px; }
  .form-grid, .profile-data { grid-template-columns: 1fr; }
  .page-heading { margin: 25px 0; align-items: flex-start; }
  .page-heading h1 { font-size: 28px; }
  .page-heading .date-pill { display: none; }
  .page-heading .muted { font-size: 12px; }
  .admin-stats { grid-template-columns: repeat(3, 1fr); }
  .admin-stats .stat { display: block; padding: 13px 10px; }
  .admin-stats .stat-icon { margin-bottom: 9px; }
  .admin-stats .stat strong { font-size: 27px; }
  .patient-directory .section-head { flex-direction: column; }
  .search-label { max-width: none; width: 100%; }
  .tabs { gap: 3px; }
  .tab { font-size: 10px; padding: 8px 11px; }
  .patient-row { gap: 10px; }
  .patient-name strong { font-size: 13px; }
  .patient-row .badge { padding: 6px 7px; font-size: 9px; }
  .auth-box { padding: 25px; }
  .auth-single { margin-top: 10px; }
  .auth-single .compact-logo { width: 175px; }
}

@media (max-width: 350px) {
  .brand small { display: none; }
  .app-header nav { gap: 8px; }
  .stat-icon { display: none; }
  .version-bar > span { font-size: 9px; }
  .footer-divider { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none; scroll-behavior: auto; }
}

/* 0.2.1: lectura cómoda y listados compactos, también en celular. */
.app-page { font-size: 17px; }
.app-page label, .app-page .button, .app-page .text-button { font-size: 15px; }
.app-page .small, .app-page summary, .app-page details > p { font-size: 15px; }
.app-page .page-heading .muted, .app-page .hero-note, .app-page .journey-hero p { font-size: 16px; }
.app-page .stat-label, .app-page .badge, .app-page .patient-context { font-size: 13px; }
.app-page .stat-date, .app-page .waist-grid span, .app-page .waist-grid small { font-size: 12px; }
.app-page .eyebrow { font-size: 12px; }
.app-page .step-options .button, .app-page .milestone > p, .app-page .milestone-values > span { font-size: 15px; }
.app-page .progress-caption, .app-page .measurements-card .section-head a, .app-page .breadcrumb { font-size: 14px; }
.app-page .app-header nav { font-size: 14px; }
.app-page .version-bar { font-size: 12px; }
.app-page table { font-size: 15px; line-height: 1.45; }
.app-page th { font-size: 14px; font-weight: 750; padding: 12px; }
.app-page td { font-size: 15px; padding: 10px 12px; }
.app-page td a { padding: 8px 4px; }
.directory-card { padding-top: 22px; }
.table-scroll { max-width: 100%; min-width: 0; }
.compact-table { min-width: 660px; }
.compact-table th, .compact-table td { text-align: left; }
.compact-table tbody tr:hover { background: #f5f8fc; }
.compact-table .email-cell { overflow-wrap: anywhere; max-width: 260px; }
.compact-table td:first-child { min-width: 180px; }
.compact-table form { margin: 0; }
.compact-table input, .compact-table select { min-height: 44px; padding: 8px 10px; }
.compact-table .row-action { min-height: 44px; white-space: nowrap; }
.groups-table td:first-child { min-width: 240px; }
.groups-table select { min-width: 150px; }
.inline-create { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(150px, 220px) auto; gap: 16px; align-items: end; }
.page-heading > .button { flex-shrink: 0; }
#account-form { scroll-margin-top: 20px; }
@media (max-width: 700px) {
  .inline-create { grid-template-columns: 1fr; }
  .app-page .page-heading { flex-wrap: wrap; gap: 16px; }
  .app-page .section-head { flex-wrap: wrap; }
  .directory-card .section-head { flex-direction: column; }
  .app-page .action-links { flex-wrap: wrap; }
  .app-page .action-links .button { font-size: 14px; }
  .app-page .tab { font-size: 13px; }
  .app-page .table-scroll { margin: 0; }
  .app-page .admin-stats { grid-template-columns: 1fr; }
  .app-page .admin-stats .stat { display: flex; align-items: center; gap: 16px; }
  .app-page .admin-stats .stat-icon { margin-bottom: 0; }
}

/* 0.3.0: lectura de medidas y acciones del consultorio. */
.patient-tools { display: flex; align-items: center; gap: 12px; }
.measurement-trend { display: inline-flex; min-width: 28px; justify-content: center; font-size: 20px; font-weight: 800; vertical-align: middle; white-space: nowrap; }
.trend-down { color: #087347; }
.trend-up { color: #b42332; }
.trend-same { color: #195bb0; font-size: 17px; }
.trend-none { color: var(--muted); font-size: 17px; }
.chart-hit { fill: transparent; cursor: pointer; }
.chart-point { cursor: pointer; outline: none; }
.chart-point:hover .chart-dot, .chart-point:focus .chart-dot, .chart-point.is-active .chart-dot { fill: #193c79; stroke: #fff; stroke-width: 3; r: 7; }
.chart-point:focus .chart-hit { stroke: #193c79; stroke-width: 2; }
.chart-readout { display: block; min-height: 48px; padding: 10px 12px; background: #eaf2fb; border-radius: 10px; color: #102a55; font-size: 15px; font-weight: 700; }
.group-actions { display: flex; gap: 6px; align-items: center; }
.trash-button { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; padding: 8px; border: 1px solid #d6acb0; border-radius: 10px; color: #a32331; background: #fff7f7; }
.trash-button svg { width: 20px; height: 20px; }
button:disabled.trash-button { cursor: not-allowed; opacity: .55; }
@media (max-width: 700px) {
  .patient-tools { width: 100%; flex-wrap: wrap; }
  .patient-tools .search-label { flex: 1; min-width: 150px; }
  .chart-label { font-size: 22px; fill: #43536b; }
  .chart-hit { r: 26; }
}

/* Crédito compartido: público y autenticado, junto a la versión. */
.version-meta { display: flex; align-items: center; gap: 16px; }
.pocketlab-credit { color: var(--navy); font-size: 12px; white-space: nowrap; }
.auth-page .pocketlab-credit { color: #e0ecfc; }
.pocketlab-credit:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; border-radius: 2px; }
@media (max-width: 700px) {
  body { padding-bottom: calc(100px + env(safe-area-inset-bottom)); }
  .version-bar { flex-direction: column; gap: 3px; font-size: 12px; }
  .version-bar > span { max-width: none; font-size: 12px; }
  .version-meta { justify-content: space-between; gap: 12px; font-size: 12px; }
}

.waist-guide { margin-top: 18px; padding: 14px; background: #edf5fc; border-radius: 14px; }
.waist-guide summary { color: var(--navy); font-weight: 750; min-height: 30px; cursor: pointer; }
.waist-guide-content { display: grid; gap: 18px; align-items: center; }
.waist-guide img { display: block; width: 100%; max-width: 320px; height: auto; margin: 16px auto 0; }
.waist-guide ol { margin: 8px 0; padding-left: 22px; }
.waist-guide li { padding: 4px 0; }
.bmi-card { margin: 24px 0; }
.bmi-value { color: var(--navy); font-size: 36px; font-weight: 800; margin: 12px 0; }
.bmi-value small { font-size: 16px; }
@media (min-width: 600px) { .waist-guide-content { grid-template-columns: minmax(160px, 1fr) 1.2fr; } }

.invitation-panel { margin: 20px 0; border-left: 4px solid var(--navy); }
.invitation-panel summary { cursor: pointer; font-weight: 750; min-height: 44px; color: var(--navy); }
.invitation-panel form { margin-top: 16px; }
.invitation-confirm { display: flex; align-items: flex-start; gap: 12px; padding: 14px; border-radius: 10px; background: #edf5fc; }
.invitation-confirm input { width: 22px; min-width: 22px; height: 22px; margin-top: 3px; }
.invitation-cancel { margin-top: 18px; }

@media (max-width: 480px) {
  .brand-logo { width: 126px; }
  .app-page .app-header nav { flex-wrap: wrap; justify-content: flex-end; gap: 8px; font-size: 12px; }
}
@media (max-width: 350px) {
  .brand-logo { width: 106px; }
}

/* Logo oficial también en la ficha, visible en celular. */
.hero-brand { flex: 0 0 220px; margin-left: 24px; padding: 14px; border-radius: 16px; background: #fff; }
.hero-brand img { display: block; width: 100%; height: auto; }
.modification-log { display: block; color: #374b63; font-size: 12px; max-width: 190px; }
@media (max-width: 640px) {
  .journey-hero { flex-wrap: wrap; }
  .hero-brand { flex: 0 0 140px; margin: 18px 0 0; padding: 10px; }
}

.measurements-card td:first-child { min-width: 160px; }
.measurements-card td > strong { white-space: nowrap; }
.modification-log { line-height: 1.4; }
