/* PsiTodoDia V5.43 — Identidade Natural
   Camada de apresentação isolada. Não altera JS, permissões, RLS, RPCs,
   posicionamento dos vídeos nem regras de consentimento V5.42. */
:root {
  --ink: #263d30;
  --muted: #617567;
  --line: #e2dfd4;
  --paper: #fcfaf6;
  --soft: #f5f1e8;
  --brand: #2e623c;
  --brand-soft: #edf0e5;
  --accent-gold: #e2d782;
  --accent-peach: #f3e8d5;
  --accent-rose: #eef1dc;
  --accent-mint: #e1f0df;
  --accent-sky: #ebf4e8;
  --shadow-soft: 0 14px 36px rgba(41, 77, 49, .075);
  --nature-background: url('/assets/media/leaf-sunlight.jpg');
  --nature-mark: url('/assets/media/leaf-mark.png');
}
html, body { background: #f4f0e6; }
body { color: var(--ink); font-family: "Avenir Next", "Segoe UI", system-ui, -apple-system, sans-serif; }
body::before, body::after { opacity: .25; }
h1,h2,h3 { font-family: "Avenir Next", "Segoe UI", system-ui, sans-serif; color: #23482f; letter-spacing: -.035em; }
button, a, input, textarea, select { accent-color: var(--brand); }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid #a4c684; outline-offset: 2px;
}
.primary, .icon-btn, .date-btn.active { background: linear-gradient(130deg,#346e43,#275a35); color: #fff; }
.secondary { background: #e8f2e5; color: #285638; }
.primary:hover:not(:disabled), .secondary:hover:not(:disabled), .mock-shortcut:hover:not(:disabled) { filter: brightness(1.035); }
.pill, .secure-chip { background: #edf0e5; color: #2b603a; }
.eyebrow { color: #507f51; letter-spacing: .11em; }

/* Identidade: usa a folha fornecida, sem substituir por um emoji genérico. */
.brand { font-family: "Avenir Next", "Segoe UI", system-ui, sans-serif; font-weight: 790; letter-spacing: -.045em; color: #23462e; }
.brand-mark { object-fit: contain; filter: drop-shadow(0 5px 9px rgba(67,110,37,.12)); }
.sidebar-brand { font-size: clamp(21px, 2vw, 26px); gap: 7px; }
.sidebar-brand-mark { width: 45px; height: 45px; flex-basis: 45px; }
.header-brand-mark { width: 39px; height: 39px; flex-basis: 39px; }

/* Login: fotografia original de folhas e card claro legível. */
.auth-gate,
.auth-gate:not(.hidden) {
  min-height: 100vh;
  min-height: 100dvh;
  padding: clamp(16px, 4vw, 48px) 16px;
  background: linear-gradient(115deg,rgba(241,248,230,.18),rgba(246,250,240,.53)), var(--nature-background) center center / cover no-repeat fixed !important;
}
.auth-card {
  width: min(100%, 458px);
  min-width: 0;
  padding: clamp(22px,4vw,34px);
  border-radius: 26px;
  background: rgba(252,249,243,.95) !important;
  border: 1px solid rgba(255,255,255,.86);
  box-shadow: 0 28px 82px rgba(31,68,33,.2), 0 4px 24px rgba(46,82,45,.08);
  backdrop-filter: blur(19px); -webkit-backdrop-filter: blur(19px);
}
.auth-brand { justify-content: center; font-size: 31px; gap: 9px; margin: 0 auto; }
.auth-brand-mark { width: 62px; height: 62px; flex-basis: 62px; }
.nature-login-tagline { text-align: center; color: #526b50 !important; font-size: 13px !important; margin: -10px 0 9px !important; font-weight: 500; }
.auth-card .eyebrow { color: #507b4a; }
.auth-card h1 { font-size: clamp(26px,4vw,32px); }
.auth-card p { line-height: 1.48; }
.auth-card label { color: #395643; }
.auth-card input, .auth-card select { background: rgba(255,251,245,.96) !important; border-color: #dddccc !important; }
.auth-card input:focus, .auth-card select:focus { border-color: #729c70 !important; box-shadow: 0 0 0 3px rgba(100,157,81,.15) !important; }
.auth-card .primary { box-shadow: 0 10px 20px rgba(40,87,45,.18); }
.auth-forgot-link, .text-btn, .back-btn, .section-link { color: #326c41; }

/* Workspace: leve, funcional, sem fotografia atrás dos textos clínicos. */
.app-shell { background: linear-gradient(180deg,#f7f3eb,#f0ece1) !important; }
.workspace-sidebar {
  background: rgba(252,249,243,.97) !important;
  border: 1px solid #e4dfd3;
  border-radius: 25px;
  box-shadow: 0 16px 38px rgba(39,74,41,.065);
  overflow: hidden;
}
.sidebar-link { color: #536b56; background: transparent; border-color: transparent; border-radius: 13px; }
.sidebar-link span { color: #567b50; }
.sidebar-link:hover { background: #f2efe4; }
.sidebar-link.active { color: #214f32; background: #ecebdd; border-color: #ddd8ca; box-shadow: inset 3px 0 0 #4f8e4d; }
.sidebar-link.active span { color: #2e623c; }
.sidebar-nature-note {
  display: flex; align-items: end; min-height: 145px; padding: 20px 14px 14px;
  border-radius: 19px; border: 1px solid #e3dece;
  background: linear-gradient(0deg,rgba(240,247,228,.98),rgba(241,248,229,.73) 53%,rgba(255,255,255,.30)), var(--nature-background) 25% 23% / cover;
}
.sidebar-nature-note span { max-width: 185px; font: italic 16px/1.36 Georgia,serif; color: #345e35; text-shadow:0 1px 6px #fff; }
.app-header {
  background: rgba(252,249,244,.95) !important;
  border: 1px solid #e0e8dd;
  box-shadow: 0 9px 25px rgba(36,71,39,.035);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.workspace-search { background: #f7f3ea; border-color: #e2ddd1; }
.workspace-search input { color: #2b4835; }
.profile-pill { background: #f7f3ea; border-color: #e3ddd1; }
.profile-avatar, .avatar { background: #e9f2e2; color: #346c3e; }
.profile-pill strong, .mock-shortcut strong { color: #284934; }
.app-main { color: #263d30; }

/* O mesmo cenário natural aparece apenas em banners e espaços decorativos. */
.hero-card.clinical-hero {
  position: relative; isolation: isolate; min-height: 196px;
  align-items: center; border: 1px solid #e0e9d8;
  border-radius: 25px; color: #224431;
  background: linear-gradient(90deg,rgba(252,249,242,.97) 0%,rgba(250,247,239,.94) 37%,rgba(251,250,243,.64) 72%,rgba(248,246,235,.40) 100%), var(--nature-background) 34% 32% / cover no-repeat !important;
  box-shadow: 0 17px 39px rgba(45,74,38,.09);
}
.hero-card.clinical-hero::before { content: none !important; }
.hero-card.clinical-hero h1 { color: #234b2e; font-size: clamp(26px,3vw,37px); line-height: 1.1; max-width: 600px; }
.hero-card.clinical-hero p { color: #526b4c; font-size: 14px; max-width: 550px; }
.hero-card.clinical-hero .eyebrow { color: #54814d; }
.hero-card.clinical-hero .hero-stat {
  background: rgba(251,248,241,.86); border: 1px solid rgba(215,216,195,.96);
  box-shadow: 0 9px 23px rgba(35,70,36,.07); backdrop-filter: blur(7px);
  min-width: 114px; flex-shrink: 0; color: #275a37;
}
.hero-stat span { color: #526a55; }
.screen[data-screen="patients"] > .screen-title-row {
  background: linear-gradient(90deg,rgba(252,249,243,.98),rgba(250,247,240,.90) 45%,rgba(249,247,239,.62)), var(--nature-background) 35% 30% / cover no-repeat !important;
  border-color: #e0e9d8;
}
.screen[data-screen="patients"]::after { background-image: var(--nature-mark); }

/* Cards, métricas e controles coerentes em todas as áreas do app. */
.app-shell .card, .app-shell .metric-card, .app-shell .appointment-card,
.app-shell .patient-card, .app-shell .status-card, .app-shell .timeline-item,
.app-shell .session-history-row, .app-shell .insight-card, .app-shell .online-link-card,
.app-shell .form-card, .app-shell .post-session-card, .app-shell .clinical-field {
  background: rgba(252,250,246,.98);
  border-color: #e1eadd;
  box-shadow: 0 8px 25px rgba(38,79,41,.045);
}
.app-shell .metric-card, .app-shell .quick-card, .app-shell .mode-card,
.app-shell .mock-shortcut { background: linear-gradient(145deg,#fcfaf5,#f3efe4) !important; border: 1px solid #e1ddd2; box-shadow: 0 9px 23px rgba(48,85,41,.055); }
.app-shell .mock-shortcut.warm { background: linear-gradient(145deg,#f5f1df,#fcfaf4) !important; }
.app-shell .mock-shortcut.mint { background: linear-gradient(145deg,#edf3e5,#fcfaf4) !important; }
.app-shell .mock-shortcut.peach { background: linear-gradient(145deg,#f4efe2,#fcfaf4) !important; }
.app-shell .mock-shortcut.cream { background: linear-gradient(145deg,#f5f0de,#fcfaf4) !important; }
.app-shell .mock-shortcut span { color: #3f7c40; }
.app-shell .mock-shortcut:hover:not(:disabled) { transform: translateY(-2px); border-color: #bbd5ad; }
.app-shell .clinical-overview-grid .metric-card:nth-child(n) { background: linear-gradient(150deg,#fcfaf5,#f2eee4) !important; }
.app-shell .metric-card strong, .app-shell .admin-metric strong { color: #2d623c; }
.app-shell .avatar.warm { background: #e9f2e3; color: #3a6c3d; }
.app-shell .focus-list li::before { background: #e6f1df; color: #346e40; }
.app-shell .profile-avatar-floral { background: #e8f2df; }
.app-shell .clinical-tabs { background: rgba(245,241,233,.97); }
.app-shell .clinical-tab.active { border-color: #bcd3b0; }
.app-shell .admin-privacy-banner { background: #f0efe5; border-color: #ddd9c8; color: #325c3e; }
.app-shell .admin-redacted-card { background: #fcfaf6; }
.app-shell .new-patient-action { background: linear-gradient(135deg,#346f42,#295d36) !important; box-shadow: 0 12px 25px rgba(38,104,54,.20),0 0 0 4px rgba(218,237,193,.25) !important; }
.app-shell input:not([type="radio"]):not([type="checkbox"]), .app-shell select, .app-shell textarea { border-color: #dce6d6; }
.app-shell input:focus, .app-shell select:focus, .app-shell textarea:focus { border-color: #7cac76; }
.bottom-nav { background: rgba(251,248,242,.97); border-color: #dfdbce; box-shadow: 0 -7px 26px rgba(42,72,37,.075); }
.bottom-nav .nav-item.active { background: #ecebdd; color: #285d36; }

/* A tela do paciente mantém seus controles de chamada e consentimento. Só entrada/saída são temáticas. */
body.patient-room-body:not(.patient-call-active) {
  background: linear-gradient(115deg,rgba(245,250,237,.76),rgba(247,251,240,.90)),var(--nature-background) center/cover fixed no-repeat !important;
}
body.patient-room-body:not(.patient-call-active) .patient-join-card {
  border-color: #d8e7d2 !important;
  background: rgba(252,249,243,.97) !important;
  box-shadow: 0 22px 62px rgba(31,73,39,.17) !important;
}
.patient-nature-brand { font-size: 29px; gap: 8px; }
.patient-nature-brand .brand-mark { width: 52px; height: 52px; flex-basis: 52px; }
.patient-join-card .auth-tagline { color: #598054; }
body.patient-room-body:not(.patient-call-active) .patient-farewell-card {
  background: linear-gradient(180deg,rgba(252,249,243,.90),rgba(249,246,238,.97)),var(--nature-background) center / cover no-repeat !important;
  border-color: #d9e9d4;
}
.patient-farewell-card::before { background: var(--nature-mark) center / contain no-repeat; }

@media(max-width: 760px) {
  .auth-gate { background-attachment: scroll !important; padding: max(12px,env(safe-area-inset-top)) 12px max(16px,env(safe-area-inset-bottom)) !important; }
  .auth-card { width: min(100%,470px); padding: 23px 19px; border-radius: 22px; }
  .auth-brand { font-size: 28px; }
  .auth-brand-mark { width: 54px; height: 54px; flex-basis: 54px; }
  .app-header { border-radius: 0 0 19px 19px; border-top: 0; border-left: 0; border-right: 0; }
  .header-brand-mark { width: 35px; height: 35px; flex-basis: 35px; }
  .hero-card.clinical-hero { min-height: 176px; gap: 12px; padding: 18px !important; flex-wrap: wrap; background-position: 29% center !important; }
  .hero-card.clinical-hero h1 { font-size: clamp(24px,6vw,31px); }
  .hero-card.clinical-hero .hero-stat { min-width: 100px; width: auto; margin-left: auto; }
  .screen[data-screen="patients"] > .screen-title-row { background-position: 33% 25% !important; }
  body.patient-room-body:not(.patient-call-active) { background-attachment: scroll !important; }
}
@media(max-width:420px) {
  .hero-card.clinical-hero { align-items: flex-start; }
  .hero-card.clinical-hero .hero-stat { padding: 8px 12px; min-width: 90px; }
  .hero-card.clinical-hero .hero-stat strong { font-size: 25px; }
  .sidebar-nature-note { display: none; }
}
@media(prefers-reduced-motion:reduce) { .app-shell .mock-shortcut { transition: none; transform: none !important; } }

/* Ajustes finais de precedência: a V5.42 continha regras neutras !important.
   São substituídas somente por propriedades cromáticas, sem tocar em layout crítico. */
.auth-card button.primary,
.app-shell button.primary,
.app-shell .primary { background: linear-gradient(135deg,#367246,#285b38) !important; color:#fff !important; }
.auth-card button.primary:hover:not(:disabled),
.app-shell button.primary:hover:not(:disabled),
.app-shell .primary:hover:not(:disabled) { background: linear-gradient(135deg,#3e7b4c,#2e6540) !important; }
.auth-card button.secondary,
.app-shell button.secondary,
.app-shell .secondary { background:#eceee2 !important;color:#285c38 !important; }
.app-shell button.ghost, .app-shell .ghost { background:#f0eee4 !important; color:#42614a !important; }
.app-shell .sidebar-link.nav-item.active, .app-shell .sidebar-link.active { background:#ecebdd !important;color:#29583a !important; }
.app-shell .bottom-nav .nav-item.active { background:#ecebdd !important; color:#275a38 !important; }
.app-shell .mock-shortcut span { color:#437e4c !important; }
.app-shell .profile-avatar-plain { background:#ecefe2 !important;color:#2e603b !important; }
.app-shell .brand-mark, .auth-card .brand-mark, .patient-nature-brand .brand-mark {
  border-radius: 0 !important; object-fit: contain !important;
}
.app-shell .sidebar-brand-mark { width:43px !important;height:43px !important; }
.app-shell .header-brand-mark { width:37px !important;height:37px !important; }
.auth-card .auth-brand-mark { width:61px !important;height:61px !important; }
.app-shell .clinical-tabs { background: rgba(245,241,233,.97) !important; }
.app-shell input:focus, .app-shell select:focus, .app-shell textarea:focus,
.auth-card input:focus, .auth-card select:focus { border-color:#79a46d !important;box-shadow:0 0 0 3px rgba(86,141,75,.16) !important; }
.auth-card input[type="email"], .auth-card input[type="password"], .auth-card input[type="text"],.auth-card input[type="tel"],.auth-card select {
  background:rgba(255,251,246,.97) !important;border-color:#dfdccf !important;
}
/* O fundo da sala de convite era neutralizado em duas regras legadas !important. */
body.patient-room-body:not(.patient-call-active) {
  background:linear-gradient(110deg,rgba(246,242,233,.66),rgba(248,245,238,.90)), var(--nature-background) center / cover fixed no-repeat !important;
}
body.patient-room-body:not(.patient-call-active) .patient-room-shell { background:transparent !important; background-image:none !important; }
body.patient-room-body:not(.patient-call-active) #patientJoinBtn {
  background:#2e623c !important;color:#fff !important;
}
body.patient-room-body:not(.patient-call-active) .patient-nature-brand .brand-mark { width:52px !important;height:52px !important; }
@media(max-width:760px) {
  .app-shell .header-brand-mark { width:31px !important;height:31px !important; }
  .auth-card .auth-brand-mark { width:58px !important;height:58px !important; }
  body.patient-room-body:not(.patient-call-active) { background-attachment:scroll !important; }
}


/* V5.45 — refinamento acolhedor/natural */
:root {
  --paper: #fbf7f0;
  --soft: #f3efe5;
  --brand-soft: #ebe9dc;
  --accent-peach: #eadcc6;
  --accent-rose: #ece7d6;
  --accent-mint: #e3ecdf;
}
body, .app-shell .notice-card, .app-shell .settings-card { color:#2c4031; }
.app-shell .card, .app-shell .metric-card, .app-shell .appointment-card,
.app-shell .patient-card, .app-shell .status-card, .app-shell .timeline-item,
.app-shell .session-history-row, .app-shell .insight-card, .app-shell .online-link-card,
.app-shell .form-card, .app-shell .post-session-card, .app-shell .clinical-field,
.app-shell .notice-card, .app-shell .settings-card, .app-shell .profile-settings-shortcut {
  background: linear-gradient(180deg, rgba(252,249,243,.98), rgba(248,244,236,.98)) !important;
  border-color:#e5dfd3 !important;
}
.app-shell .section-block, .app-shell .screen-title-row, .app-shell .finance-toolbar {
  border-color:#e4ddd0;
}
.app-shell .section-heading h2, .app-shell .screen-title-row h1, .app-shell .notice-card h2 { color:#2c4a32; }
.notice-card p, .muted-copy { color:#5f6f5e; }
.workspace-sidebar, .app-header { box-shadow: 0 14px 34px rgba(60,72,42,.055); }
.sidebar-nature-note { background: linear-gradient(0deg,rgba(241,235,223,.94),rgba(241,245,230,.72) 53%,rgba(255,255,255,.28)), var(--nature-background) 25% 23% / cover; }
.hero-card.clinical-hero .hero-stat, .workspace-search, .profile-pill, .pill, .secure-chip {
  background: rgba(248,244,236,.92) !important;
  border-color:#e3dbc8 !important;
}
.app-shell .mock-shortcut { border-radius:18px; }
.app-shell .mock-shortcut strong { color:#35553d; }
.app-shell .profile-settings-shortcut { background: linear-gradient(180deg,#fcf9f2,#f5efe3) !important; }
.auth-card { box-shadow: 0 24px 70px rgba(46,68,38,.17), 0 4px 18px rgba(80,89,56,.06); }
.error-log-item { background: rgba(251,248,242,.92); border:1px solid #e4ddd0; border-radius:16px; padding:14px; }
.error-log-item + .error-log-item { margin-top: 12px; }
.error-log-item-head { display:flex; justify-content:space-between; gap:16px; align-items:flex-start; margin-bottom:8px; }
.error-log-item-head strong { color:#31543b; }
.error-log-meta { display:flex; flex-wrap:wrap; gap:8px; margin-top:10px; }
.error-log-meta span { background:#ecebdd; color:#47614e; border-radius:999px; padding:6px 10px; font-size:12px; font-weight:600; }
.error-log-list { display:flex; flex-direction:column; gap:0; }


/* V5.46 — acolhedor com toque terapêutico mais sofisticado */
:root {
  --ink: #2a3f34;
  --muted: #667363;
  --paper: #faf5ee;
  --soft: #efe8dc;
  --line: #e2d7c8;
  --brand: #355d46;
  --brand-soft: #e8e3d4;
  --accent-gold: #cdb98d;
  --accent-peach: #e8dbc4;
  --accent-rose: #ebe3d3;
  --accent-mint: #dde7db;
  --accent-sky: #edf1e8;
  --shadow-soft: 0 18px 42px rgba(54,66,46,.08);
}
html, body { background: #efe8dc; }
body {
  color: var(--ink);
  letter-spacing: .001em;
}
h1,h2,h3 {
  color: #2e4737;
  letter-spacing: -.04em;
}
.eyebrow {
  color: #6d7d63;
  letter-spacing: .14em;
}
.brand { color:#2a4a38; }
.primary, .icon-btn, .date-btn.active {
  background: linear-gradient(135deg,#436b54,#2f5441) !important;
  box-shadow: 0 12px 24px rgba(47,84,65,.16);
}
.secondary {
  background: #ece7da !important;
  color: #355645 !important;
  border-color: #ded4c4 !important;
}
.pill, .secure-chip {
  background: #ece6d8 !important;
  color: #43624f !important;
  border: 1px solid #dfd2bf;
}
.auth-gate,
.auth-gate:not(.hidden) {
  background: linear-gradient(115deg,rgba(243,235,223,.36),rgba(247,242,235,.62)), var(--nature-background) center center / cover no-repeat fixed !important;
}
.auth-card {
  background: linear-gradient(180deg, rgba(251,247,240,.96), rgba(246,240,231,.94)) !important;
  border: 1px solid rgba(230,220,202,.92);
  box-shadow: 0 28px 78px rgba(52,66,45,.16), 0 4px 18px rgba(80,76,57,.05);
}
.nature-login-tagline { color:#6f7660 !important; }
.auth-card input, .auth-card select {
  background: rgba(255,252,247,.94) !important;
  border-color: #ded4c6 !important;
}
.app-shell {
  background: linear-gradient(180deg,#f3ede3,#ece4d6) !important;
}
.workspace-sidebar,
.app-header {
  background: linear-gradient(180deg, rgba(251,247,240,.97), rgba(246,240,231,.95)) !important;
  border-color: #e3d8c8 !important;
  box-shadow: 0 14px 34px rgba(67,74,54,.06);
}
.sidebar-link { color:#596a5b; }
.sidebar-link span { color:#6b7f65; }
.sidebar-link:hover { background:#f3ecdf; }
.sidebar-link.active,
.app-shell .sidebar-link.nav-item.active, .app-shell .sidebar-link.active {
  background: linear-gradient(180deg,#ebe7da,#e6e2d4) !important;
  border-color:#d9cfbf !important;
  box-shadow: inset 3px 0 0 #608566 !important;
  color:#2d4d3b !important;
}
.sidebar-nature-note {
  border-color:#e1d6c5;
  background: linear-gradient(0deg,rgba(240,232,219,.96),rgba(239,242,228,.70) 54%,rgba(255,255,255,.26)), var(--nature-background) 25% 23% / cover;
}
.sidebar-nature-note span {
  color:#4d604f;
  font: italic 16px/1.45 Georgia,serif;
}
.workspace-search,
.profile-pill,
.hero-card.clinical-hero .hero-stat {
  background: rgba(248,242,234,.92) !important;
  border-color:#e2d7c8 !important;
}
.hero-card.clinical-hero {
  background: linear-gradient(90deg,rgba(250,246,239,.97) 0%,rgba(247,242,234,.94) 38%,rgba(244,241,233,.68) 72%,rgba(240,236,224,.46) 100%), var(--nature-background) 34% 32% / cover no-repeat !important;
  border-color:#e0d5c5;
  box-shadow: 0 18px 40px rgba(64,68,42,.08);
}
.hero-card.clinical-hero h1 { color:#2d4737; }
.hero-card.clinical-hero p,
.hero-stat span,
.notice-card p, .muted-copy { color:#687465; }
.app-shell .card, .app-shell .metric-card, .app-shell .appointment-card,
.app-shell .patient-card, .app-shell .status-card, .app-shell .timeline-item,
.app-shell .session-history-row, .app-shell .insight-card, .app-shell .online-link-card,
.app-shell .form-card, .app-shell .post-session-card, .app-shell .clinical-field,
.app-shell .notice-card, .app-shell .settings-card, .app-shell .profile-settings-shortcut,
.app-shell .finance-toolbar {
  background: linear-gradient(180deg, rgba(250,246,239,.98), rgba(244,238,229,.98)) !important;
  border-color:#e4d9ca !important;
  box-shadow: 0 10px 26px rgba(70,75,50,.045);
}
.app-shell .metric-card, .app-shell .quick-card, .app-shell .mode-card, .app-shell .mock-shortcut {
  background: linear-gradient(145deg,#faf6ee,#f1eadc) !important;
  border-color:#e2d6c6 !important;
}
.app-shell .mock-shortcut.warm { background: linear-gradient(145deg,#f4ebd8,#faf6ed) !important; }
.app-shell .mock-shortcut.mint { background: linear-gradient(145deg,#e7eee0,#faf6ed) !important; }
.app-shell .mock-shortcut.peach { background: linear-gradient(145deg,#f1e6d6,#faf6ed) !important; }
.app-shell .mock-shortcut.cream { background: linear-gradient(145deg,#f1ebd7,#faf6ed) !important; }
.app-shell .mock-shortcut,
.app-shell .metric-card,
.app-shell .notice-card,
.app-shell .profile-settings-shortcut,
.error-log-item { border-radius: 18px; }
.app-shell .mock-shortcut strong,
.app-shell .metric-card strong,
.app-shell .admin-metric strong,
.error-log-item-head strong { color:#365442; }
.app-shell .profile-avatar-plain,
.profile-avatar, .avatar { background:#e8e2d6 !important; color:#365845 !important; }
.app-shell input:not([type="radio"]):not([type="checkbox"]), .app-shell select, .app-shell textarea,
.auth-card input[type="email"], .auth-card input[type="password"], .auth-card input[type="text"],.auth-card input[type="tel"],.auth-card select {
  background: rgba(255,252,247,.96) !important;
  border-color:#dfd4c6 !important;
}
.app-shell input:focus, .app-shell select:focus, .app-shell textarea:focus,
.auth-card input:focus, .auth-card select:focus {
  border-color:#8ba48d !important;
  box-shadow: 0 0 0 3px rgba(126,153,127,.16) !important;
}
.bottom-nav {
  background: rgba(249,244,236,.97) !important;
  border-color:#e1d6c6;
}
.app-shell .bottom-nav .nav-item.active {
  background:#e8e4d7 !important;
  color:#31513f !important;
}
.patient-join-card, body.patient-room-body:not(.patient-call-active) .patient-join-card {
  background: linear-gradient(180deg, rgba(251,247,240,.96), rgba(246,240,231,.96)) !important;
  border-color:#e2d7c8 !important;
}
body.patient-room-body:not(.patient-call-active) {
  background: linear-gradient(110deg,rgba(243,236,225,.70),rgba(248,244,236,.90)), var(--nature-background) center / cover fixed no-repeat !important;
}
.error-log-meta span {
  background:#e8e2d6;
  color:#516553;
  border:1px solid #d8ccba;
}


/* V5.47 — microdetalhes finos */
:root {
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
}
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body { text-rendering: optimizeLegibility; }
h1 { font-weight: 760; }
h2 { font-weight: 720; }
h3 { font-weight: 680; }
.brand, .auth-brand, .sidebar-brand { letter-spacing: -.05em; }
.eyebrow { font-weight: 700; font-size: 11px; }
.app-header,
.workspace-sidebar,
.auth-card,
.hero-card.clinical-hero,
.app-shell .card,
.app-shell .metric-card,
.app-shell .appointment-card,
.app-shell .patient-card,
.app-shell .status-card,
.app-shell .timeline-item,
.app-shell .session-history-row,
.app-shell .insight-card,
.app-shell .online-link-card,
.app-shell .form-card,
.app-shell .post-session-card,
.app-shell .clinical-field,
.app-shell .notice-card,
.app-shell .settings-card,
.app-shell .profile-settings-shortcut,
.app-shell .finance-toolbar,
.patient-join-card,
.error-log-item {
  border-radius: var(--radius-md) !important;
}
.auth-card,
.workspace-sidebar,
.hero-card.clinical-hero,
.app-header { border-radius: var(--radius-lg) !important; }
.section-heading,
.screen-title-row,
.dialog-head {
  margin-bottom: 14px;
}
.section-heading h2,
.screen-title-row h1,
.notice-card h2,
.dialog-head h2 {
  letter-spacing: -.035em;
}
.section-heading .eyebrow,
.screen-title-row .eyebrow,
.dialog-head .eyebrow { margin-bottom: 4px; display:inline-block; }
button,
.primary,
.secondary,
.ghost,
.sidebar-link,
.mock-shortcut,
.profile-pill,
.section-link,
.auth-forgot-link,
.admin-hub-tab,
.bottom-nav .nav-item {
  transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease, filter .18s ease;
}
button:active,
.primary:active,
.secondary:active,
.ghost:active,
.mock-shortcut:active { transform: translateY(0); }
.primary,
.secondary,
.ghost,
.section-link,
.inline-link,
.auth-forgot-link,
.bottom-nav .nav-item,
.sidebar-link,
.admin-hub-tab {
  font-weight: 650;
}
.primary,
.secondary,
.ghost,
button.compact,
.profile-pill,
.workspace-search,
.pill,
.secure-chip,
.error-log-meta span,
.admin-tab-badge {
  border-radius: 999px !important;
}
.primary,
.secondary,
.ghost { padding-inline: 16px; }
button.compact { padding-inline: 12px; }
.app-shell .card,
.app-shell .metric-card,
.app-shell .appointment-card,
.app-shell .patient-card,
.app-shell .status-card,
.app-shell .timeline-item,
.app-shell .session-history-row,
.app-shell .insight-card,
.app-shell .online-link-card,
.app-shell .form-card,
.app-shell .post-session-card,
.app-shell .clinical-field,
.app-shell .notice-card,
.app-shell .settings-card,
.app-shell .profile-settings-shortcut,
.app-shell .finance-toolbar {
  box-shadow: 0 10px 24px rgba(72,74,54,.038), 0 1px 0 rgba(255,255,255,.72) inset !important;
}
.app-shell .card:hover,
.app-shell .metric-card:hover,
.app-shell .patient-card:hover,
.app-shell .online-link-card:hover,
.app-shell .mock-shortcut:hover {
  box-shadow: 0 16px 30px rgba(72,74,54,.06), 0 1px 0 rgba(255,255,255,.72) inset !important;
}
.workspace-search input::placeholder,
input::placeholder,
textarea::placeholder { color:#889284; }
.workspace-search { padding-left: 12px; }
.profile-pill { gap: 10px; }
.profile-pill strong { font-size: 14px; }
.profile-pill small { font-size: 12px; color:#728074; }
.sidebar-link { min-height: 46px; }
.sidebar-link strong,
.bottom-nav .nav-item strong { font-weight: 650; }
.sidebar-link.active,
.app-shell .bottom-nav .nav-item.active {
  box-shadow: inset 3px 0 0 #608566, 0 6px 16px rgba(84,98,71,.08) !important;
}
.bottom-nav .nav-item { border-radius: 14px; }
.bottom-nav .nav-item span,
.sidebar-link span,
.mock-shortcut span { opacity: .92; }
.hero-card.clinical-hero { overflow: hidden; }
.hero-card.clinical-hero::after {
  content:'';
  position:absolute;
  inset:auto -20px -20px auto;
  width:140px;
  height:140px;
  background: radial-gradient(circle at center, rgba(205,185,141,.15), transparent 68%);
  pointer-events:none;
}
.hero-card.clinical-hero .hero-stat {
  box-shadow: 0 8px 18px rgba(64,73,50,.06);
}
.mock-shortcuts { gap: 12px; }
.app-shell .mock-shortcut { padding: 16px 18px; }
.app-shell .mock-shortcut strong { font-size: 14px; }
.metric-card span,
.setting-line span,
.finance-summary article span { font-size: 12px; font-weight: 700; letter-spacing: .02em; color:#73806f; }
.metric-card strong,
.finance-summary article strong,
.hero-stat strong { letter-spacing: -.03em; }
.section-block,
.finance-summary,
.focus-grid,
.clinical-overview-grid,
.admin-metrics-grid { gap: 16px; }
.setting-line {
  padding: 10px 0;
  border-bottom: 1px solid rgba(216,206,189,.55);
}
.setting-line:last-child { border-bottom: 0; }
.dialog-body,
.startup-sync-card,
.verification-wait-card { border-radius: 22px !important; }
.dialog-head p,
.muted-copy,
.privacy-note { line-height: 1.5; }
.clinical-tabs,
.finance-filter-switch { padding: 5px; border-radius: 18px; }
.clinical-tab,
.finance-filter-switch button,
.admin-hub-tab {
  border-radius: 14px !important;
  font-weight: 650;
}
.clinical-tab.active,
.finance-filter-switch button.active,
.admin-hub-tab.active {
  box-shadow: 0 8px 16px rgba(86,94,69,.08);
}
.error-log-item p { color:#58665a; line-height:1.5; }
.error-log-item-head small { color:#7d887d; font-weight:600; }
.error-log-meta { gap: 10px; }
.admin-usage-row,
.admin-crp-review-item {
  border-radius: 16px;
  border: 1px solid #e1d7c8;
  background: linear-gradient(180deg, rgba(250,246,239,.98), rgba(244,238,229,.98));
  padding: 14px;
}
.admin-crp-review-actions,
.button-row,
.conflict-actions,
.recovery-actions { gap: 10px; }
.patient-room-body .patient-farewell-card,
body.patient-room-body:not(.patient-call-active) .patient-farewell-card {
  border-radius: 24px !important;
  box-shadow: 0 18px 40px rgba(62,70,48,.10) !important;
}
@media (max-width:760px) {
  .mock-shortcuts { gap: 10px; }
  .app-shell .mock-shortcut { padding: 14px 16px; }
  .section-block,
  .finance-summary,
  .focus-grid,
  .clinical-overview-grid,
  .admin-metrics-grid { gap: 14px; }
  .workspace-search { min-height: 42px; }
}
