/* All overrides are confined to the GHL view. Standalone styles are untouched. */
html.ghl-embedded {
  --ghl-font: Roboto, system-ui, -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
  --cream: #fff;
  --bg: #fff;
  --text: #182230;
  --border: #e4e7ec;
  --sidebar-w: 0px;
}
html.ghl-embedded body {
  display: block;
  background: var(--bg);
  color: var(--text);
  font-family: var(--ghl-font) !important;
  font-size: 14px;
}
html.ghl-embedded body :is(h1,h2,h3,h4,button,input,select,textarea,.btn,.stat-value,.stat-label,.page-h) {
  font-family: var(--ghl-font) !important;
  letter-spacing: normal;
}
html.ghl-embedded body > .sidebar,
html.ghl-embedded .main > .topbar,
html.ghl-embedded #mob-overlay { display: none !important; }
html.ghl-embedded body > .main {
  width: 100%; max-width: none; min-width: 0; margin: 0 !important;
}
html.ghl-embedded .main > .content {
  box-sizing: border-box; width: 100%; min-width: 0;
  padding: 24px !important; max-width: none; margin: 0;
  background: #fff !important;
}
html.ghl-embedded .ghl-workspace-nav {
  display: flex; align-items: center; gap: 4px; padding: 24px 24px 0;
  min-height: 48px; overflow-x: auto; background: #fff;
  border-bottom: 1px solid var(--border); scrollbar-width: thin;
}
html.ghl-embedded .ghl-workspace-nav a {
  display: inline-flex; align-items: center; min-height: 48px;
  padding: 0 13px; white-space: nowrap; border-bottom: 2px solid transparent;
  color: #667085; font-size: 13px; font-weight: 500; text-decoration: none;
}
html.ghl-embedded .ghl-workspace-nav a:hover { color: #155e6b; background: #f7fafb; }
html.ghl-embedded .ghl-workspace-nav a[aria-current=page] { color: #155e6b; border-bottom-color: #4f8795; }
html.ghl-embedded .ghl-workspace-account { margin-left: auto; padding: 0 12px; color: #667085; font-size: 12px; white-space: nowrap; }
html.ghl-embedded .ghl-workspace-heading {
  display: flex; justify-content: space-between; align-items: flex-start;
  flex-wrap: wrap; gap: 16px; margin: 0 0 22px;
}
html.ghl-embedded .ghl-workspace-heading h1 { margin: 0; font-size: 26px; line-height: 1.25; font-weight: 600; }
html.ghl-embedded .ghl-workspace-heading p { margin: 6px 0 0; color: #667085; font-size: 13px; line-height: 1.5; }
html.ghl-embedded .ghl-workspace-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-left: auto; justify-content: flex-end; }
html.ghl-embedded .content :is(.card,.stat-card) { border-color: var(--border); box-shadow: 0 1px 2px rgba(16,24,40,.03); }
html.ghl-embedded .content .page-header h1 { font-size: 26px; font-weight: 600; }
html.ghl-embedded .editor-grid { gap: 20px; }
html.ghl-embedded .editor-sidebar { top: 16px; }
@media (max-width: 1000px) {
  html.ghl-embedded .editor-grid { grid-template-columns: minmax(0,1fr) !important; }
  html.ghl-embedded .editor-sidebar { position: static !important; }
}
@media (max-width: 600px) {
  html.ghl-embedded .main > .content { padding: 16px !important; }
  html.ghl-embedded .ghl-workspace-nav { padding: 24px 8px 0; }
  html.ghl-embedded .ghl-workspace-heading h1 { font-size: 23px; }
  html.ghl-embedded .ghl-workspace-actions { width: 100%; }
  html.ghl-embedded .ghl-workspace-actions .btn { flex: 1; justify-content: center; }
}

/* Center the sign-in card within GHL without affecting standalone pages. */
html.ghl-embedded body:has(> .wrapper > .card) {
  display:flex; align-items:center; justify-content:center;
  min-height:100vh; min-height:100dvh; height:auto;
  padding:32px 24px; overflow-x:hidden; overflow-y:auto;
  background:#fff;
}
html.ghl-embedded body:has(> .wrapper > .card)::before,
html.ghl-embedded body:has(> .wrapper > .card)::after,
html.ghl-embedded body > .particle { display:none; }
html.ghl-embedded body > .wrapper { flex:0 1 420px; margin:auto; max-width:420px; }
html.ghl-embedded body > .wrapper > .card {
  border-radius:16px; box-shadow:0 8px 28px rgba(16,24,40,.08);
}
@media(max-width:480px), (max-height:640px) {
  html.ghl-embedded body:has(> .wrapper > .card) { padding:20px 16px; }
  html.ghl-embedded .wrapper .card-header { padding:24px 24px 20px; }
  html.ghl-embedded .wrapper .card-body { padding:24px; }
  html.ghl-embedded .wrapper .card-footer { padding:14px 24px; }
}
/* DR CEO interface theme: exclusively inside the verified GHL presentation. */
@font-face {
  font-family:'Geologica'; font-style:normal; font-weight:400 700;
  font-display:swap; src:url('geologica-latin-v1.woff2') format('woff2');
}
html.ghl-embedded,
html.ghl-embedded body {
  --ghl-font:'Geologica',system-ui,-apple-system,'Segoe UI',sans-serif;
  --gold:#7B83B3; --gold-dk:#555F94; --gold-light:#DDE0F0; --gold-pale:#F0F1F8;
  --blue:#555F94; --blue-pale:#F0F1F8; --blue-border:#DDE0F0;
  --r:16px; --r-lg:18px; --r-sm:10px;
  accent-color:#7B83B3;
}
html.ghl-embedded body,
html.ghl-embedded body :is(h1,h2,h3,h4,h5,h6,p,a,span,label,small,strong,th,td,button,input,select,textarea,.btn,.stat-value,.stat-label,.page-h) {
  font-family:var(--ghl-font) !important;
}
html.ghl-embedded .ghl-workspace-nav a { border-radius:10px 10px 0 0; }
html.ghl-embedded .ghl-workspace-nav a:hover { color:#555F94; background:#F0F1F8; }
html.ghl-embedded .ghl-workspace-nav a[aria-current=page] {
  color:#555F94; border-bottom-color:#7B83B3; background:#F0F1F8;
}
html.ghl-embedded :is(.card,.stat-card,.modal-content,.modal-box,.modal-card) { border-radius:16px; }
html.ghl-embedded :is(.card,.stat-card) { overflow:hidden; }
html.ghl-embedded :is(.btn,.btn-login,.copy-btn,.use-id-btn,.opcion-tab,.lang-toggle,.patient-search) { border-radius:10px; }
html.ghl-embedded :is(input:not([type=checkbox]):not([type=radio]),select,textarea) { border-radius:10px; }
html.ghl-embedded :is(.btn-gold,.btn-primary,.btn-login,.copy-btn,.use-id-btn),
html.ghl-embedded :is(.opcion-tab.active,.lang-btn.active,.lang-toggle .active) {
  background:#7B83B3; border-color:#7B83B3; color:#141A30;
  box-shadow:0 2px 5px rgba(85,95,148,.12);
}
html.ghl-embedded :is(.btn-gold,.btn-primary,.btn-login,.copy-btn,.use-id-btn):hover {
  background:#6E77A7; border-color:#6E77A7; color:#101526;
  box-shadow:0 3px 7px rgba(85,95,148,.16);
}
html.ghl-embedded .stat-card.highlight { background:#7B83B3; border-color:#7B83B3; }
html.ghl-embedded .stat-card.highlight :is(.stat-label,.stat-value,.stat-sub) { color:#141A30; }
html.ghl-embedded :is(input,select,textarea):focus-visible {
  outline:2px solid #555F94; outline-offset:2px;
  border-color:#7B83B3; box-shadow:0 0 0 3px rgba(123,131,179,.12);
}
html.ghl-embedded .wrapper .card-header::after { background:#7B83B3; }
html.ghl-embedded .wrapper :is(.input-icon,.brand-name,.toggle-pass:hover) { color:#555F94; }
html.ghl-embedded :is(.guide-blue,.guide-gold,.alert-info) {
  background:#F0F1F8; border-color:#DDE0F0; color:#414A76;
}html.ghl-embedded body > main :is(a,summary) { color:#555F94; }
html.ghl-embedded body > main :is(.back,.back-button,form,button) { border-radius:12px; }
html.ghl-embedded body > main button:not(.secondary) { background:#7B83B3; color:#141A30; }
html.ghl-embedded { scrollbar-color:#7B83B3 #F0F1F8; }
html.ghl-embedded ::-webkit-scrollbar-thumb { background-color:#7B83B3; border-radius:10px; }
/* Ads uses its own layout. Adapt it only inside GHL. */
html.ghl-embedded { color-scheme:light; }
html.ghl-embedded body {
  --bg:#fff; --surface:#fff; --surface2:#F7F8FC; --border:#E4E7EC;
  --text:#182230; --muted:#667085; --violet:#7B83B3; --violet2:#68709E;
  background:#fff; color:#182230;
}
html.ghl-embedded .app-shell { display:block; min-width:0; }
html.ghl-embedded .app-shell > .sidebar,
html.ghl-embedded .app-shell > main > header > .menu { display:none !important; }
html.ghl-embedded .app-shell > main {
  margin:0; width:100%; max-width:none; min-width:0; padding:0 24px 24px;
}
html.ghl-embedded .app-shell > main > .ghl-workspace-nav { margin:0 -24px; overflow:visible; flex-wrap:wrap; position:relative; z-index:20; }
html.ghl-embedded .app-shell > main > header {
  position:static; background:#fff; backdrop-filter:none; box-shadow:none;
  margin:0; padding:24px 0 0; min-height:72px; border:0; gap:16px; flex-wrap:wrap;
}
html.ghl-embedded main > header h1 { font-size:26px; font-weight:600; line-height:1.25; }
html.ghl-embedded .ghl-nav-group { position:relative; }
html.ghl-embedded .ghl-nav-group summary {
  cursor:pointer; padding:15px 13px; font-size:13px; font-weight:500;
  color:#667085; border-radius:10px 10px 0 0; list-style:none;
}
html.ghl-embedded .ghl-nav-group summary::after { content:'⌄'; margin-left:7px; }
html.ghl-embedded .ghl-nav-group[open] summary,
html.ghl-embedded .ghl-nav-group:has(a[aria-current=page]) summary { background:#F0F1F8; color:#555F94; }
html.ghl-embedded .ghl-nav-group > div {
  position:absolute; top:100%; left:0; min-width:200px; padding:6px;
  background:#fff; border:1px solid #E4E7EC; border-radius:12px;
  box-shadow:0 6px 20px rgba(16,24,40,.08); z-index:30;
}
html.ghl-embedded .ghl-nav-group > div a { display:flex; min-height:38px; border:0; border-radius:8px; }
html.ghl-embedded :is(.metrics article,.panel,.connector,.workflow,.login-card,.custom-select-menu,.conversation-drawer,.drawer-footer,.payload-view,.toast,.empty-chart) {
  background:#fff; color:#182230; border-color:#E4E7EC; border-radius:16px; box-shadow:0 1px 3px rgba(16,24,40,.04);
}
html.ghl-embedded :is(.metrics article:hover,.panel:hover) { border-color:#DDE0F0; box-shadow:0 1px 4px rgba(16,24,40,.05); }
html.ghl-embedded :is(.search,.profile-chip,.range-label,.payload-pre,.stepper,.custom-select-trigger,.drawer-close) {
  background:#F7F8FC; color:#344054; border-color:#E4E7EC;
}
html.ghl-embedded :is(.search input,main input:not([type=checkbox]):not([type=radio]):not([type=file]),main select,main textarea,.custom-select-option,.connection-form input,.connection-form textarea) {
  background-color:#fff; color:#182230; border-color:#D0D5DD; font-family:var(--ghl-font);
}
html.ghl-embedded :is(main select option,.custom-select-menu) { background:#fff; color:#182230; }
html.ghl-embedded :is(.button.primary,.pagination .page-num.active,.custom-select-option.selected) {
  background:#7B83B3; color:#171B2E; border-color:#7B83B3; box-shadow:0 2px 5px rgba(85,95,148,.12);
}
html.ghl-embedded .button.primary:hover { background:#68709E; color:#fff; transform:none; filter:none; }
html.ghl-embedded .button.ghost { background:#fff; color:#555F94; border-color:#DDE0F0; }
html.ghl-embedded :is(.button,.custom-select-trigger,.search,.pagination .page-btn,.pagination .page-num) { border-radius:10px; }
html.ghl-embedded :is(.eyebrow,.panel-head a,.stepper-btn,.header-actions a:hover) { color:#555F94; }
html.ghl-embedded :is(.detail-text,.text-soft,.connection-detail strong,.recommendation-body h4,.access-check,.table-note b,.empty-inbox b,.timeline-item b,.profile-chip) { color:#344054; }
html.ghl-embedded :is(.table-note,.notice,.drawer-status) { background:#F0F1F8; color:#414A76; border-color:#DDE0F0; }
html.ghl-embedded :is(.notice.warn,.badge.orange) { background:#FFF4DE; color:#855317; }
html.ghl-embedded :is(.notice.error,.error) { background:#FEF3F2; color:#B42318; border-color:#FECDCA; }
html.ghl-embedded :is(.metrics .good,.status.connected,.integrations-mini .status.connected,.wa-link) { color:#167347; }
html.ghl-embedded :is(.metrics .warn,.status.error,.integrations-mini .status.error) { color:#9B3B17; }
html.ghl-embedded table.sticky-first :is(th:first-child,td:first-child) { background:#fff; }
html.ghl-embedded .gridline { stroke:#DDE0F0; stroke-opacity:1; }
html.ghl-embedded :is(.avatar,.avatar-preview,.patient-avatar) { background:#E8EAF5; color:#414A76; box-shadow:none; }
html.ghl-embedded .table-wrap::-webkit-scrollbar-thumb { background:#7B83B3; }
html.ghl-embedded body.login-page { display:grid; place-items:center; padding:24px; min-height:100vh; min-height:100dvh; }
html.ghl-embedded body.login-page > main.login-card { margin:0; width:min(430px,100%); max-width:none; padding:32px; }
html.ghl-embedded .login-card :is(label,input) { color:#344054; }
html.ghl-embedded .login-card input { background:#fff; }
@media(max-width:760px) {
  html.ghl-embedded .app-shell > main { padding:0 16px 20px; }
  html.ghl-embedded .app-shell > main > .ghl-workspace-nav { margin:0 -16px; padding:20px 16px 0; }
  html.ghl-embedded .ghl-workspace-nav { gap:0; }
  html.ghl-embedded .ghl-nav-group summary { padding:13px 9px; }
  html.ghl-embedded .header-actions { flex-wrap:wrap; width:100%; }
  html.ghl-embedded .search { flex:1; }
}html.ghl-embedded .search input { border:0!important; background:transparent!important; box-shadow:none!important; padding:0!important; min-width:0; }
html.ghl-embedded .search:focus-within { border-color:#7B83B3; outline:2px solid #DDE0F0; outline-offset:1px; }html.ghl-embedded .login-logo { background:#555F94; border-radius:12px; min-height:94px; padding:18px 24px; margin-bottom:24px; }