.heylth-cloud-browser-host {
  isolation: isolate;
  overflow: hidden !important;
  overscroll-behavior: contain;
}

.heylth-cloud-browser-host:not(.inner-screen):not([data-phone-screen]) {
  position: relative !important;
}

/* Cloud browser replaces the Profile content, not its shared Bar backdrop. */
.heylth-cloud-browser-host > #profileSettingsLive {
  visibility: hidden;
}

.heylth-cloud-browser-page,
.heylth-cloud-browser-page * {
  box-sizing: border-box;
}

.heylth-cloud-browser-page {
  --cb-bg: var(--settings-page-surface);
  --cb-card: #fff;
  --cb-label: #000;
  --cb-secondary: #929297;
  --cb-separator: rgba(60, 60, 67, 0.12);
  --cb-orange: #d85d26;
  --cb-blue: #0a84ff;
  --cb-type-16: var(--settings-row-font-size);
  position: absolute;
  inset: 0;
  z-index: 9999;
  overflow: hidden;
  max-width: 100%;
  max-height: 100%;
  border-radius: inherit;
  contain: layout paint;
  overscroll-behavior: contain;
  color: var(--cb-label);
  font-family: var(--heylth-font-text);
  font-size: var(--settings-row-font-size);
  font-weight: 400;
  letter-spacing: 0em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  pointer-events: auto;
}

/* Keep the shared dimmed Bar/status backdrop visible in both appearances. */
.device.heylth-cloud-browser-host > .heylth-cloud-browser-page {
  background: transparent;
}

.cb-sheet {
  position: absolute;
  inset: var(--settings-nav-top) 0 0;
  overflow: hidden;
  max-width: 100%;
  max-height: 100%;
  border-radius: var(--settings-nav-radius) var(--settings-nav-radius) 0 0;
  background: var(--cb-bg);
  isolation: isolate;
  overscroll-behavior: contain;
}

.cb-view {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  min-width: 0;
  background: var(--cb-bg);
}

.cb-navigation {
  position: absolute;
  inset: 0 0 auto;
  height: var(--settings-nav-height);
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: var(--settings-nav-radius) var(--settings-nav-radius) 0 0;
  background: var(--cb-bg);
  z-index: 4;
}

