:root {
  --ink: #173641;
  --muted: #6f8187;
  --brand: #244b5a;
  --brand-dark: #173844;
  --coral: #d47b62;
  --coral-soft: #f6e4dd;
  --mint: #dcece6;
  --sand: #f2e7d1;
  --blue-soft: #dce9ee;
  --surface: #ffffff;
  --background: #f5f7f4;
  --line: #e2e8e5;
  --shadow: 0 18px 45px rgba(35, 70, 78, 0.08);
  --radius: 20px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--background);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.activity-open { overflow: hidden; }
body.auth-pending, body.auth-open { overflow-x: hidden; overflow-y: auto; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.auth-gate {
  display: grid;
  min-height: 100vh;
  min-height: 100dvh;
  grid-template-columns: minmax(360px, .9fr) minmax(480px, 1.1fr);
  background: #f7f8f5;
}
.auth-gate[hidden] { display: none; }
.auth-showcase {
  position: relative;
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(35px, 5vw, 72px);
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 15% 18%, rgba(230,178,156,.25), transparent 25%),
    radial-gradient(circle at 88% 78%, rgba(151,193,178,.2), transparent 28%),
    linear-gradient(145deg, #173844, #244f5d 58%, #183d49);
}
.auth-showcase::before, .auth-showcase::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 42% 58% 55% 45%;
}
.auth-showcase::before {
  width: 330px;
  height: 330px;
  right: -120px;
  top: 18%;
  transform: rotate(20deg);
}
.auth-showcase::after { width: 220px; height: 220px; left: -80px; bottom: 12%; transform: rotate(-18deg); }
.auth-brand { position: relative; z-index: 1; display: flex; align-items: center; gap: 13px; }
.auth-brand strong { display: block; font-family: Georgia, serif; font-size: 27px; font-weight: 500; }
.auth-brand small { color: #a8c6cb; font-size: 10px; letter-spacing: 1.4px; text-transform: uppercase; }
.auth-message { position: relative; z-index: 1; max-width: 590px; padding: 50px 0; }
.auth-message .eyebrow { color: #e9b39f; }
.auth-message h1 { max-width: 580px; margin: 16px 0 20px; font-size: clamp(42px, 5vw, 68px); line-height: 1.02; }
.auth-message p { max-width: 530px; color: #c5d7da; font-size: 16px; line-height: 1.75; }
.auth-about {
  display: grid;
  max-width: 560px;
  gap: 8px;
  margin-top: 22px;
  padding: 18px 20px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 20px;
  background: rgba(255,255,255,.08);
  box-shadow: 0 18px 45px rgba(9,34,42,.16);
  backdrop-filter: blur(10px);
}
.auth-about strong { color: #fff; font-family: Georgia, serif; font-size: 20px; font-weight: 500; }
.auth-about span { color: #d6e4e6; font-size: 13px; line-height: 1.65; }
.auth-features { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 30px; }
.auth-public-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.light-button {
  min-height: 44px;
  color: var(--brand-dark);
  border-color: #fff;
  background: #fff;
  box-shadow: 0 5px 0 #c8d7d5, 0 16px 30px rgba(0,0,0,.18);
}
.outline-light-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 12px;
  background: rgba(255,255,255,.08);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.outline-light-button:hover { border-color: rgba(255,255,255,.72); background: rgba(255,255,255,.14); transform: translateY(-2px); }
.auth-feature {
  position: relative;
  padding: 9px 12px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 30px;
  background: rgba(255,255,255,.06);
  font: inherit;
  font-size: 10px;
  font-weight: 700;
  cursor: help;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.auth-feature:hover, .auth-feature:focus, .auth-feature:focus-visible {
  z-index: 3;
  border-color: rgba(255,255,255,.42);
  background: rgba(255,255,255,.13);
  transform: translateY(-2px);
  outline: none;
}
.auth-feature-tip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 13px);
  width: 245px;
  padding: 13px 15px;
  color: #294d58;
  border: 1px solid rgba(255,255,255,.7);
  border-radius: 13px;
  background: rgba(255,255,255,.97);
  box-shadow: 0 16px 35px rgba(10,34,42,.24);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, 8px);
  visibility: hidden;
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}
.auth-feature-tip::after {
  position: absolute;
  top: 100%;
  left: 50%;
  width: 12px;
  height: 12px;
  background: #fff;
  content: "";
  transform: translate(-50%, -6px) rotate(45deg);
}
.auth-notice a, .consent-check a, .creator-footer a {
  color: var(--coral);
  font-weight: 800;
  text-decoration: none;
}
.auth-notice a:hover, .consent-check a:hover, .creator-footer a:hover { text-decoration: underline; }
.legal-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 12%, rgba(212,123,98,.16), transparent 24%),
    radial-gradient(circle at 88% 18%, rgba(151,193,178,.18), transparent 26%),
    var(--background);
}
.legal-shell {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0 70px;
}
.legal-back {
  display: inline-flex;
  margin-bottom: 18px;
  padding: 10px 14px;
  color: var(--brand);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  box-shadow: var(--shadow);
}
.legal-card {
  padding: clamp(26px, 5vw, 54px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  box-shadow: var(--shadow);
}
.legal-card h1 {
  margin: 8px 0 10px;
  font-size: clamp(34px, 6vw, 58px);
}
.legal-card h2 {
  margin: 30px 0 10px;
  color: var(--brand);
  font-family: Georgia, serif;
  font-size: 23px;
}
.legal-card p {
  color: #536b72;
  font-size: 15px;
  line-height: 1.8;
}
.legal-card ul {
  margin: 12px 0 18px;
  padding-left: 22px;
  color: #536b72;
  font-size: 15px;
  line-height: 1.8;
}
.legal-card li + li { margin-top: 6px; }
.auth-feature:hover .auth-feature-tip, .auth-feature:focus .auth-feature-tip, .auth-feature:focus-visible .auth-feature-tip {
  opacity: 1;
  transform: translate(-50%, 0);
  visibility: visible;
}
.auth-feature:first-child .auth-feature-tip {
  left: 0;
  transform: translate(0, 8px);
}
.auth-feature:first-child:hover .auth-feature-tip,
.auth-feature:first-child:focus .auth-feature-tip,
.auth-feature:first-child:focus-visible .auth-feature-tip {
  transform: translate(0, 0);
}
.auth-feature:first-child .auth-feature-tip::after { left: 22%; }
.auth-feature:last-child .auth-feature-tip {
  right: 0;
  left: auto;
  transform: translate(0, 8px);
}
.auth-feature:last-child:hover .auth-feature-tip,
.auth-feature:last-child:focus .auth-feature-tip,
.auth-feature:last-child:focus-visible .auth-feature-tip {
  transform: translate(0, 0);
}
.auth-feature:last-child .auth-feature-tip::after { left: 78%; }
.auth-credit { position: relative; z-index: 1; color: #9fb8bd; }
.auth-credit strong { color: #fff; }
.auth-panel { display: grid; min-height: 100vh; min-height: 100dvh; place-items: center; padding: 35px; }
.auth-card { width: min(460px, 100%); margin: 30px 0; }
.environment-badge { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 28px; padding: 8px 11px; color: #58756d; border-radius: 30px; background: #e5efea; font-size: 10px; font-weight: 800; letter-spacing: .4px; text-transform: uppercase; }
.environment-badge span { width: 7px; height: 7px; border-radius: 50%; background: #75a28f; box-shadow: 0 0 0 4px rgba(117,162,143,.14); }
.environment-badge.online { color: #315f55; background: #dceee6; }
.environment-badge.online span { background: #4e9179; box-shadow: 0 0 0 4px rgba(78,145,121,.16); }
.auth-heading h2 { margin: 7px 0; font-size: 36px; }
.auth-heading p { color: var(--muted); font-size: 13px; }
.auth-pricing-note {
  display: grid;
  gap: 3px;
  margin: 22px 0 0;
  padding: 15px 16px;
  border: 1px solid #dbe7e1;
  border-radius: 16px;
  background: linear-gradient(135deg, #f7fbf8, #fff7f2);
}
.auth-pricing-note span {
  color: var(--coral);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.auth-pricing-note strong { color: var(--ink); font-family: Georgia, serif; font-size: 24px; }
.auth-pricing-note small { color: var(--muted); font-size: 11px; line-height: 1.45; }
.auth-session-alert {
  margin: 15px 0 0;
  padding: 12px 14px;
  color: #7a463c;
  border: 1px solid #edc8bc;
  border-radius: 13px;
  background: #fff1ec;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.5;
}
.auth-session-alert[hidden] { display: none; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin: 28px 0 24px; padding: 5px; border-radius: 13px; background: #e9eeeb; }
.auth-tabs button { min-height: 40px; color: #748582; border: 0; border-radius: 9px; background: transparent; font-size: 12px; font-weight: 800; }
.auth-tabs button.active { color: var(--brand); background: #fff; box-shadow: 0 5px 18px rgba(35,70,78,.09); }
.auth-form { display: grid; gap: 16px; }
.auth-form[hidden], .recovery-panel[hidden] { display: none; }
.auth-form label { display: grid; gap: 7px; color: #4d6463; font-size: 11px; font-weight: 800; }
.auth-form input, .auth-form select { min-height: 48px; background: #fff; }
.password-field { position: relative; display: block; }
.password-field input { padding-right: 75px; }
.password-toggle { position: absolute; top: 50%; right: 12px; padding: 5px; color: var(--coral); border: 0; background: transparent; transform: translateY(-50%); font-size: 10px; font-weight: 800; }
.password-requirements { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px 10px; margin-top: -7px; }
.password-requirements span { position: relative; padding-left: 18px; color: #849390; font-size: 9px; line-height: 1.4; }
.password-requirements span::before { position: absolute; left: 0; top: 1px; display: grid; width: 12px; height: 12px; place-items: center; content: "•"; color: #9aaba7; border: 1px solid #ccd7d3; border-radius: 50%; font-size: 8px; }
.password-requirements span.valid { color: #4f796b; }
.password-requirements span.valid::before { content: "✓"; color: #fff; border-color: #6c9a89; background: #6c9a89; }
.password-requirements span.invalid { color: #a75b52; }
.password-requirements span.invalid::before { content: "!"; color: #fff; border-color: #bd7568; background: #bd7568; }
.forgot-password { justify-self: end; margin-top: -6px; }
.auth-submit { width: 100%; min-height: 48px; margin-top: 3px; }
.consent-check { display: flex !important; grid-template-columns: auto 1fr; align-items: flex-start; gap: 10px !important; color: var(--muted) !important; font-weight: 500 !important; line-height: 1.5; }
.consent-check input { width: 17px; min-height: 17px; margin: 2px 0 0; accent-color: var(--brand); }
.patient-consent { margin-top: 8px; padding: 13px 14px; border: 1px solid var(--line); border-radius: 14px; background: #f8fbf8; }
.auth-notice { margin: 24px 0 0; padding: 13px 15px; color: #6c7e7b; border-left: 3px solid #d79a84; border-radius: 0 10px 10px 0; background: #f5ede8; font-size: 10px; line-height: 1.55; }
.recovery-panel h3 { margin: 18px 0 6px; font-family: Georgia, serif; font-size: 28px; }
.recovery-panel > p { margin-bottom: 20px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.auth-back { margin-bottom: 5px; }

.app-shell { display: flex; min-height: 100vh; }
.app-shell[hidden] { display: none; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 20;
  display: flex;
  width: 260px;
  flex-direction: column;
  padding: 28px 22px 20px;
  overflow-y: auto;
  color: #fff;
  background: var(--brand-dark);
}
.brand { display: flex; align-items: center; gap: 12px; padding: 0 6px 34px; }
.brand strong { display: block; font-family: Georgia, serif; font-size: 23px; font-weight: 500; letter-spacing: .2px; }
.brand small { color: #a8c0c6; font-size: 11px; letter-spacing: 1.2px; text-transform: uppercase; }
.brand-mark { position: relative; display: flex; width: 34px; height: 34px; align-items: center; justify-content: center; }
.brand-mark span { position: absolute; width: 18px; height: 18px; border: 2px solid #e7b29f; border-radius: 50% 50% 45% 55%; }
.brand-mark span:nth-child(1) { transform: translate(-6px, 1px); }
.brand-mark span:nth-child(2) { transform: translate(6px, 1px); }
.brand-mark span:nth-child(3) { transform: translateY(-6px); }
.brand-mark.small { width: 26px; height: 26px; transform: scale(.8); }

.main-nav { display: grid; gap: 6px; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  padding: 13px 14px;
  color: #b9cdd1;
  border: 0;
  border-radius: 12px;
  background: transparent;
  text-align: left;
  transition: .2s ease;
}
.nav-item:hover, .nav-item.active { color: #fff; background: rgba(255,255,255,.09); }
.nav-item.active { box-shadow: inset 3px 0 var(--coral); }
.nav-icon { width: 20px; font-size: 19px; text-align: center; }
.sidebar-card {
  margin-top: 24px;
  padding: 18px;
  color: var(--ink);
  border-radius: 16px;
  background: #e9f0ec;
}
.sidebar-card .eyebrow { color: #718f88; }
.sidebar-card strong { display: block; margin: 7px 0; }
.sidebar-card p { margin: 0 0 10px; color: #6f7c79; font-size: 12px; line-height: 1.5; }
.profile { display: flex; align-items: center; gap: 10px; margin-top: auto; padding: 18px 5px 0; border-top: 1px solid rgba(255,255,255,.1); }
.profile > div:not(.avatar):not(.profile-actions) { min-width: 0; }
.profile strong, .profile small { display: block; }
.profile strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.profile small { margin-top: 3px; color: #9cb2b7; font-size: 10px; }
.profile .icon-button { margin-left: auto; color: #9cb2b7; }
.profile-actions { display: grid; justify-items: end; margin-left: auto; }
.profile-actions .icon-button { width: 30px; height: 25px; }
.profile-logout { padding: 2px 0; color: #e7b29f; border: 0; background: transparent; font-size: 9px; font-weight: 800; }
.avatar, .patient-avatar {
  display: grid;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  place-items: center;
  color: var(--ink);
  border-radius: 50%;
  background: #e4b29f;
  font-size: 12px;
  font-weight: 700;
}

.main-content { width: calc(100% - 260px); margin-left: 260px; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  height: 76px;
  align-items: center;
  justify-content: space-between;
  padding: 0 4vw;
  border-bottom: 1px solid var(--line);
  background: rgba(245,247,244,.92);
  backdrop-filter: blur(16px);
}
.topbar-title strong { display: block; margin-top: 3px; font-family: Georgia, serif; font-size: 20px; font-weight: 500; }
.top-actions { display: flex; align-items: center; gap: 12px; }
.sync-status { display: inline-flex; min-height: 30px; align-items: center; gap: 7px; padding: 0 11px; color: #5c716d; border: 1px solid #d5dfdc; border-radius: 999px; background: #fff; font-size: 10px; font-weight: 800; white-space: nowrap; }
.sync-status::before { width: 7px; height: 7px; border-radius: 50%; background: #9aa8a5; content: ""; }
.sync-status.online { color: #376a59; background: #e8f3ee; border-color: #cfe4d8; }
.sync-status.online::before { background: #57a17d; box-shadow: 0 0 0 4px rgba(87,161,125,.14); }
.sync-status.saving { color: #816234; background: #fff6e5; border-color: #efd7a9; }
.sync-status.saving::before { background: #d6a64f; animation: syncPulse 1s ease-in-out infinite; }
.sync-status.error { color: #9a4b42; background: #fff0ed; border-color: #e7b7af; }
.sync-status.error::before { background: #c76559; }
.sync-status.local { color: #64716f; background: #f7faf8; }
@keyframes syncPulse { 50% { opacity: .35; transform: scale(.72); } }
.page-navigation { display: flex; gap: 7px; margin-right: 12px; }
.page-navigation[hidden] { display: none; }
.nav-control { min-height: 35px; padding: 0 11px; color: var(--brand); border: 1px solid #d5dfdc; border-radius: 10px; background: #fff; font-size: 10px; font-weight: 800; }
.icon-button, .menu-button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: transparent;
}
.notification { position: relative; color: var(--coral); border: 1px solid var(--line); background: #fff; font-size: 11px; }
.notification::after { position: absolute; top: 4px; right: 4px; width: 7px; height: 7px; border: 2px solid #fff; border-radius: 50%; background: #d47b62; content: ""; }
.notification-panel { position: absolute; top: 65px; right: 4vw; z-index: 30; width: min(340px, calc(100vw - 30px)); padding: 12px; border: 1px solid var(--line); border-radius: 17px; background: #fff; box-shadow: 0 24px 60px rgba(23,54,65,.2); }
.notification-panel[hidden] { display: none; }
.compact-help-button { min-height: 34px; padding: 0 14px; font-size: 11px; }
.notification-heading { display: flex; align-items: center; justify-content: space-between; padding: 5px 6px 10px; }
.notification-heading strong { font-family: Georgia, serif; font-size: 18px; }
.notification-heading button { border: 0; background: transparent; font-size: 20px; }
.notification-item { display: block; width: 100%; padding: 13px; color: var(--ink); border: 0; border-top: 1px solid #edf1ef; background: transparent; text-align: left; }
.notification-item:hover { border-radius: 10px; background: #f2f6f3; }
.notification-item strong, .notification-item span { display: block; }
.notification-item strong { font-size: 11px; }.notification-item span { margin-top: 4px; color: var(--muted); font-size: 9px; }
.menu-button { display: none; color: var(--ink); font-size: 20px; }
.view { display: none; padding: 42px 4vw 64px; animation: fadeIn .25s ease; }
.view.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } }

.eyebrow { color: #839295; font-size: 10px; font-weight: 800; letter-spacing: 1.5px; }
h1, h2, h3, p { margin-top: 0; }
h1, h2 { font-family: Georgia, "Times New Roman", serif; font-weight: 500; }
h1 { margin-bottom: 9px; font-size: clamp(30px, 3.2vw, 46px); line-height: 1.06; }
h2 { margin-bottom: 5px; font-size: 24px; }
h3 { font-size: 14px; }
.subtitle { color: var(--muted); line-height: 1.6; }
.welcome-row, .section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 25px; margin-bottom: 32px; }
.welcome-kicker { margin-bottom: 8px; color: var(--coral); font-size: 14px; font-weight: 700; }

.primary-button, .secondary-button, .small-button {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 11px;
  font-weight: 700;
  transition: transform .15s ease, box-shadow .15s ease;
}
.primary-button {
  color: #fff;
  border: 1px solid #173d4b;
  background: linear-gradient(180deg, #315f6f, #1e4655);
  box-shadow: 0 5px 0 #123440, 0 12px 24px rgba(36,75,90,.18);
}
.secondary-button { color: var(--brand); border: 1px solid #cbd7d7; background: #fff; }
.small-button { min-height: 34px; padding: 0 13px; color: var(--brand); border: 1px solid #ccd8d7; background: #fff; font-size: 12px; }
.primary-button:hover, .secondary-button:hover, .small-button:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(34,63,70,.14); }
.primary-button:active { transform: translateY(3px); box-shadow: 0 2px 0 #123440, 0 5px 12px rgba(36,75,90,.12); }
.primary-button:disabled { cursor: not-allowed; opacity: .45; transform: none; box-shadow: none; }
.text-button { padding: 0; color: var(--coral); border: 0; background: transparent; font-size: 12px; font-weight: 800; }
.full { width: 100%; }

.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 22px; }
.metric-card { display: flex; width: 100%; align-items: center; gap: 17px; padding: 23px; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 10px 35px rgba(35,70,78,.04); text-align: left; }
.metric-link { transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.metric-link:hover, .metric-link:focus-visible { transform: translateY(-4px); border-color: #bfd1cc; box-shadow: 0 18px 38px rgba(35,70,78,.11); }
.metric-icon { display: grid; width: 49px; height: 49px; place-items: center; border-radius: 15px; font-family: Georgia, serif; font-size: 19px; }
.mint { background: var(--mint); }.sand { background: var(--sand); }.blue { background: var(--blue-soft); }.lavender { background: #e9e3f1; }
.metric-card span, .metric-card small, .metric-card strong { display: block; }
.metric-card span { color: var(--muted); font-size: 12px; }
.metric-card strong { margin: 3px 0 2px; font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.metric-card small { color: #94a0a2; font-size: 10px; }
.metric-card .positive { color: #648f7e; }

.dashboard-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 22px; }
.dashboard-agenda { margin-top: 22px; padding: 25px; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 12px 40px rgba(35,70,78,.045); }
.schedule-panel, .progress-panel { padding: 25px; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; margin-bottom: 18px; }
.panel-heading h2 { margin-top: 5px; }
.quick-start-panel { margin-bottom: 22px; padding: 25px; background: linear-gradient(135deg, #fff 0%, #f7fbf8 100%); }
.quick-start-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; }
.quick-step { display: grid; gap: 9px; min-height: 145px; padding: 18px; color: var(--ink); border: 1px solid var(--line); border-radius: 17px; background: rgba(255,255,255,.86); text-align: left; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.quick-step:hover, .quick-step:focus-visible { transform: translateY(-3px); border-color: #bed2cc; box-shadow: 0 18px 36px rgba(35,70,78,.1); }
.quick-step-number { display: grid; width: 34px; height: 34px; place-items: center; color: #fff; border-radius: 12px; background: var(--brand); font-weight: 900; }
.quick-step strong { font-family: Georgia, serif; font-size: 18px; }
.quick-step small { color: var(--muted); font-size: 11px; line-height: 1.45; }
.quick-step.done { border-color: #c9ded3; background: #f4faf6; }
.quick-step.done .quick-step-number { background: #75a28f; }
select, input, textarea {
  width: 100%;
  color: var(--ink);
  border: 1px solid #d7e0dd;
  border-radius: 10px;
  outline: none;
  background: #fbfcfb;
}
select, input { height: 43px; padding: 0 12px; }
textarea { padding: 12px; resize: vertical; line-height: 1.55; }
select:focus, input:focus, textarea:focus { border-color: #7fa0a5; box-shadow: 0 0 0 3px rgba(80,128,136,.1); }
.panel-heading select { width: auto; height: 34px; font-size: 11px; }
.session-item { display: flex; align-items: center; gap: 13px; padding: 15px 0; border-top: 1px solid #edf0ee; }
.session-empty { padding: 42px 12px; color: var(--muted); text-align: center; font-size: 11px; line-height: 1.6; }
.time { width: 52px; }
.time strong, .time span, .session-info strong, .session-info span { display: block; }
.time strong { font-size: 13px; }.time span { margin-top: 3px; color: #9aa5a6; font-size: 9px; }
.patient-avatar.coral { background: #f2d8ce; }.patient-avatar.lavender { background: #e2deef; }.patient-avatar.green { background: #d9e9df; }
.session-info { min-width: 0; flex: 1; }
.session-info strong { font-size: 13px; }.session-info span { overflow: hidden; margin-top: 4px; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.status-badge, .gentle-tag { padding: 6px 9px; color: #9c624f; border-radius: 20px; background: var(--coral-soft); font-size: 9px; font-weight: 800; }

.progress-summary { display: flex; align-items: center; gap: 20px; padding: 9px 0 22px; }
.progress-ring {
  display: grid;
  flex: 0 0 auto;
  width: 105px;
  height: 105px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--coral) calc(var(--value) * 1%), #edf1ef 0);
}
.progress-ring::before { position: absolute; width: 82px; height: 82px; border-radius: 50%; background: #fff; content: ""; }
.progress-ring div { position: relative; z-index: 1; text-align: center; }
.progress-ring strong, .progress-ring span { display: block; }
.progress-ring strong { font-family: Georgia, serif; font-size: 22px; }.progress-ring span { color: var(--muted); font-size: 9px; }
.progress-notes strong { font-size: 13px; }.progress-notes p { margin: 5px 0 10px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.skill-bars { display: grid; gap: 13px; }
.skill-bars span { display: flex; justify-content: space-between; margin-bottom: 6px; font-size: 10px; }
.skill-bars small { color: var(--muted); }
.skill-bars i, .support-row i { display: block; height: 5px; overflow: hidden; border-radius: 10px; background: #edf1ef; }
.skill-bars em, .support-row em { display: block; height: 100%; border-radius: inherit; background: #86a99c; }

.activity-highlight { display: flex; min-height: 240px; overflow: hidden; margin-top: 22px; }
.highlight-copy { width: 58%; padding: 32px; }
.highlight-copy h2 { margin-top: 8px; font-size: 30px; }
.highlight-copy p { max-width: 570px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.tag-row, .report-tags { display: flex; flex-wrap: wrap; gap: 7px; margin: 18px 0; }
.tag-row span, .report-tags span { padding: 7px 10px; color: #668079; border-radius: 20px; background: #edf3ef; font-size: 9px; font-weight: 700; }
.activity-art { position: relative; display: flex; width: 42%; align-items: center; justify-content: center; gap: 10px; overflow: hidden; background: #dfeae5; }
.activity-art::before, .activity-art::after { position: absolute; width: 190px; height: 190px; border: 1px solid rgba(58,100,96,.14); border-radius: 50%; content: ""; }
.activity-art::after { width: 280px; height: 280px; }
.art-card { z-index: 1; display: grid; width: 82px; height: 105px; place-items: center; color: #fff; border-radius: 14px; background: var(--coral); box-shadow: 0 15px 28px rgba(48,82,83,.15); font-family: Georgia, serif; font-size: 25px; transform: rotate(-6deg); }
.art-card span { font-family: sans-serif; font-size: 9px; text-transform: uppercase; }
.art-card.two { background: #718f8b; transform: translateY(-12px) rotate(2deg); }
.art-card.three { background: #dbab78; transform: rotate(7deg); }
.premium-hero { position: relative; min-height: 310px; color: #fff; border: 0; background: var(--brand-dark); box-shadow: 0 24px 60px rgba(19,54,65,.18); }
.premium-hero .highlight-copy { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: 42px; }
.premium-hero .eyebrow { color: #a8c8c7; }
.premium-hero h2 { max-width: 610px; font-size: clamp(27px, 3vw, 40px); line-height: 1.1; }
.premium-hero p { color: #c6d5d6; }
.premium-hero .tag-row span { color: #d8e7e4; background: rgba(255,255,255,.1); }
.premium-hero .primary-button { color: var(--brand-dark); border-color: #fff; background: #fff; box-shadow: 0 5px 0 #c8d7d5, 0 12px 24px rgba(0,0,0,.18); }
.hero-image {
  position: relative;
  width: 48%;
  min-height: 310px;
  overflow: hidden;
  background: linear-gradient(90deg, var(--brand-dark) 0%, transparent 35%), url("assets/images/hero-cognition.png") center/cover no-repeat;
  transition: transform .7s cubic-bezier(.2,.8,.2,1), filter .4s ease;
}
.hero-image::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--brand-dark) 0%, transparent 35%), url("assets/images/hero-progress.png") center/cover no-repeat;
  content: "";
  animation: heroCrossfade 12s ease-in-out infinite alternate;
}
@keyframes heroCrossfade {
  0%, 35% { opacity: 0; transform: scale(1.035); }
  65%, 100% { opacity: 1; transform: scale(1); }
}
.premium-hero:hover .hero-image { transform: scale(1.025); filter: saturate(1.05); }

.toolbar { display: flex; gap: 12px; margin-bottom: 20px; }
.toolbar input { max-width: 400px; }.toolbar select { width: 190px; }
.patient-grid, .activity-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.patient-card, .activity-card { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: 0 10px 30px rgba(35,70,78,.04); }
.patient-card.paused { opacity: .72; background: #fafbfa; }
.patient-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.patient-card-head div:nth-child(2) { flex: 1; }
.patient-card h3, .activity-card h3 { margin: 0 0 4px; font-family: Georgia, serif; font-size: 18px; }
.patient-card p, .activity-card p { margin-bottom: 16px; color: var(--muted); font-size: 11px; line-height: 1.6; }
.patient-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.patient-meta span { color: var(--muted); font-size: 10px; }.patient-meta strong { display: block; margin-top: 3px; font-size: 12px; }
.card-actions { display: flex; justify-content: space-between; margin-top: 15px; }
.patient-menu { display: flex; gap: 5px; }
.patient-menu button { height: 34px; }
.patient-menu .edit-patient { width: auto; min-width: 64px; padding: 0 13px; }
.patient-menu .delete-patient { flex: 0 0 34px; width: 34px; border: 1px solid #d7e0dd; background: #fff; }
.patient-record { color: #557a73; }
.card-actions { flex-wrap: wrap; gap: 12px; }
.status-pill { padding: 5px 8px; color: #52776b; border-radius: 20px; background: #e3efe9; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.status-pill.paused { color: #806d58; background: #efe8dc; }
.empty-state { padding: 55px 20px; color: var(--muted); border: 1px dashed #cfdad6; border-radius: var(--radius); text-align: center; }
.empty-state strong { display: block; color: var(--ink); font-family: Georgia, serif; font-size: 20px; }
.empty-state p { margin: 8px 0 0; font-size: 12px; }
.activity-visual { display: grid; height: 135px; margin: -8px -8px 20px; place-items: center; overflow: hidden; border-radius: 15px; background: #e6efeb; }
.activity-visual span { display: grid; width: 68px; height: 68px; place-items: center; color: #fff; border-radius: 18px; background: var(--coral); font-family: Georgia, serif; font-size: 28px; transform: rotate(-4deg); box-shadow: 14px 12px 0 rgba(101,143,136,.26); }
.activity-card:nth-child(2n) .activity-visual { background: #f1e7d8; }.activity-card:nth-child(3n) .activity-visual { background: #e8e4ee; }
.activity-card { transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease, border-color .3s ease; }
.activity-card:hover { transform: translateY(-7px); border-color: #c7d7d3; box-shadow: 0 22px 45px rgba(35,70,78,.12); }
.activity-card .activity-visual span { transition: transform .35s cubic-bezier(.2,.8,.2,1); }
.activity-card:hover .activity-visual span { transform: translateY(-5px) rotate(2deg) scale(1.05); }
.activity-card { position: relative; }
.favorite-toggle { position: absolute; top: 12px; right: 12px; z-index: 2; display: grid; width: 36px; height: 36px; place-items: center; color: #879895; border: 1px solid rgba(255,255,255,.8); border-radius: 50%; background: rgba(255,255,255,.92); box-shadow: 0 6px 16px rgba(35,70,78,.1); font-size: 19px; }
.favorite-toggle.active { color: #d47b62; background: #fff4ef; }
.filter-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.filter { padding: 9px 14px; color: var(--muted); border: 1px solid var(--line); border-radius: 20px; background: #fff; font-size: 11px; font-weight: 700; }
.filter.active { color: #fff; border-color: var(--brand); background: var(--brand); }

.report-layout { display: grid; grid-template-columns: minmax(400px, .8fr) minmax(460px, 1.2fr); gap: 24px; align-items: start; }
.report-form { padding: 27px; }
.form-section { display: flex; gap: 13px; margin: 5px 0 20px; }
.form-section:not(:first-child) { margin-top: 30px; padding-top: 25px; border-top: 1px solid var(--line); }
.form-section h2 { margin: 0; font-size: 20px; }
.form-section p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.step-number { display: grid; flex: 0 0 auto; width: 28px; height: 28px; place-items: center; color: #fff; border-radius: 50%; background: var(--coral); font-size: 11px; font-weight: 800; }
label { display: block; margin-bottom: 16px; color: #536a70; font-size: 11px; font-weight: 800; }
label input, label select, label textarea { margin-top: 7px; font-weight: 400; }
.two-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.toggle-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 22px 0; padding: 16px; border: 1px solid var(--line); border-radius: 13px; background: #f8faf8; }
.toggle-row strong, .toggle-row small { display: block; }.toggle-row small { margin-top: 4px; color: var(--muted); font-weight: 400; }
.toggle-row input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.toggle-row i { position: relative; flex: 0 0 auto; width: 42px; height: 24px; border-radius: 20px; background: #cdd7d4; transition: .2s; }
.toggle-row i::after { position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; content: ""; transition: .2s; }
.toggle-row input:checked + i { background: var(--brand); }.toggle-row input:checked + i::after { transform: translateX(18px); }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; }
.report-data-summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 22px; padding: 13px 14px; color: #667b76; border-radius: 11px; background: #edf4f0; font-size: 9px; }
.report-data-summary strong { color: var(--ink); font-size: 11px; }

.report-preview { padding: 42px; color: #314a51; border: 1px solid #dfe5e2; border-radius: 6px; background: #fff; box-shadow: var(--shadow); }
.saved-reports-panel { margin-top: 24px; padding: 27px; }
.saved-reports-panel .panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.saved-reports-panel select { min-width: 220px; }
.saved-report-list { display: grid; gap: 12px; margin-top: 20px; }
.saved-report-card { display: flex; gap: 20px; align-items: center; justify-content: space-between; padding: 17px 18px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.saved-report-main { display: grid; gap: 5px; }
.saved-report-main strong { color: var(--ink); font-size: 15px; }
.saved-report-main small { color: var(--muted); line-height: 1.5; }
.report-status { width: max-content; padding: 4px 8px; border-radius: 999px; color: #85633d; background: #f5ead8; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.report-status.final { color: #326654; background: #e2f0e9; }
.saved-report-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.billing-hero { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 24px; padding: 28px; }
.billing-hero h2 { margin: 7px 0; font-size: 30px; }
.billing-hero p { margin: 0; color: var(--muted); line-height: 1.6; }
.billing-status-card { min-width: 210px; padding: 18px; border: 1px solid #d9e4df; border-radius: 18px; background: #f6faf8; }
.billing-status-card span, .billing-status-card small { display: block; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; }
.billing-status-card strong { display: block; margin: 8px 0 5px; color: var(--brand); font-family: Georgia, serif; font-size: 22px; }
.pricing-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin-bottom: 24px; }
.pricing-card { position: relative; display: grid; gap: 16px; padding: 28px; border: 1px solid var(--line); border-radius: 24px; background: #fff; box-shadow: 0 16px 42px rgba(35,70,78,.06); }
.pricing-card.featured { border-color: #d69a84; box-shadow: 0 24px 60px rgba(150,88,67,.13); }
.pricing-card.selected::after { position: absolute; top: 16px; right: 16px; padding: 6px 9px; content: "Selecionado"; color: #fff; border-radius: 999px; background: var(--brand); font-size: 9px; font-weight: 900; letter-spacing: .6px; text-transform: uppercase; }
.pricing-card h2 { margin: 0; color: var(--ink); font-size: 38px; }
.pricing-card p { margin: 0; color: var(--muted); line-height: 1.6; }
.pricing-card ul { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.pricing-card li { position: relative; padding-left: 20px; color: #516563; font-size: 12px; line-height: 1.45; }
.pricing-card li::before { position: absolute; left: 0; top: 2px; content: "✓"; color: #6f9a86; font-weight: 900; }
.payment-placeholder { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 26px; }
.payment-placeholder p { margin: 5px 0 0; color: var(--muted); line-height: 1.6; }
.payment-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.billing-guidance { margin-top: 18px; padding: 24px 26px; border-color: #dce8e2; background: linear-gradient(135deg, #fff, #f7fbf8); }
.billing-guidance h2 { margin: 6px 0 8px; font-size: 24px; }
.billing-guidance p { max-width: 760px; margin: 0; color: var(--muted); line-height: 1.65; }
.billing-guidance-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.billing-guidance-actions:empty { display: none; }
.launch-checklist { margin-top: 24px; padding: 26px; }
.launch-progress { padding: 7px 10px; color: #52776b; border-radius: 999px; background: #e4f0ea; font-size: 10px; font-weight: 900; letter-spacing: .8px; text-transform: uppercase; }
.launch-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.launch-item { display: grid; grid-template-columns: 34px 1fr; gap: 12px; padding: 15px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.launch-item > span { display: grid; place-items: center; width: 28px; height: 28px; color: #8b6845; border-radius: 50%; background: #f5eadc; font-size: 13px; font-weight: 900; }
.launch-item.done > span { color: #376a59; background: #e2f0e9; }
.launch-item strong { display: block; color: var(--ink); font-size: 12px; }
.launch-item p { margin: 5px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.report-brand { display: flex; align-items: center; gap: 8px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.report-brand strong, .report-brand span { display: block; }.report-brand strong { font-family: Georgia, serif; font-size: 15px; }.report-brand span { margin-top: 3px; color: #94a0a0; font-size: 8px; text-transform: uppercase; }
.report-title { padding: 28px 0 18px; }
.report-title > span { color: var(--coral); font-size: 9px; font-weight: 800; letter-spacing: .8px; }
.report-title h2 { margin: 7px 0 8px; font-size: 30px; }
.report-title p, .report-section p { color: #718085; font-size: 10px; line-height: 1.65; }
.report-section { padding: 14px 0; }
.report-section h3, .mini-chart h3, .support-chart h3 { margin-bottom: 9px; font-family: Georgia, serif; font-size: 14px; }
.report-tags { margin: 0; }
.report-charts { display: grid; grid-template-columns: 1.1fr .9fr; gap: 14px; margin: 14px 0; }
.mini-chart, .support-chart { padding: 16px; border: 1px solid var(--line); border-radius: 12px; }
.line-chart { position: relative; height: 100px; overflow: hidden; }
.line-chart svg { position: absolute; inset: 5px 0 15px; width: 100%; height: 75px; }
.grid-line { position: absolute; right: 0; left: 0; height: 1px; background: #edf0ee; }.grid-line.a { top: 18px; }.grid-line.b { top: 48px; }.grid-line.c { top: 78px; }
.chart-labels { position: absolute; right: 0; bottom: 0; left: 0; display: flex; justify-content: space-between; color: #9ca5a5; font-size: 7px; }
.support-chart { display: flex; flex-direction: column; }
.support-row { display: grid; grid-template-columns: 35px 1fr 52px; gap: 7px; align-items: center; margin: 9px 0; font-size: 8px; }
.support-row i { height: 6px; }.support-row em { background: var(--coral); }.support-row b { color: #788888; font-size: 7px; }
.report-bar-list { display: grid; gap: 10px; }
.report-bar-item { display: grid; grid-template-columns: 72px 1fr 18px; align-items: center; gap: 7px; color: #788888; font-size: 7px; }
.report-bar-item i { height: 7px; overflow: hidden; border-radius: 10px; background: #edf1ef; }
.report-bar-item em { display: block; height: 100%; border-radius: inherit; background: #7da195; }
.support-chart .report-bar-item em { background: var(--coral); }
.report-empty-chart { padding: 18px 5px; color: #93a0a1; font-size: 8px; line-height: 1.5; text-align: center; }
.recommendation { margin-top: 8px; padding: 16px; border-left: 3px solid #83a398; background: #f2f6f3; }
.recommendation p { margin-bottom: 0; }
.signature { width: 230px; margin-top: 35px; padding-top: 10px; border-top: 1px solid #9daaaa; }
.signature span, .signature small { display: block; }.signature span { font-family: Georgia, serif; font-size: 13px; }.signature small { margin-top: 4px; color: #849091; font-size: 7px; }

.modal-backdrop { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; background: rgba(17,46,55,.55); backdrop-filter: blur(5px); }
.modal-backdrop[hidden] { display: none; }
.modal { position: relative; width: min(430px, 100%); padding: 34px; border-radius: 20px; background: #fff; box-shadow: 0 30px 80px rgba(13,40,47,.3); }
.modal h2 { margin: 8px 0; font-size: 27px; }.modal > p { margin-bottom: 22px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.modal-close { position: absolute; top: 14px; right: 16px; color: var(--muted); border: 0; background: transparent; font-size: 24px; }
.patient-modal { width: min(610px, 100%); max-height: calc(100vh - 30px); overflow-y: auto; }
.onboarding-modal { width: min(680px, 100%); max-height: calc(100vh - 30px); overflow-y: auto; }
.help-modal { width: min(760px, 100%); max-height: calc(100vh - 30px); overflow-y: auto; }
.help-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 22px 0; }
.help-card { padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: linear-gradient(145deg, #fff, #f8fbf9); }
.help-card span { display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 10px; color: var(--brand); border-radius: 50%; background: #e5f0eb; font-weight: 900; }
.help-card strong { display: block; color: var(--ink); }
.help-card p, .help-notes p { color: var(--muted); font-size: 11px; line-height: 1.55; }
.help-card .text-button { margin-top: 8px; }
.help-notes { display: grid; gap: 10px; }
.help-notes > div { padding: 14px; border-radius: 14px; background: #f2f7f4; }
.help-notes strong { color: var(--brand); font-size: 12px; }
.support-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.support-link { display: inline-flex; min-height: 34px; align-items: center; padding: 0 12px; color: var(--brand); border: 1px solid #cfe0d8; border-radius: 999px; background: #fff; font-size: 11px; font-weight: 800; }
.support-link:hover { border-color: var(--coral); }
.option-group {
  display: grid;
  gap: 10px;
  margin: 14px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #f8fbf9;
}
.option-group legend {
  padding: 0 6px;
  color: var(--brand);
  font-size: 12px;
  font-weight: 900;
}
.option-group label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: #536b72;
  font-size: 13px;
  font-weight: 750;
}
.option-group input { width: auto; accent-color: var(--brand); }
.privacy-note { display: flex; gap: 8px; margin: 5px 0 22px; padding: 13px; color: #60766f; border-radius: 11px; background: #edf4f0; font-size: 10px; line-height: 1.5; }
.privacy-note strong { flex: 0 0 auto; color: var(--ink); }
.danger-button { min-height: 42px; padding: 0 18px; color: #fff; border: 1px solid #a84f49; border-radius: 11px; background: #a84f49; font-weight: 700; }
.confirm-modal { width: min(390px, 100%); }
.clinical-modal { width: min(920px, 100%); max-height: calc(100vh - 30px); overflow-y: auto; }
.appointment-modal { width: min(580px, 100%); max-height: calc(100vh - 30px); overflow-y: auto; }
.anamnesis-fields { margin: 26px 0 20px; padding-top: 8px; border-top: 1px solid var(--line); }
.anamnesis-fields[hidden] { display: none; }
.anamnesis-section { margin-top: 18px; }
.anamnesis-section h3 { margin: 0 0 12px; color: var(--brand); font-size: 13px; letter-spacing: .7px; text-transform: uppercase; }
.anamnesis-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.anamnesis-tools {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid #dbe7e1;
  border-radius: 16px;
  background: #f7fbf8;
}
.anamnesis-tools span { color: var(--muted); font-size: 11px; line-height: 1.5; }
.records-toolbar, .agenda-toolbar { display: flex; align-items: end; gap: 14px; margin-bottom: 20px; padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.records-toolbar label, .agenda-toolbar label { min-width: 220px; margin: 0; }
.record-summary-grid, .agenda-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; }
.record-summary-grid article, .agenda-summary article { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.record-summary-grid span, .record-summary-grid strong, .agenda-summary span, .agenda-summary strong { display: block; }
.record-summary-grid span, .agenda-summary span { color: var(--muted); font-size: 10px; }
.record-summary-grid strong, .agenda-summary strong { margin-top: 6px; font-family: Georgia, serif; font-size: 22px; font-weight: 500; }
.record-timeline { position: relative; display: grid; gap: 14px; padding-left: 30px; }
.record-timeline::before { position: absolute; top: 8px; bottom: 8px; left: 10px; width: 2px; background: #dce6e2; content: ""; }
.record-entry { position: relative; padding: 20px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 10px 28px rgba(35,70,78,.045); }
.record-entry::before { position: absolute; top: 25px; left: -27px; width: 12px; height: 12px; border: 4px solid #f5f7f4; border-radius: 50%; background: var(--coral); content: ""; }
.record-entry-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; }
.record-entry time { color: var(--coral); font-size: 10px; font-weight: 800; }
.record-entry h3 { margin: 5px 0 4px; font-family: Georgia, serif; font-size: 20px; }
.record-entry p { margin: 12px 0 0; color: var(--muted); font-size: 11px; line-height: 1.65; white-space: pre-wrap; }
.record-type { padding: 6px 9px; color: #55756d; border-radius: 20px; background: #e7f0ec; font-size: 8px; font-weight: 900; text-transform: uppercase; }
.record-actions { display: flex; gap: 10px; margin-top: 15px; padding-top: 13px; border-top: 1px solid #edf1ef; }
.anamnesis-preview { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 15px; }
.anamnesis-answer { padding: 12px; border-radius: 11px; background: #f3f7f4; }
.anamnesis-answer strong, .anamnesis-answer span { display: block; }
.anamnesis-answer strong { color: #57716c; font-size: 9px; }.anamnesis-answer span { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.5; white-space: pre-wrap; }
.anamnesis-details { margin-top: 12px; }
.anamnesis-details summary { cursor: pointer; color: var(--brand); font-size: 11px; font-weight: 800; }
.appointment-list { display: grid; gap: 12px; }
.appointment-list.compact { grid-template-columns: repeat(3, 1fr); }
.appointment-card { display: grid; grid-template-columns: 90px 1fr auto; gap: 16px; align-items: center; padding: 18px; border: 1px solid var(--line); border-radius: 17px; background: #fff; box-shadow: 0 9px 25px rgba(35,70,78,.04); }
.appointment-list.compact .appointment-card { grid-template-columns: 1fr; gap: 8px; padding: 15px; box-shadow: none; }
.appointment-date strong, .appointment-date span, .appointment-info strong, .appointment-info span { display: block; }
.appointment-date strong { color: var(--brand); font-family: Georgia, serif; font-size: 20px; }.appointment-date span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.appointment-info strong { font-size: 13px; }.appointment-info span { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.appointment-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.appointment-card.cancelled { opacity: .62; }.appointment-card.completed { border-color: #c4dace; background: #f7faf8; }
.appointment-status { width: max-content; padding: 5px 8px; border-radius: 20px; background: #edf2ef; color: #627a74; font-size: 8px; font-weight: 900; text-transform: uppercase; }
.appointment-status.scheduled { color: #8c654f; background: #f4e8df; }
.appointment-status.completed { color: #507665; background: #e2efe8; }
.appointment-status.cancelled { color: #8a6762; background: #efe5e3; }
.history-modal { width: min(680px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; }
.history-list { display: grid; gap: 10px; margin-top: 20px; }
.history-item { display: grid; grid-template-columns: 82px 1fr auto; gap: 13px; align-items: start; padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: #fafcfa; }
.history-item time { color: var(--coral); font-size: 9px; font-weight: 800; }
.history-item strong, .history-item span, .history-item small { display: block; }
.history-item strong { font-size: 12px; }.history-item span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.history-item small { max-width: 150px; color: #71847f; font-size: 9px; line-height: 1.4; text-align: right; }
.toast { position: fixed; right: 25px; bottom: 25px; z-index: 80; padding: 14px 18px; color: #fff; border-radius: 12px; background: var(--brand-dark); box-shadow: var(--shadow); font-size: 12px; transform: translateY(100px); opacity: 0; transition: .25s ease; }
.toast.show { transform: translateY(0); opacity: 1; }

.creator-footer {
  display: flex;
  margin-left: 260px;
  align-items: center;
  justify-content: space-between;
  padding: 22px 4vw;
  color: #91a2a6;
  border-top: 1px solid var(--line);
  background: #eef2ef;
  font-size: 11px;
}
.creator-footer[hidden] { display: none; }
.creator-footer > span { color: var(--brand); font-family: Georgia, serif; font-size: 16px; }
.creator-footer strong { color: var(--ink); }

.activity-player {
  position: fixed;
  inset: 0;
  z-index: 100;
  overflow-y: auto;
  color: #1c3b46;
  background:
    radial-gradient(circle at 15% 15%, rgba(208,228,220,.65), transparent 30%),
    radial-gradient(circle at 88% 82%, rgba(239,218,205,.55), transparent 28%),
    #f8faf8;
  animation: playerIn .45s cubic-bezier(.2,.8,.2,1);
}
.activity-player[hidden] { display: none; }
@keyframes playerIn { from { opacity: 0; transform: scale(.985); } }
.player-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  min-height: 78px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(42,76,84,.1);
  background: rgba(248,250,248,.88);
  backdrop-filter: blur(18px);
}
.player-header strong { display: block; margin-top: 3px; font-family: Georgia, serif; font-size: 20px; }
.stimulus-controls { display: flex; align-items: center; gap: 8px; }
.control-chip { min-height: 38px; padding: 0 13px; color: #587078; border: 1px solid #d3dedb; border-radius: 20px; background: rgba(255,255,255,.8); font-size: 10px; font-weight: 800; }
.control-chip[aria-pressed="true"] { color: #fff; border-color: var(--brand); background: var(--brand); }
.player-close { display: grid; width: 42px; height: 42px; place-items: center; color: var(--ink); border: 1px solid #d3dedb; border-radius: 50%; background: #fff; font-size: 24px; }
.player-content { width: min(1100px, calc(100% - 40px)); margin: 0 auto; padding: 45px 0 55px; }
.activity-instructions { display: flex; align-items: flex-end; justify-content: space-between; gap: 25px; margin-bottom: 30px; }
.activity-instructions h1 { max-width: 720px; margin: 7px 0 9px; font-size: clamp(31px, 4.4vw, 54px); }
.activity-instructions p { max-width: 720px; margin: 0; color: #6c7e82; line-height: 1.6; }
.step-label { color: var(--coral); font-size: 10px; font-weight: 900; letter-spacing: 1.5px; }
.activity-progress { display: grid; flex: 0 0 auto; width: 105px; height: 105px; place-items: center; align-content: center; border: 1px solid #dbe5e1; border-radius: 50%; background: rgba(255,255,255,.75); box-shadow: 0 14px 35px rgba(42,75,80,.08); }
.activity-progress strong, .activity-progress span { display: block; text-align: center; }
.activity-progress strong { font-family: Georgia, serif; font-size: 20px; }.activity-progress span { margin-top: 3px; color: var(--muted); font-size: 9px; }
.session-context { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 20px; padding: 16px; border: 1px solid rgba(73,104,106,.12); border-radius: 18px; background: rgba(255,255,255,.7); }
.session-context label { margin: 0; }
.matching-board { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.activity-board[hidden] { display: none; }
.shape-bank, .target-bank { min-height: 285px; padding: 25px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.shape-bank > span, .target-bank > span { display: block; margin-bottom: 28px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.shape-row { display: flex; min-height: 165px; align-items: center; justify-content: space-around; flex-wrap: wrap; gap: 18px; }
.activity-player.difficulty-initial .match-shape,
.activity-player.difficulty-initial .match-target,
.activity-player.difficulty-initial .photo-option { transform: scale(1.04); }
.activity-player.difficulty-initial .photo-option:hover { transform: translateY(-5px) scale(1.04); }
.match-shape, .match-target {
  position: relative;
  display: grid;
  width: clamp(82px, 10vw, 116px);
  height: clamp(82px, 10vw, 116px);
  place-items: center;
  border: 0;
  outline: none;
  touch-action: none;
  transition: transform .24s cubic-bezier(.2,.8,.2,1), box-shadow .24s ease, opacity .24s ease;
}
.match-shape { filter: drop-shadow(0 12px 8px rgba(30,60,66,.18)); }
.match-shape:hover, .match-shape:focus-visible, .match-shape.selected { transform: translateY(-8px) scale(1.07); filter: drop-shadow(0 18px 10px rgba(30,60,66,.22)); }
.match-shape.selected::after { position: absolute; inset: -12px; border: 3px solid var(--brand); border-radius: 22px; content: ""; }
.shape-circle { border-radius: 50%; background: linear-gradient(145deg, #e89a7f, #c96651); box-shadow: inset 8px 8px 12px rgba(255,255,255,.22), inset -8px -8px 14px rgba(111,48,38,.18); }
.shape-square { border-radius: 22%; background: linear-gradient(145deg, #85aaa0, #527e75); box-shadow: inset 8px 8px 12px rgba(255,255,255,.22), inset -8px -8px 14px rgba(37,83,73,.2); }
.shape-triangle { height: 105px; background: linear-gradient(145deg, #e8bc72, #c88b38); clip-path: polygon(50% 2%, 98% 96%, 2% 96%); }
.shape-diamond { background: linear-gradient(145deg, #8aa6c3, #587794); clip-path: polygon(50% 0,100% 50%,50% 100%,0 50%); }
.shape-star { background: linear-gradient(145deg, #d89aaa, #a8667a); clip-path: polygon(50% 0,61% 35%,98% 35%,68% 57%,79% 94%,50% 72%,21% 94%,32% 57%,2% 35%,39% 35%); }
.match-target { border: 3px dashed #b8c9c5; border-radius: 24px; background: #f5f8f6; }
.match-target i { display: block; width: 70%; height: 70%; opacity: .18; background: var(--brand); }
.target-circle i { border-radius: 50%; }.target-square i { border-radius: 18%; }.target-triangle i { clip-path: polygon(50% 2%, 98% 96%, 2% 96%); }
.target-diamond i { clip-path: polygon(50% 0,100% 50%,50% 100%,0 50%); }
.target-star i { clip-path: polygon(50% 0,61% 35%,98% 35%,68% 57%,79% 94%,50% 72%,21% 94%,32% 57%,2% 35%,39% 35%); }
.extra-shape { display: none; }
.activity-player.difficulty-advanced .extra-shape { display: grid; }
.activity-player.difficulty-initial .match-shape[data-shape="triangle"],
.activity-player.difficulty-initial .match-target[data-target="triangle"] { display: none; }
.activity-player.difficulty-advanced .routine-card strong,
.activity-player.difficulty-advanced .story-card strong,
.activity-player.difficulty-advanced .category-item strong,
.activity-player.difficulty-advanced .photo-option strong,
.activity-player.difficulty-advanced .word-picture strong { visibility: hidden; }
.activity-player.difficulty-advanced #playerActivityInstructions { opacity: .45; }
.match-target:hover, .match-target:focus-visible, .match-target.drag-over { transform: scale(1.04); border-color: #759c91; background: #edf4f0; }
.match-target.matched { border-style: solid; border-color: #73a190; background: #e7f1ec; animation: matchedPop .42s cubic-bezier(.2,.8,.2,1); }
.match-target.matched i { opacity: .75; background: #69a08d; }
.match-shape.matched { pointer-events: none; opacity: .18; transform: scale(.8); }
.match-target.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.pointer-ghost {
  position: fixed !important;
  z-index: 200;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.82) !important;
  opacity: .88;
}
@keyframes matchedPop { 50% { transform: scale(1.09); } }
@keyframes softShake { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.patient-feedback { display: flex; min-height: 56px; align-items: center; justify-content: center; margin: 20px 0; padding: 12px 20px; color: #5f7377; border-radius: 16px; background: rgba(255,255,255,.75); text-align: center; font-size: 13px; font-weight: 700; }
.patient-feedback.success { color: #376b5b; background: #e5f1eb; }
.sequence-board { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.sequence-source, .sequence-targets { min-height: 315px; padding: 25px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.sequence-source > span, .sequence-targets > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.routine-cards, .routine-slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.routine-card, .routine-slot { min-height: 190px; padding: 16px 10px; border-radius: 20px; transition: transform .22s ease, box-shadow .22s ease, opacity .22s ease; }
.routine-card { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 15px; color: var(--ink); border: 1px solid #d8e1de; background: linear-gradient(160deg, #fff, #eef3f0); box-shadow: 0 7px 0 #d2ded9, 0 15px 25px rgba(37,70,75,.1); touch-action: none; }
.routine-card:hover, .routine-card:focus-visible, .routine-card.selected { transform: translateY(-7px); box-shadow: 0 12px 0 #d2ded9, 0 22px 30px rgba(37,70,75,.14); }
.routine-card.selected { outline: 3px solid var(--brand); }
.routine-card.placed { pointer-events: none; opacity: .18; transform: scale(.88); }
.routine-icon { position: relative; display: block; width: 65px; height: 65px; }
.routine-icon.sun { border-radius: 50%; background: #e7b35f; box-shadow: 0 0 0 10px #f5e4bb; }
.routine-icon.cup { width: 58px; height: 50px; border-radius: 8px 8px 18px 18px; background: #7ca198; }
.routine-icon.cup::after { position: absolute; top: 9px; right: -17px; width: 20px; height: 25px; border: 7px solid #7ca198; border-left: 0; border-radius: 0 15px 15px 0; content: ""; }
.routine-icon.bag { width: 58px; height: 64px; border-radius: 13px 13px 18px 18px; background: #d87f65; }
.routine-icon.bag::before { position: absolute; top: -13px; left: 13px; width: 26px; height: 20px; border: 6px solid #b96752; border-bottom: 0; border-radius: 12px 12px 0 0; content: ""; }
.routine-card strong { font-size: 11px; }
.routine-slot { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 10px; color: #82928f; border: 3px dashed #bdcbc7; background: #f5f8f6; }
.routine-slot b { display: grid; width: 40px; height: 40px; place-items: center; color: #fff; border-radius: 50%; background: #a8bbb5; font-family: Georgia, serif; font-size: 18px; }
.routine-slot span { font-size: 9px; font-weight: 800; text-transform: uppercase; }
.routine-slot:hover, .routine-slot:focus-visible, .routine-slot.drag-over { transform: scale(1.025); border-color: #789b92; }
.routine-slot.filled { color: var(--ink); border-style: solid; border-color: #79a191; background: #e7f1ec; }
.routine-slot.filled b { background: #5e8c7d; }
.routine-slot.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.missing-board { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 24px; align-items: stretch; }
.memory-stage, .memory-options { min-height: 310px; padding: 25px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.memory-stage > span, .memory-options > span { display: block; margin-bottom: 28px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.memory-display, .memory-option-row { display: flex; min-height: 190px; align-items: center; justify-content: center; flex-wrap: wrap; gap: 20px; }
.memory-symbol { position: relative; display: grid; width: 105px; height: 105px; place-items: center; border-radius: 24px; background: #f3f6f4; box-shadow: inset 0 0 0 1px #dbe4e1, 0 10px 24px rgba(41,73,79,.08); }
.memory-symbol i { position: relative; display: block; width: 58px; height: 58px; }
.memory-symbol .real-photo { width: 88px; height: 88px; border: 1px solid #e0e3df; box-shadow: 0 7px 16px rgba(35,70,78,.1); }
.memory-option .memory-symbol .real-photo { width: 72px; height: 72px; }
.memory-symbol .symbol-star { background: #e5af54; clip-path: polygon(50% 0,61% 35%,98% 35%,68% 57%,79% 94%,50% 72%,21% 94%,32% 57%,2% 35%,39% 35%); }
.memory-symbol .symbol-heart { width: 55px; height: 50px; background: #d87965; transform: rotate(-45deg); border-radius: 10px 0 10px 0; }
.memory-symbol .symbol-heart::before, .memory-symbol .symbol-heart::after { position: absolute; width: 55px; height: 50px; border-radius: 50%; background: #d87965; content: ""; }
.memory-symbol .symbol-heart::before { top: -25px; left: 0; }.memory-symbol .symbol-heart::after { top: 0; left: 25px; }
.memory-symbol .symbol-leaf { width: 48px; height: 67px; border-radius: 80% 10% 80% 10%; background: #6e9b83; transform: rotate(28deg); }
.memory-symbol .symbol-moon { border-radius: 50%; background: #718eaa; box-shadow: inset 18px -8px 0 #f3f6f4; }
.memory-symbol.hidden-item { animation: memoryFade .35s ease forwards; }
@keyframes memoryFade { to { opacity: 0; transform: scale(.8); } }
.memory-option { width: 94px; height: 94px; padding: 0; border: 2px solid transparent; border-radius: 22px; background: #f3f6f4; }
.memory-option:hover, .memory-option:focus-visible { transform: translateY(-5px); border-color: #789b92; }
.memory-option.correct { border-color: #6e9b83; background: #e4f0ea; }
.memory-option.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.memory-continue { position: absolute; right: 25px; bottom: 25px; }
.emotion-board { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.emotion-scene, .emotion-choices { min-height: 345px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.emotion-scene > span, .emotion-choices > span { display: block; margin-bottom: 18px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.emotion-scene h2 { margin: 18px 0 8px; font-size: 23px; text-align: center; }
.emotion-scene p { margin: 0; color: var(--muted); font-size: 12px; text-align: center; }
.scene-illustration { position: relative; display: grid; height: 150px; place-items: center; overflow: hidden; border-radius: 22px; background: #e8f0ec; }
.scene-illustration::before { width: 85px; height: 85px; border-radius: 50%; background: #e7b863; box-shadow: 75px 25px 0 #7b9f94, -85px 35px 0 #dc816a; content: ""; }
.scene-illustration.gift::after { position: absolute; width: 72px; height: 58px; border-radius: 8px; background: #d97c63; box-shadow: inset 0 10px 0 #edaa97; content: ""; }
.scene-illustration.lost::before { background: #7b9f94; box-shadow: 80px 30px 0 #d9b163, -80px 20px 0 #d6dfdc; }
.scene-illustration.lost::after { position: absolute; bottom: 25px; width: 48px; height: 48px; border: 4px dashed #b07b68; border-radius: 12px; content: ""; }
.scene-illustration.waiting::before { background: #d9b163; box-shadow: 80px 30px 0 #d6dfdc, -80px 20px 0 #7b9f94; }
.scene-illustration.waiting::after { position: absolute; width: 72px; height: 72px; border: 7px solid #506f79; border-radius: 50%; content: ""; }
.emotion-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.emotion-choice { display: flex; min-height: 105px; align-items: center; justify-content: center; flex-direction: column; gap: 9px; color: var(--ink); border: 1px solid #d7e1de; border-radius: 20px; background: #f7f9f8; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.emotion-choice:hover, .emotion-choice:focus-visible { transform: translateY(-4px); border-color: #799b92; }
.emotion-face { position: relative; display: block; width: 48px; height: 48px; border-radius: 50%; background: #e6b765; }
.emotion-face::before { position: absolute; top: 15px; left: 12px; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); box-shadow: 19px 0 0 var(--ink); content: ""; }
.emotion-face::after { position: absolute; top: 28px; left: 14px; width: 20px; height: 9px; border-bottom: 3px solid var(--ink); border-radius: 0 0 20px 20px; content: ""; }
.emotion-face.sad::after { top: 31px; border-top: 3px solid var(--ink); border-bottom: 0; border-radius: 20px 20px 0 0; }
.emotion-face.calm::after { top: 30px; height: 0; border-bottom: 3px solid var(--ink); border-radius: 0; }
.emotion-face.unsure { background: #b7c7c3; }.emotion-face.unsure::after { top: 27px; left: 19px; width: 10px; height: 10px; border: 0; content: "?"; font-size: 14px; font-weight: 900; }
.emotion-choice strong { font-size: 11px; }
.emotion-choice.correct { border-color: #6f9b86; background: #e5f1eb; }
.emotion-choice.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.emotion-continue { position: absolute; right: 28px; bottom: 28px; }
.spatial-board { position: relative; display: grid; grid-template-columns: .72fr 1.28fr; gap: 24px; }
.spatial-prompt, .spatial-grid-wrap { min-height: 390px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.spatial-prompt > span, .spatial-grid-wrap > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.spatial-prompt h2 { margin: 35px 0 10px; font-size: 28px; line-height: 1.15; text-align: center; }
.spatial-prompt p { color: var(--muted); font-size: 12px; text-align: center; }
.spatial-legend { display: flex; align-items: center; justify-content: center; gap: 13px; margin-top: 38px; padding: 15px; border-radius: 15px; background: #edf3f0; }
.spatial-legend span { color: #627873; font-size: 9px; font-weight: 800; }
.spatial-piece { display: block; width: 45px; height: 45px; filter: drop-shadow(0 7px 5px rgba(36,67,72,.18)); }
.piece-circle { border-radius: 50%; background: #d97d64; }
.piece-square { border-radius: 11px; background: #71998e; }
.piece-triangle { background: #e2ae57; clip-path: polygon(50% 2%, 98% 96%, 2% 96%); }
.spatial-grid { display: grid; width: min(350px, 100%); margin: 0 auto; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.spatial-grid button { position: relative; aspect-ratio: 1; padding: 0; border: 2px dashed #c4d0cd; border-radius: 18px; background: #f5f8f6; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.spatial-grid button:hover, .spatial-grid button:focus-visible { transform: scale(1.035); border-color: #789b92; background: #edf4f0; }
.spatial-grid button.reference { border-style: solid; border-color: #a8bab5; background: #e6eeeb; }
.spatial-grid button.reference::after, .spatial-grid button.correct::after { position: absolute; inset: 24%; content: ""; }
.spatial-grid button.correct { border-style: solid; border-color: #6e9c89; background: #e4f0ea; }
.spatial-grid button.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.spatial-grid .piece-circle::after { border-radius: 50%; background: #d97d64; }
.spatial-grid .piece-square::after { border-radius: 20%; background: #71998e; }
.spatial-grid .piece-triangle::after { background: #e2ae57; clip-path: polygon(50% 2%, 98% 96%, 2% 96%); }
.spatial-continue { position: absolute; right: 28px; bottom: 28px; }
.story-board { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.story-source, .story-target { min-height: 350px; padding: 25px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.story-source > span, .story-target > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.story-cards, .story-slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; }
.story-card, .story-slots button { display: flex; min-height: 220px; align-items: center; justify-content: center; flex-direction: column; gap: 15px; padding: 14px 8px; border-radius: 20px; transition: transform .22s ease, opacity .22s ease, box-shadow .22s ease; }
.story-card { color: var(--ink); border: 1px solid #d6e0dd; background: linear-gradient(160deg, #fff, #eef3f0); box-shadow: 0 7px 0 #d2ded9, 0 15px 25px rgba(37,70,75,.1); touch-action: none; }
.story-card:hover, .story-card:focus-visible, .story-card.selected { transform: translateY(-7px); box-shadow: 0 12px 0 #d2ded9, 0 22px 30px rgba(37,70,75,.14); }
.story-card.selected { outline: 3px solid var(--brand); }
.story-card.placed { pointer-events: none; opacity: .18; transform: scale(.88); }
.story-card strong { font-size: 10px; text-align: center; line-height: 1.35; }
.story-art { position: relative; display: block; width: 76px; height: 90px; }
.story-art::after { position: absolute; right: 12px; bottom: 3px; left: 12px; height: 38px; border-radius: 7px 7px 20px 20px; background: #b97858; content: ""; }
.seed-pot::before { position: absolute; z-index: 1; top: 25px; left: 34px; width: 9px; height: 9px; border-radius: 50%; background: #66543c; content: ""; }
.watering::before { position: absolute; z-index: 1; top: 7px; left: 5px; width: 45px; height: 35px; border-radius: 13px 13px 8px 8px; background: #729a91; box-shadow: 34px 8px 0 -10px #729a91; transform: rotate(-12deg); content: ""; }
.plant-grown::before { position: absolute; z-index: 1; top: 0; left: 36px; width: 7px; height: 58px; background: #648b72; box-shadow: -17px 12px 0 5px #79a486, 17px 24px 0 5px #79a486; content: ""; }
.story-slots button { color: #82928f; border: 3px dashed #bdcbc7; background: #f5f8f6; }
.story-slots button b { display: grid; width: 42px; height: 42px; place-items: center; color: #fff; border-radius: 50%; background: #a8bbb5; font-family: Georgia, serif; font-size: 18px; }
.story-slots button span { font-size: 9px; font-weight: 800; text-align: center; text-transform: uppercase; }
.story-slots button:hover, .story-slots button:focus-visible, .story-slots button.drag-over { transform: scale(1.025); border-color: #789b92; }
.story-slots button.filled { color: var(--ink); border-style: solid; border-color: #79a191; background: #e7f1ec; }
.story-slots button.filled b { background: #5e8c7d; }
.story-slots button.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.category-board { display: grid; grid-template-columns: 1.15fr .85fr; gap: 24px; }
.category-items, .category-targets { min-height: 385px; padding: 25px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.category-items > span, .category-targets > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.category-item-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; }
.category-item { display: flex; min-height: 145px; align-items: center; justify-content: center; flex-direction: column; gap: 10px; color: var(--ink); border: 1px solid #d7e1de; border-radius: 18px; background: #f7f9f8; box-shadow: 0 5px 0 #d6e0dc; touch-action: none; transition: transform .2s ease, opacity .2s ease; }
.category-item:hover, .category-item:focus-visible, .category-item.selected { transform: translateY(-5px); }
.category-item.selected { outline: 3px solid var(--brand); }
.category-item.sorted { pointer-events: none; opacity: .16; transform: scale(.88); }
.category-item i { position: relative; display: block; width: 58px; height: 58px; }
.category-item strong { font-size: 10px; }
.real-photo {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  background-image: url("assets/images/activities/realistic-objects-v1.png");
  background-repeat: no-repeat;
  background-size: 300% 200%;
  background-color: #f5f3f0;
}
.photo-cat { background-position: 0 0; }
.photo-apple { background-position: 50% 0; }
.photo-fish { background-position: 100% 0; }
.photo-bread { background-position: 0 100%; }
.photo-bird { background-position: 50% 100%; }
.photo-carrot { background-position: 100% 100%; }
.photo-ball, .photo-car, .photo-duck, .photo-block, .photo-cup, .photo-backpack,
.photo-toothbrush, .photo-shoes, .photo-banana, .photo-orange, .photo-sunflower,
.photo-leaf, .photo-dog, .photo-butterfly, .photo-pencil, .photo-clock {
  background-image: url("assets/images/activities/realistic-objects-v2.png");
  background-size: 400% 400%;
}
.photo-ball { background-position: 0 0; }
.photo-car { background-position: 33.333% 0; }
.photo-duck { background-position: 66.666% 0; }
.photo-block { background-position: 100% 0; }
.photo-cup { background-position: 0 33.333%; }
.photo-backpack { background-position: 33.333% 33.333%; }
.photo-toothbrush { background-position: 66.666% 33.333%; }
.photo-shoes { background-position: 100% 33.333%; }
.photo-banana { background-position: 0 66.666%; }
.photo-orange { background-position: 33.333% 66.666%; }
.photo-sunflower { background-position: 66.666% 66.666%; }
.photo-leaf { background-position: 100% 66.666%; }
.photo-dog { background-position: 0 100%; }
.photo-butterfly { background-position: 33.333% 100%; }
.photo-pencil { background-position: 66.666% 100%; }
.photo-clock { background-position: 100% 100%; }
.photo-house, .photo-strawberry, .photo-drum, .photo-teddy, .photo-book,
.photo-spoon, .photo-bottle, .photo-bicycle, .photo-bus, .photo-tree {
  background-image: url("assets/images/activities/realistic-objects-v3.png");
  background-size: 400% 400%;
}
.photo-house { background-position: 0 0; }
.photo-strawberry { background-position: 100% 33.333%; }
.photo-drum { background-position: 0 66.666%; }
.photo-teddy { background-position: 33.333% 66.666%; }
.photo-book { background-position: 66.666% 66.666%; }
.photo-spoon { background-position: 100% 66.666%; }
.photo-bottle { background-position: 0 100%; }
.photo-bicycle { background-position: 33.333% 100%; }
.photo-bus { background-position: 66.666% 100%; }
.photo-tree { background-position: 100% 100%; }
.category-item .real-photo { width: 82px; height: 82px; border: 1px solid #e0e3df; box-shadow: 0 8px 18px rgba(35,70,78,.09); }
.item-cat { border-radius: 48% 48% 42% 42%; background: #8ca7a0; }.item-cat::before { position: absolute; top: -8px; left: 5px; width: 20px; height: 20px; background: #8ca7a0; box-shadow: 28px 0 0 #8ca7a0; clip-path: polygon(50% 0,100% 100%,0 100%); content: ""; }
.item-apple { border-radius: 48% 48% 52% 52%; background: #d97862; }.item-apple::before { position: absolute; top: -9px; left: 30px; width: 8px; height: 17px; border-radius: 5px; background: #557866; transform: rotate(25deg); content: ""; }
.item-fish { width: 65px !important; height: 42px !important; margin-top: 8px; border-radius: 55% 45% 45% 55%; background: #7598ad; }.item-fish::after { position: absolute; right: -20px; width: 25px; height: 35px; background: #7598ad; clip-path: polygon(0 50%,100% 0,100% 100%); content: ""; }
.item-bread { height: 48px !important; margin-top: 8px; border-radius: 25px 25px 10px 10px; background: #dbaf70; box-shadow: inset 0 -10px 0 #c78d4e; }
.item-bird { border-radius: 60% 40% 55% 45%; background: #daa85a; }.item-bird::after { position: absolute; right: -13px; top: 17px; width: 20px; height: 15px; background: #d97c63; clip-path: polygon(0 0,100% 50%,0 100%); content: ""; }
.item-carrot { width: 38px !important; background: #df8b55; clip-path: polygon(0 0,100% 0,58% 100%,42% 100%); }.item-carrot::before { position: absolute; top: -15px; left: 8px; width: 24px; height: 22px; background: #6f9a74; clip-path: polygon(50% 100%,0 0,45% 35%,50% 0,55% 35%,100% 0); content: ""; }
.category-bins { display: grid; gap: 18px; }
.category-bin { display: grid; min-height: 145px; place-items: center; align-content: center; gap: 8px; color: var(--ink); border: 3px dashed #bdcbc7; border-radius: 22px; background: #f4f7f5; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.category-bin:hover, .category-bin:focus-visible, .category-bin.drag-over { transform: scale(1.025); border-color: #789b92; background: #edf4f0; }
.category-bin i { display: block; width: 48px; height: 48px; border-radius: 50%; }
.bin-animal { background: #7f9f97; }.bin-food { background: #d99b67; }
.category-bin strong { font-family: Georgia, serif; font-size: 17px; }
.category-bin small { color: var(--muted); font-size: 9px; }
.category-bin.accepted { animation: matchedPop .42s ease; border-color: #72a08d; }
.category-bin.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.pattern-board { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 24px; }
.pattern-stage, .pattern-options { min-height: 330px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.pattern-stage > span, .pattern-options > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.pattern-stage h2 { margin: 15px 0 34px; font-size: 27px; text-align: center; }
.pattern-sequence { display: flex; min-height: 120px; align-items: center; justify-content: center; flex-wrap: wrap; gap: 14px; }
.pattern-token, .pattern-choice { display: grid; width: 86px; height: 86px; place-items: center; border-radius: 20px; background: #f4f7f5; box-shadow: inset 0 0 0 1px #dbe4e1; }
.pattern-token.question { color: #8b9b98; border: 3px dashed #b9c8c4; background: transparent; box-shadow: none; font-family: Georgia, serif; font-size: 33px; }
.pattern-symbol { display: block; width: 48px; height: 48px; }
.pattern-circle { border-radius: 50%; }.pattern-square { border-radius: 10px; }.pattern-triangle { clip-path: polygon(50% 2%,98% 96%,2% 96%); }
.pattern-coral { background: #d97d64; }.pattern-green { background: #71998e; }.pattern-gold { background: #dfae58; }.pattern-blue { background: #7597ad; }
.pattern-option-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-content: center; min-height: 190px; }
.pattern-choice { width: 100%; height: auto; min-height: 110px; border: 2px solid transparent; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.pattern-choice:hover, .pattern-choice:focus-visible { transform: translateY(-5px); border-color: #789b92; }
.pattern-choice.correct { border-color: #6f9b86; background: #e5f1eb; }
.pattern-choice.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.pattern-continue { position: absolute; right: 28px; bottom: 28px; }
.quantity-board { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; }
.quantity-stage, .quantity-options { min-height: 330px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.quantity-stage > span, .quantity-options > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.quantity-stage h2 { margin: 12px 0 30px; font-size: 27px; text-align: center; }
.quantity-objects { display: flex; min-height: 155px; align-items: center; justify-content: center; flex-wrap: wrap; gap: 18px; }
.count-object { position: relative; display: block; width: 66px; height: 66px; border: 1px solid #e0e3df; filter: drop-shadow(0 8px 6px rgba(35,66,71,.14)); }
.count-ball { border-radius: 50%; background: #d97d64; box-shadow: inset 8px 7px 0 rgba(255,255,255,.22); }
.count-block { border-radius: 13px; background: #71998e; box-shadow: inset 8px 7px 0 rgba(255,255,255,.18); }
.count-flower::before { position: absolute; inset: 17px; border-radius: 50%; background: #d99b56; box-shadow: 0 -19px 0 #e7b76d, 0 19px 0 #e7b76d, 19px 0 0 #e7b76d, -19px 0 0 #e7b76d; content: ""; }
.number-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-content: center; min-height: 190px; }
.number-choice { min-height: 110px; color: var(--ink); border: 2px solid transparent; border-radius: 20px; background: #f4f7f5; font-family: Georgia, serif; font-size: 35px; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.number-choice:hover, .number-choice:focus-visible { transform: translateY(-5px); border-color: #789b92; }
.number-choice.correct { border-color: #6f9b86; background: #e5f1eb; }
.number-choice.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.quantity-continue { position: absolute; right: 28px; bottom: 28px; }
.syllable-board { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.syllable-stage, .syllable-options { min-height: 340px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.syllable-stage > span, .syllable-options > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.syllable-stage h2 { margin: 10px 0 20px; font-size: 27px; text-align: center; }
.syllable-stage p { color: var(--muted); font-size: 10px; text-align: center; }
.word-picture { display: grid; width: 180px; min-height: 170px; margin: 0 auto 14px; place-items: center; align-content: center; gap: 14px; border-radius: 25px; background: #f0f5f2; box-shadow: inset 0 0 0 1px #dbe5e1; }
.word-picture i { position: relative; display: block; width: 118px; height: 105px; border: 1px solid #e0e3df; box-shadow: 0 8px 18px rgba(35,70,78,.09); }
.word-picture strong { font-family: Georgia, serif; font-size: 22px; }
.word-ball { border-radius: 50%; background: radial-gradient(circle at 30% 25%, #efaa96 0 13%, #d97962 14% 100%); box-shadow: inset -9px -10px 0 rgba(125,50,39,.12); }
.word-house::before { position: absolute; bottom: 0; left: 9px; width: 60px; height: 52px; border-radius: 5px; background: #7a9d94; content: ""; }.word-house::after { position: absolute; top: 0; left: 3px; width: 72px; height: 45px; background: #d98a69; clip-path: polygon(50% 0,100% 100%,0 100%); content: ""; }
.word-cat { border-radius: 48%; background: #d4a45f; }.word-cat::before { position: absolute; top: -12px; left: 7px; width: 25px; height: 25px; background: #d4a45f; box-shadow: 39px 0 0 #d4a45f; clip-path: polygon(50% 0,100% 100%,0 100%); content: ""; }
.syllable-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-content: center; min-height: 210px; }
.syllable-choice { min-height: 115px; color: var(--ink); border: 2px solid transparent; border-radius: 20px; background: #f4f7f5; font-family: Georgia, serif; font-size: 30px; font-weight: 700; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.syllable-choice:hover, .syllable-choice:focus-visible { transform: translateY(-5px); border-color: #789b92; }
.syllable-choice.correct { border-color: #6f9b86; background: #e5f1eb; }
.syllable-choice.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.syllable-continue { position: absolute; right: 28px; bottom: 28px; }
.photo-quiz-board { position: relative; display: grid; grid-template-columns: .72fr 1.28fr; gap: 24px; }
.photo-quiz-prompt, .photo-quiz-options { min-height: 390px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.photo-quiz-prompt > span, .photo-quiz-options > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.photo-quiz-prompt h2 { margin: 35px 0 12px; font-size: 30px; line-height: 1.18; text-align: center; }
.photo-quiz-prompt p { color: var(--muted); font-size: 12px; line-height: 1.6; text-align: center; }
.photo-model { display: grid; justify-items: center; gap: 9px; margin: 10px auto 20px; }
.photo-model[hidden] { display: none; }
.photo-model small { color: #738782; font-size: 9px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; }
.photo-model .real-photo { width: 130px; height: 130px; border: 3px solid #fff; box-shadow: 0 12px 28px rgba(35,70,78,.15); }
.photo-option-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: center; min-height: 270px; }
.photo-option {
  display: flex;
  min-height: 230px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 13px;
  padding: 14px 10px;
  color: var(--ink);
  border: 1px solid #d7e1de;
  border-radius: 22px;
  background: #f8faf8;
  box-shadow: 0 6px 0 #d8e1de;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.photo-option:hover, .photo-option:focus-visible { transform: translateY(-6px); border-color: #789b92; box-shadow: 0 11px 0 #d8e1de, 0 18px 28px rgba(35,70,78,.12); }
.photo-option .real-photo { width: min(150px, 100%); aspect-ratio: 1; border: 1px solid #e0e3df; }
.photo-option strong { font-size: 12px; }
.photo-option.correct { border-color: #6e9b83; background: #e4f0ea; }
.photo-option.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.photo-option:disabled { cursor: default; }
.photo-quiz-continue { position: absolute; right: 28px; bottom: 28px; }
.functional-choice-board { position: relative; display: grid; grid-template-columns: .72fr 1.28fr; gap: 24px; }
.functional-choice-prompt, .functional-choice-area { min-height: 390px; padding: 28px; border: 1px solid rgba(73,104,106,.12); border-radius: 28px; background: rgba(255,255,255,.82); box-shadow: 0 20px 60px rgba(41,73,79,.08); }
.functional-choice-prompt > span, .functional-choice-area > span { display: block; margin-bottom: 22px; color: #809093; font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-align: center; text-transform: uppercase; }
.functional-choice-prompt h2 { margin: 24px 0 12px; font-size: 28px; line-height: 1.2; text-align: center; }
.functional-choice-prompt p { color: var(--muted); font-size: 12px; line-height: 1.6; text-align: center; }
.functional-choice-mark { display: grid; width: 105px; height: 105px; margin: 12px auto; place-items: center; color: #fff; border: 6px solid #e5eeea; border-radius: 28px; background: linear-gradient(145deg, #315e68, #71998f); box-shadow: 0 10px 0 #d8e1de, 0 18px 30px rgba(35,70,78,.16); font-family: Georgia, serif; font-size: 28px; font-weight: 700; }
.functional-choice-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; align-content: center; min-height: 290px; }
.functional-choice-option { display: grid; min-height: 135px; place-items: center; align-content: center; gap: 8px; padding: 15px; color: var(--ink); border: 2px solid transparent; border-radius: 22px; background: #f4f7f5; box-shadow: 0 7px 0 #d8e1de; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.functional-choice-option > span { display: grid; min-width: 82px; min-height: 50px; padding: 0 10px; place-items: center; color: #fff; border-radius: 14px; background: #527b76; font-size: 12px; font-weight: 900; letter-spacing: .7px; }
.functional-choice-option strong { font-size: 14px; }
.functional-choice-option small { color: var(--muted); font-size: 10px; }
.functional-choice-option:hover, .functional-choice-option:focus-visible { transform: translateY(-6px); border-color: #789b92; box-shadow: 0 12px 0 #d8e1de, 0 19px 28px rgba(35,70,78,.12); }
.functional-choice-option.correct { border-color: #6e9b83; background: #e4f0ea; }
.functional-choice-option.incorrect { animation: softShake .32s ease; border-color: #d3937f; }
.functional-choice-option:disabled { cursor: default; }
.functional-choice-continue { position: absolute; right: 28px; bottom: 28px; }
.activity-player.difficulty-initial .functional-choice-option { min-height: 175px; transform: scale(1.02); }
.activity-player.difficulty-advanced .functional-choice-option small,
.activity-player.difficulty-advanced .functional-choice-prompt p { visibility: hidden; }
.profile-modal { width: min(480px, 100%); }
.player-actions { display: flex; justify-content: flex-end; gap: 12px; }
.result-modal { width: min(520px, 100%); }
#sessionResultBackdrop { z-index: 160; }
.result-summary { display: grid; margin-bottom: 20px; padding: 17px; border-radius: 14px; background: #edf4f0; }
.result-summary span { color: #748983; font-size: 9px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; }
.result-summary strong { margin: 4px 0; font-family: Georgia, serif; font-size: 19px; }
.result-summary small { color: var(--muted); }
.history-preview { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.history-preview span, .history-preview strong { display: block; }
.history-preview span { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .7px; }
.history-preview strong { margin-top: 4px; font-size: 10px; line-height: 1.45; }
.activity-player.reduce-motion *, .activity-player.reduce-motion *::before, .activity-player.reduce-motion *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

@media (max-width: 1100px) {
  .metric-grid, .patient-grid, .activity-grid, .quick-start-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid, .report-layout { grid-template-columns: 1fr; }
  .appointment-list.compact { grid-template-columns: 1fr; }
  .report-form { order: 1; }.report-preview { order: 2; }
}
@media (max-width: 780px) {
  .auth-gate { display: block; min-height: 100vh; min-height: 100dvh; }
  .auth-showcase { min-height: 280px; padding: 32px 28px; }
  .auth-message { padding: 45px 0 25px; }
  .auth-message h1 { max-width: 600px; font-size: clamp(35px, 8vw, 48px); }
  .auth-message p { margin-bottom: 0; }
  .auth-about { max-width: 620px; }
  .auth-features, .auth-credit { display: none; }
  .auth-public-actions { margin-top: 22px; }
  .auth-panel { min-height: auto; padding: 38px 24px 55px; }
  .auth-card { margin: 0; }
  .sidebar { transform: translateX(-100%); transition: transform .25s ease; box-shadow: 15px 0 40px rgba(17,40,46,.2); }
  .sidebar.open { transform: translateX(0); }
  .main-content { width: 100%; margin-left: 0; }
  .creator-footer { margin-left: 0; }
  .menu-button { display: grid; }
  .topbar { padding: 0 20px; }
  .page-navigation span { display: none; }
  .page-navigation { margin-right: 5px; }
  .topbar-title .eyebrow { display: none; }
  .sync-status { display: none; }
  .view { padding: 30px 20px 50px; }
  .welcome-row, .section-heading { align-items: flex-start; flex-direction: column; }
  .metric-grid, .quick-start-grid, .help-grid, .launch-list { grid-template-columns: 1fr; }
  .records-toolbar, .agenda-toolbar { align-items: stretch; flex-direction: column; }
  .records-toolbar label, .agenda-toolbar label { width: 100%; min-width: 0; }
  .record-summary-grid, .agenda-summary, .anamnesis-grid { grid-template-columns: 1fr; }
  .anamnesis-tools { align-items: flex-start; flex-direction: column; }
  .pricing-grid { grid-template-columns: 1fr; }
  .billing-hero, .payment-placeholder { align-items: flex-start; flex-direction: column; }
  .appointment-card { grid-template-columns: 1fr; }
  .appointment-actions { justify-content: flex-start; }
  .activity-highlight { flex-direction: column; }
  .highlight-copy, .activity-art, .hero-image { width: 100%; }
  .activity-art { min-height: 200px; }
  .hero-image { min-height: 260px; background-image: linear-gradient(180deg, var(--brand-dark) 0%, transparent 30%), url("assets/images/hero-cognition.png"); }
  .hero-image::after { background-image: linear-gradient(180deg, var(--brand-dark) 0%, transparent 30%), url("assets/images/hero-progress.png"); }
  .patient-grid, .activity-grid { grid-template-columns: 1fr; }
}
@media (max-width: 540px) {
  .auth-showcase { min-height: auto; padding: 25px 22px 28px; }
  .auth-brand strong { font-size: 23px; }
  .auth-message { padding: 28px 0 0; }
  .auth-message h1 { margin: 11px 0 0; font-size: 34px; }
  .auth-message p { display: none; }
  .auth-about { margin-top: 16px; padding: 14px 15px; border-radius: 16px; }
  .auth-about strong { font-size: 17px; }
  .auth-about span { font-size: 11px; line-height: 1.5; }
  .auth-public-actions { display: grid; grid-template-columns: 1fr; gap: 10px; }
  .light-button, .outline-light-button { width: 100%; min-height: 42px; }
  .auth-panel { padding: 26px 16px 45px; }
  .auth-heading h2 { font-size: 31px; }
  .auth-pricing-note { margin-top: 17px; padding: 13px 14px; }
  .auth-tabs { margin: 20px 0 18px; }
  .auth-form { gap: 13px; }
  .auth-form input, .auth-form select { min-height: 44px; }
  .auth-notice { margin-top: 18px; }
  .password-requirements { grid-template-columns: 1fr; }
  .top-actions .primary-button { min-height: 38px; padding: 0 12px; font-size: 11px; }
  .notification { display: none; }
  .toolbar, .form-actions { flex-direction: column; }
  .toolbar input, .toolbar select { max-width: none; width: 100%; }
  .two-columns, .report-charts { grid-template-columns: 1fr; }
  .report-preview { padding: 25px; }
  .saved-report-card { align-items: flex-start; flex-direction: column; }
  .saved-report-actions { justify-content: flex-start; }
  .progress-summary { align-items: flex-start; flex-direction: column; }
  .session-item { gap: 8px; }.session-item .patient-avatar { display: none; }
  .history-item { grid-template-columns: 1fr; }
  .history-item small { max-width: none; text-align: left; }
  .creator-footer, .activity-instructions { align-items: flex-start; flex-direction: column; }
  .session-context { grid-template-columns: 1fr; }
  .matching-board { grid-template-columns: 1fr; }
  .sequence-board { grid-template-columns: 1fr; }
  .missing-board { grid-template-columns: 1fr; }
  .emotion-board { grid-template-columns: 1fr; }
  .spatial-board { grid-template-columns: 1fr; }
  .story-board { grid-template-columns: 1fr; }
  .category-board { grid-template-columns: 1fr; }
  .pattern-board { grid-template-columns: 1fr; }
  .quantity-board { grid-template-columns: 1fr; }
  .syllable-board { grid-template-columns: 1fr; }
  .photo-quiz-board, .functional-choice-board { grid-template-columns: 1fr; }
  .player-header { align-items: flex-start; }
  .stimulus-controls { flex-wrap: wrap; justify-content: flex-end; }
  .control-chip { padding: 0 9px; font-size: 8px; }
  .shape-bank, .target-bank { min-height: 225px; padding: 19px 12px; }
  .shape-row { min-height: 125px; gap: 10px; }
  .match-shape, .match-target { width: 76px; height: 76px; }
  .shape-triangle { height: 72px; }
  .sequence-source, .sequence-targets { min-height: 250px; padding: 18px 10px; }
  .routine-card, .routine-slot { min-height: 140px; padding: 12px 5px; }
  .routine-icon { transform: scale(.75); }
  .memory-stage, .memory-options { min-height: 245px; padding: 18px 10px; }
  .memory-symbol { width: 74px; height: 74px; border-radius: 18px; }
  .memory-symbol i { transform: scale(.72); }
  .memory-continue { position: static; justify-self: stretch; }
  .emotion-scene, .emotion-choices { min-height: 280px; padding: 20px 14px; }
  .emotion-continue { position: static; justify-self: stretch; }
  .spatial-prompt, .spatial-grid-wrap { min-height: 300px; padding: 20px 14px; }
  .spatial-prompt h2 { margin-top: 20px; font-size: 24px; }
  .spatial-grid { width: min(310px, 100%); }
  .spatial-continue { position: static; justify-self: stretch; }
  .story-source, .story-target { min-height: 285px; padding: 18px 10px; }
  .story-card, .story-slots button { min-height: 170px; }
  .story-art { transform: scale(.78); }
  .category-items, .category-targets { min-height: 300px; padding: 18px 10px; }
  .category-item { min-height: 120px; }
  .pattern-stage, .pattern-options { min-height: 260px; padding: 20px 12px; }
  .pattern-token { width: 62px; height: 62px; }
  .pattern-symbol { transform: scale(.78); }
  .pattern-continue { position: static; justify-self: stretch; }
  .quantity-stage, .quantity-options { min-height: 250px; padding: 20px 12px; }
  .count-object { width: 52px; height: 52px; }
  .quantity-continue { position: static; justify-self: stretch; }
  .syllable-stage, .syllable-options { min-height: 260px; padding: 20px 12px; }
  .syllable-continue { position: static; justify-self: stretch; }
  .photo-quiz-prompt, .photo-quiz-options, .functional-choice-prompt, .functional-choice-area { min-height: 280px; padding: 20px 12px; }
  .photo-option-grid { grid-template-columns: 1fr; min-height: auto; }
  .photo-option { min-height: 150px; flex-direction: row; justify-content: flex-start; padding: 12px; }
  .photo-option .real-photo { width: 110px; flex: 0 0 auto; }
  .photo-quiz-continue { position: static; justify-self: stretch; }
  .functional-choice-grid { grid-template-columns: 1fr; min-height: auto; }
  .functional-choice-option { min-height: 120px; }
  .functional-choice-continue { position: static; justify-self: stretch; }
}

@media print {
  body * { visibility: hidden; }
  #reportPreview, #reportPreview * { visibility: visible; }
  #reportPreview { position: absolute; inset: 0; width: 100%; border: 0; box-shadow: none; }
}
