/* Desktop presentation only. Touch-first phones/tablets retain the dark studio,
   including landscape. Do not infer device type from viewport width alone. */
@media (hover: hover) and (pointer: fine) {
  body.social-ghost {
    --ink: #252138;
    --muted: #625b73;
    --line: #d8d2e4;
    --purple: #6941c6;
    --deep: #5731ae;
    --pale: #f0eafa;
    --bg: #f4f3f8;
    color-scheme: light;
    background: var(--bg) !important;
    color: var(--ink) !important;
  }
  .social-ghost .workspace {
    background: radial-gradient(ellipse at 50% 0, #eee7fb 0, transparent 55%), var(--bg) !important;
  }
  .social-ghost #sgHeader {
    background: #fff;
    border-color: var(--line);
    box-shadow: 0 3px 18px #34204c08;
  }
  .social-ghost #sgHeader a.wv-editor-exit,
  .social-ghost #sgHeader #undo,
  .social-ghost #sgHeader #redo {
    background: #fff !important;
    border-color: #cfc4df !important;
    color: #493269 !important;
  }
  .social-ghost #sgHeader a.wv-editor-exit:hover,
  .social-ghost #sgHeader #undo:not(:disabled):hover,
  .social-ghost #sgHeader #redo:not(:disabled):hover {
    background: #f0eafa !important;
  }
  .social-ghost #sgHeader #next,
  .social-ghost .primary,
  .social-ghost #mobilePreview {
    color: #fff !important;
    background: #6941c6 !important;
    border-color: #6941c6 !important;
  }
  .social-ghost .step-link { color: #625b73; }
  .social-ghost .step-link.active { color: #5731ae; }
  .social-ghost .step-num { color: #493269; }
  .social-ghost .step-link.active .step-num { color: #fff; }
  .social-ghost .work-grid { max-width: none; width: 100%; min-width: 0; }
  /* Fill the space between the tool rails; reserve their actual hit areas. */
  .social-ghost #page0 { padding-inline: 88px 80px !important; }
  .social-ghost.sg-clean #page0,
  .social-ghost.sg-keyboard #page0 { padding-inline: 18px !important; }
  .social-ghost .editor-shell {
    padding: clamp(16px, 2.2vw, 30px) !important;
    background: #fff !important;
    border: 1px solid #d8d2e4 !important;
    border-radius: 20px;
    box-shadow: 0 10px 36px #34204c0a !important;
  }
  .social-ghost .editor-top { border-bottom: 1px solid #eee9f4; }
  .social-ghost .author b,
  .social-ghost .title-input,
  .social-ghost .editor-body { color: #252138 !important; }
  .social-ghost .editor-body { min-height: 220px; caret-color: #6941c6; }
  .social-ghost #formatToggle { color: #5731ae; }
  .social-ghost input::placeholder,
  .social-ghost textarea::placeholder,
  .social-ghost [contenteditable]:empty:before { color: #72677f !important; opacity: 1; }
  .social-ghost #sgTools,
  .social-ghost #sgStyle {
    background: #fffffff2;
    border-color: #cfc4df;
    box-shadow: 0 8px 28px #34204c0e;
  }
  .social-ghost #sgTools button,
  .social-ghost #sgStyle button { color: #493269; }
  .social-ghost #sgTools button:hover,
  .social-ghost #sgStyle button:hover { background: #eee6fb; }
  .social-ghost .format-tools {
    background: #f7f4fc !important;
    border-color: #cfc4df;
  }
  .social-ghost .format-tools button { color: #493269; background: #fff; }
  .social-ghost .footer {
    background: #fff !important;
    border-color: #d8d2e4 !important;
  }
  .social-ghost .footer button { color: #493269; }
  .social-ghost .footer-left > button:not(.primary) {
    background: #f6f2fc;
    border: 1px solid #d8d2e4;
    border-radius: 10px;
    padding: 8px 12px;
  }
  .social-ghost .poll-box,
  .social-ghost .audio-panel,
  .social-ghost .target,
  .social-ghost .preview-card,
  .social-ghost .visibility-card,
  .social-ghost .field input,
  .social-ghost .field select,
  .social-ghost .field textarea {
    background: #fff !important;
    color: #252138 !important;
    border-color: #cfc4df !important;
  }
  .social-ghost .target:has(input:checked),
  .social-ghost .privacy:has(input:checked) {
    background: #f1ebfc !important;
    border-color: #8058c4 !important;
  }
  .social-ghost .poll-options input {
    background: #faf8fd;
    border-color: #bfb0d3;
    color: #252138;
  }
  .social-ghost .target-copy,
  .social-ghost label,
  .social-ghost h2 { color: #252138; }
  .social-ghost .sub { color: #625b73; }
  .social-ghost #socialSession:not(:empty) {
    background: #fff;
    color: #493269;
    border: 1px solid #cfc4df;
    border-radius: 12px;
    box-shadow: 0 4px 16px #34204c12;
  }
  .social-ghost dialog {
    background: #fff;
    color: #252138;
    border-color: #cfc4df;
    color-scheme: light;
  }
  .social-ghost button:focus-visible,
  .social-ghost a:focus-visible,
  .social-ghost #mobilePreview:focus-visible {
    outline: 3px solid #6941c6;
    outline-offset: 3px;
  }
  .social-ghost .editor-body:focus-visible { outline: 2px solid #b7a0de; outline-offset: 4px; }
  .social-ghost .secondary { color: #493269; background: #fff; border-color: #cfc4df; }
  .social-ghost .primary:hover,
  .social-ghost #sgHeader #next:hover,
  .social-ghost #mobilePreview:hover { background: #5731ae !important; }
}
@media (min-width: 900px) and (hover: hover) and (pointer: fine) {
  .social-ghost #page0 { padding-inline: 120px 110px !important; }
  .social-ghost.sg-clean #page0,
  .social-ghost.sg-keyboard #page0 { padding-inline: 18px !important; }
}
