/* Loaded after the legacy styles so settings and workspace controls agree. */
#workspace-view-plans,
.manual-media-load {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--border, #746b87);
  border-radius: 12px;
  color: inherit;
  background: var(--chat-bar, #eeeaf5);
  font: inherit;
  cursor: pointer;
}
#workspace-view-plans {
  width: 100%;
  margin-top: 12px;
  color: white;
  background: rgb(255 255 255 / 12%);
  border-color: rgb(255 255 255 / 35%);
}
.manual-media-load { max-width: 100%; overflow-wrap: anywhere; }
#messages .message .media-preview {
  position: relative;
  display: block;
  width: min(60vw, 520px) !important;
  max-width: 100%;
  aspect-ratio: 4 / 3 !important;
  overflow: hidden;
}
html.native-mobile #messages .message .media-preview { width: min(70vw, 320px) !important; }
html body #messages .message .media-preview img {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  max-height: none;
  object-fit: contain;
}
.settings-info-card span { display: block; }
.settings-clone-page > p { line-height: 1.5; overflow-wrap: anywhere; }
body #overlay[data-panel="settings"] :is(#open-chat-history, #open-chat-backup) {
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  min-height: 48px;
  overflow-wrap: normal;
}

/* Privacy controls share the settings row layout at phone widths. */
#privacy-controls .settings-clone-page, #proxy-controls, #conversation-timer-controls .settings-clone-page {padding:16px; margin:12px 0; border-radius:16px; border:1px solid var(--border,#394650);}
#privacy-controls form, #proxy-controls form {display:flex;flex-direction:column;gap:12px;}
#privacy-controls .settings-clone-choice, #proxy-controls .settings-clone-choice {min-width:0;display:flex;gap:12px;align-items:center;justify-content:space-between;}
#privacy-controls .settings-clone-choice b, #proxy-controls .settings-clone-choice b {min-width:0;flex:1;}
#privacy-controls small {display:block;font-weight:400;line-height:1.4;}
#privacy-controls input:not([type=checkbox]), #privacy-controls select, #proxy-controls input:not([type=checkbox]), #proxy-controls select {min-width:0;max-width:50%;}
#privacy-controls input[type=checkbox], #proxy-controls input[type=checkbox] {width:24px;height:24px;flex:none;}
#privacy-controls p, #proxy-controls p, #conversation-timer-controls p {overflow-wrap:anywhere;line-height:1.5;}
#privacy-controls button, #proxy-controls button, #conversation-timer-controls button {min-height:44px;}
body #overlay[data-panel="settings"] #open-blocked-contacts.settings-clone-row {display:block;grid-template-columns:none;width:100%;text-align:left;white-space:normal;padding:14px 16px;font-size:16px;}
#privacy-controls, #proxy-controls {padding-bottom:calc(110px + env(safe-area-inset-bottom));font-size:15px;}
#privacy-controls .settings-clone-choice, #proxy-controls .settings-clone-choice {font-size:15px;line-height:1.4;}
#privacy-controls select, #privacy-controls input, #proxy-controls input {font-size:15px;}
body #overlay[data-panel="settings"] #privacy-controls .settings-clone-choice b,
body #overlay[data-panel="settings"] #proxy-controls .settings-clone-choice b {font-size:15px;}

/* Remove double-tap click delay without disabling page scrolling or pinch zoom. */
html.native-mobile button, html.native-mobile a { touch-action: manipulation; }
html.native-mobile #native-mobile-nav, html.native-mobile #app-rail { touch-action: pan-y pinch-zoom; }