.cb-navigation-title {
  max-width: 68cqw;
  margin: .5cqw 0 0;
  overflow: hidden;
  color: #050505;
  font-size: var(--settings-nav-title-size);
  line-height: var(--settings-nav-title-line-height);
  font-weight: var(--settings-nav-title-weight);
  letter-spacing: 0em;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cb-back-button {
  display: grid;
  place-items: center;
  -webkit-tap-highlight-color: transparent;
}

.cb-scroll {
  position: absolute;
  top: calc(var(--settings-content-top) - var(--settings-nav-top));
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  max-width: 100%;
  max-height: 100%;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.cb-scroll::-webkit-scrollbar {
  display: none;
}

.cb-content {
  width: 100%;
  max-width: 100%;
  min-height: 100%;
  margin: 0 auto;
  padding: 0 var(--settings-nav-side-inset) 13cqw;
}

.cb-section + .cb-section {
  margin-top: 8.35cqw;
}

.cb-section-title {
  margin: 0 4.35cqw 3.1cqw;
  color: #949498;
  font-size: var(--settings-section-font-size);
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: 0em;
}

.cb-card {
  position: relative;
  overflow: visible;
  border-radius: var(--settings-row-radius);
  background: var(--cb-card);
}

.cb-card.cb-card-clips {
  overflow: hidden;
}

.cb-row,
.cb-action-row {
  position: relative;
  width: 100%;
  min-height: var(--settings-row-height);
  display: flex;
  align-items: center;
  gap: 2.67cqw;
  padding: 0 4.35cqw;
  border: 0;
  color: var(--cb-label);
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.cb-row::after,
.cb-action-row::after,
.cb-added-site::after {
  content: "";
  position: absolute;
  left: 4.35cqw;
  right: 4.35cqw;
  bottom: 0;
  height: .27cqw;
  background: var(--cb-separator);
  transform: scaleY(0.7);
  transform-origin: bottom;
}

.cb-card > :last-child::after,
.cb-row.cb-no-separator::after,
.cb-action-row.cb-no-separator::after {
  display: none;
}

.cb-row:active,
.cb-action-row:active {
  background: rgba(118, 118, 128, 0.08);
}

.cb-row-label,
.cb-action-label,
.cb-site-label {
  min-width: 0;
  color: #050505;
  font-size: var(--settings-row-font-size);
  line-height: var(--settings-row-line-height);
  font-weight: var(--settings-row-font-weight);
  letter-spacing: 0em;
}

.cb-row-label,
.cb-action-label {
  font-size: var(--cb-type-16);
  font-weight: 450;
  letter-spacing: 0em;
}

.cb-row-label {
  margin-right: auto;
}

.cb-row-value,
.cb-site-value {
  min-width: 0;
  overflow: hidden;
  color: #636367;
  font-size: var(--settings-row-font-size);
  line-height: 1.2;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cb-chevron-down,
.cb-chevron-right {
  flex: 0 0 auto;
  width: 2.13cqw;
  height: 2.13cqw;
  border-style: solid;
  border-color: #c1c1c5;
}

.cb-chevron-down {
  margin: -1cqw .8cqw 0 1.6cqw;
  border-width: 0 .45cqw .45cqw 0;
  transform: rotate(45deg);
}

.cb-chevron-right {
  margin-left: 1.07cqw;
  border-width: .45cqw .45cqw 0 0;
  transform: rotate(45deg);
}

.cb-plus {
  position: relative;
  width: 5.87cqw;
  height: 5.87cqw;
  flex: 0 0 5.87cqw;
  margin-right: .53cqw;
}

.cb-plus::before,
.cb-plus::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 0.5333cqw;
  background: #0b0b0c;
  transform: translate(-50%, -50%);
}

.cb-plus::before { width: 5.6cqw; height: .43cqw; }
.cb-plus::after { width: .43cqw; height: 5.6cqw; }

.cb-helper {
  margin: 2.65cqw 4.35cqw 0;
  color: #96969a;
  font-size: var(--settings-helper-font-size);
  line-height: var(--settings-helper-line-height);
  font-weight: var(--settings-helper-font-weight);
  letter-spacing: 0em;
}

.cb-menu {
  position: absolute;
  z-index: 30;
  width: min(103.4667cqw, calc(100cqw - 9.6cqw));
  min-width: 0;
  max-width: calc(100cqw - 9.6cqw);
  padding: 3.7333cqw 0;
  overflow: hidden;
  border: 0.2667cqw solid rgba(255, 255, 255, 0.76);
  border-radius: 6.6667cqw;
  background: rgba(250, 250, 252, 0.86);
  box-shadow: 0 3.7333cqw 10.6667cqw rgba(0, 0, 0, 0.13), inset 0 0 0 0.1333cqw rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: saturate(155%) blur(6.9333cqw);
  backdrop-filter: saturate(155%) blur(6.9333cqw);
  transform-origin: 78% 0;
  animation: cb-menu-in 0.27s cubic-bezier(0.2, 0.85, 0.3, 1) both;
}

.cb-default-menu {
  top: 17.0667cqw;
  right: 4.8cqw;
}

.cb-rule-menu {
  top: calc(100% - 1.0667cqw);
  right: 4.8cqw;
}

.cb-select-wrap > .cb-rule-menu {
  right: -5.8667cqw;
}

.cb-menu-item {
  width: 100%;
  min-height: 16.8cqw;
  display: grid;
  grid-template-columns: 8cqw minmax(0, 1fr) 6.9333cqw;
  align-items: center;
  column-gap: 2.6667cqw;
  padding: 2.1333cqw 4.8cqw;
  border: 0;
  color: #050505;
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.cb-menu-item:active {
  background: rgba(118, 118, 128, 0.1);
}

.cb-menu-item.cb-warning {
  color: var(--cb-orange);
}

.cb-menu-copy {
  min-width: 0;
}

.cb-menu-title {
  display: block;
  color: currentColor;
  font-size: 4.5333cqw;
  line-height: 1.16;
  font-weight: 500;
}

.cb-menu-subtitle {
  display: block;
  margin-top: 0.8cqw;
  color: #8c8c91;
  font-size: 3.7333cqw;
  line-height: 1.25;
  font-weight: 400;
}

.cb-warning .cb-menu-subtitle {
  color: var(--cb-orange);
}

.cb-check {
  width: 4.2667cqw;
  height: 2.4cqw;
  margin: -1.0667cqw 0 0 0.5333cqw;
  border: solid currentColor;
  border-width: 0 0 0.5333cqw 0.5333cqw;
  transform: rotate(-45deg);
}

.cb-warning-icon {
  position: relative;
  width: 5.3333cqw;
  height: 6.1333cqw;
  border: 0.5333cqw solid currentColor;
  border-radius: 2.6667cqw 2.6667cqw 3.2cqw 3.2cqw;
  clip-path: polygon(50% 0, 100% 18%, 90% 78%, 50% 100%, 10% 78%, 0 18%);
}

.cb-warning-icon::after {
  content: "!";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 3.4667cqw;
  line-height: 1;
  font-weight: 700;
}

.cb-menu-divider {
  height: 0.2667cqw;
  margin: 2.1333cqw 4.8cqw;
  background: var(--cb-separator);
}

.cb-trash-icon {
  position: relative;
  width: 4.5333cqw;
  height: 5.3333cqw;
  margin-left: 0.2667cqw;
  border: 0.5333cqw solid currentColor;
  border-radius: 0.8cqw 0.8cqw 1.3333cqw 1.3333cqw;
}

.cb-trash-icon::before {
  content: "";
  position: absolute;
  left: -1.0667cqw;
  right: -1.0667cqw;
  top: -1.3333cqw;
  height: 0.5333cqw;
  border-radius: 0.5333cqw;
  background: currentColor;
}

.cb-trash-icon::after {
  content: "";
  position: absolute;
  left: 1.0667cqw;
  right: 1.0667cqw;
  top: -2.4cqw;
  height: 1.3333cqw;
  border: 0.5333cqw solid currentColor;
  border-bottom: 0;
  border-radius: 0.8cqw 0.8cqw 0 0;
}

.cb-add-form {
  padding: 3.7333cqw 5.8667cqw 4.2667cqw;
  animation: cb-form-in 0.34s cubic-bezier(0.2, 0.82, 0.25, 1) both;
}

.cb-field,
.cb-select-button {
  width: 100%;
  min-height: 14.4cqw;
  border: 0.2667cqw solid rgba(60, 60, 67, 0.23);
  border-radius: 5.8667cqw;
  color: #0a0a0b;
  background: rgba(255, 255, 255, 0.54);
  font: inherit;
  font-size: 4.5333cqw;
  line-height: 1.2;
  font-weight: 500;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.cb-field {
  padding: 0 4.5333cqw;
}

.cb-field::placeholder {
  color: #a5a5aa;
  opacity: 1;
}

.cb-select-button:focus-visible {
  border-color: rgba(10, 132, 255, 0.65);
  box-shadow: 0 0 0 0.8cqw rgba(10, 132, 255, 0.12);
  background: rgba(255, 255, 255, 0.82);
}

.cb-field:focus,
.cb-field:focus-visible {
  border-color: rgba(60, 60, 67, 0.23);
  outline: none;
  box-shadow: none;
  background: rgba(255, 255, 255, 0.82);
}

.cb-select-wrap {
  position: relative;
  margin-top: 2.6667cqw;
}

.cb-select-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4.5333cqw;
  cursor: pointer;
}

.cb-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 2.6667cqw;
  margin-top: 2.9333cqw;
}

.cb-pill-button {
  min-width: 20.2667cqw;
  min-height: 11.2cqw;
  padding: 0 4.8cqw;
  border: 0.2667cqw solid rgba(60, 60, 67, 0.2);
  border-radius: 5.8667cqw;
  color: #08080a;
  background: rgba(255, 255, 255, 0.74);
  font: inherit;
  font-size: 4.2667cqw;
  font-weight: 500;
  cursor: pointer;
  transition: transform 0.14s ease, opacity 0.18s ease, background 0.18s ease;
}

.cb-pill-button.cb-primary {
  min-width: 18.1333cqw;
  border-color: #050505;
  color: #fff;
  background: #050505;
}

.cb-pill-button:active:not(:disabled) {
  transform: scale(0.96);
}

.cb-pill-button:disabled {
  border-color: transparent;
  color: #fff;
  background: #b9b9bd;
  cursor: default;
  opacity: 0.84;
}

.cb-loading-inline {
  display: inline-flex;
  align-items: center;
  gap: 2.1333cqw;
}

.cb-spinner {
  width: 4.2667cqw;
  height: 4.2667cqw;
  display: inline-block;
  border: 0.5333cqw solid rgba(255, 255, 255, 0.48);
  border-top-color: #fff;
  border-radius: 50%;
  animation: cb-spin 0.74s linear infinite;
}

.cb-added-site {
  position: relative;
  min-height: 18.1333cqw;
  display: flex;
  align-items: center;
  gap: 2.6667cqw;
  padding: 0 5.8667cqw;
}

.cb-site-label {
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cb-site-menu-button {
  flex: 0 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 2.1333cqw;
  padding: 3.2cqw 0 3.2cqw 3.2cqw;
  border: 0;
  color: #57575b;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.cb-site-menu-button:active {
  opacity: 0.58;
}

.cb-cookie-empty {
  min-height: 82.6667cqw;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8.5333cqw;
  text-align: center;
}

.cb-cookie-icon {
  position: relative;
  width: 15.4667cqw;
  height: 15.4667cqw;
  margin-bottom: 4.8cqw;
  border: 1.0667cqw solid #8e8e93;
  border-radius: 50%;
}

.cb-cookie-icon::before,
.cb-cookie-icon::after {
  content: "";
  position: absolute;
  width: 1.8667cqw;
  height: 1.8667cqw;
  border-radius: 50%;
  background: #8e8e93;
}

.cb-cookie-icon::before { left: 3.4667cqw; top: 3.7333cqw; box-shadow: 5.3333cqw 3.7333cqw 0 #8e8e93; }
.cb-cookie-icon::after { left: 4.5333cqw; top: 9.3333cqw; }

.cb-empty-title {
  margin: 0;
  font-size: 5.3333cqw;
  line-height: 1.2;
  font-weight: 600;
}

.cb-empty-copy {
  max-width: 96cqw;
  margin: 2.1333cqw 0 0;
  color: #8e8e93;
  font-size: 4cqw;
  line-height: 1.3;
}

.cb-cookie-site {
  min-height: 18.1333cqw;
  display: flex;
  align-items: center;
  gap: 3.2cqw;
  padding: 2.6667cqw 5.8667cqw;
}

.cb-cookie-site-copy {
  flex: 1;
  min-width: 0;
}

.cb-cookie-site-name {
  display: block;
  overflow: hidden;
  font-size: 4.2667cqw;
  font-weight: 450;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cb-cookie-site-meta {
  display: block;
  margin-top: 0.8cqw;
  color: #8e8e93;
  font-size: 3.4667cqw;
}

.cb-clear-button {
  width: 100%;
  min-height: 15.4667cqw;
  margin-top: 6.4cqw;
  border: 0;
  border-radius: 5.8667cqw;
  color: #ff3b30;
  background: rgba(255, 255, 255, 0.96);
  font: inherit;
  font-size: 4.2667cqw;
  font-weight: 500;
  cursor: pointer;
}

.cb-clear-button:active {
  background: rgba(255, 59, 48, 0.08);
}

.cb-toast {
  position: absolute;
  left: 50%;
  bottom: 6.4cqw;
  z-index: 50;
  max-width: calc(100% - 12.8cqw);
  padding: 2.9333cqw 4.5333cqw;
  border-radius: 4.8cqw;
  color: #fff;
  background: rgba(28, 28, 30, 0.88);
  box-shadow: 0 2.6667cqw 7.4667cqw rgba(0, 0, 0, 0.18);
  -webkit-backdrop-filter: blur(4.8cqw);
  backdrop-filter: blur(4.8cqw);
  font-size: 3.7333cqw;
  font-weight: 500;
  white-space: nowrap;
  transform: translateX(-50%);
  animation: cb-toast-in 0.28s cubic-bezier(0.2, 0.85, 0.3, 1) both;
}

@keyframes cb-menu-in {
  from { opacity: 0; transform: scale(0.94) translateY(-1.3333cqw); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes cb-form-in {
  from { opacity: 0; transform: translateY(-2.6667cqw); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cb-toast-in {
  from { opacity: 0; transform: translate(-50%, 2.1333cqw) scale(0.96); }
  to { opacity: 1; transform: translate(-50%, 0) scale(1); }
}

@keyframes cb-spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .heylth-cloud-browser-page,
  .cb-view,
  .cb-content,
  .cb-menu,
  .cb-add-form,
  .cb-toast {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
  .cb-scroll { scroll-behavior: auto; }
}

/* Match Cloud Browser popups to the Memory summary overflow material. */
.cb-menu,
.cb-toast {
  border-color: var(--popup-material-border);
  background: var(--popup-material-surface);
  box-shadow: var(--popup-material-shadow);
  -webkit-backdrop-filter: var(--popup-material-backdrop);
  backdrop-filter: var(--popup-material-backdrop);
}

@media (prefers-reduced-transparency: reduce) {
  .cb-menu,
  .cb-toast {
    background: #f8f8fa !important;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}
