/* Desktop account social surfaces; no effect on game or compact viewports. */
@media (min-width: 1025px) {
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-product-content,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-product-content {
    width: min(100%, 1240px);
    margin-inline: auto;
    padding-inline: 28px;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-page-heading h1,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-page-heading h1 {
    font-size: 34px;
    line-height: 1.15;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-page-heading p,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-page-heading p {
    color: var(--tp-color-text-secondary);
    font-size: 15px;
    line-height: 1.45;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-toolbar {
    gap: 18px;
    padding-block: 4px 13px;
    border-bottom: 1px solid var(--tp-color-border);
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-section-tabs { gap: 6px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-section-tabs button {
    min-height: 42px;
    padding-inline: 15px;
    font-size: 13px;
    transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-search-bar,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-messenger-search {
    border-color: var(--tp-color-border);
    border-radius: 8px;
    background: var(--tp-color-surface);
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-context-status { font-size: 13px; color: var(--tp-color-text-muted); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-layout { grid-template-columns: minmax(0, 1fr) 270px; gap: 28px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-list-section {
    min-height: 0;
    padding: 16px 0;
    border: 0;
    border-radius: 0;
    background: transparent;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-list-section .tp-section-heading h2 { font-size: 21px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-list-section .tp-section-heading p { color: var(--tp-color-text-muted); font-size: 13px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-people-list { min-height: 0; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row {
    min-height: 72px;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    padding: 10px 8px;
    border-color: color-mix(in srgb, var(--tp-color-border) 66%, transparent);
    transition: background-color 160ms ease;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row:hover { background: var(--tp-color-surface); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row__identity > strong { font-size: 15px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row__identity > span,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-presence { font-size: 12px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row__context { color: var(--tp-color-text-secondary); font-size: 12px; line-height: 1.35; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-friends-aside { gap: 0; border-top: 1px solid var(--tp-color-border); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-side-section {
    padding: 16px 0;
    border: 0;
    border-bottom: 1px solid var(--tp-color-border);
    border-radius: 0;
    background: transparent;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-side-section h2 { font-size: 15px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-side-section > header button { color: var(--tp-color-primary); font-size: 12px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-side-empty { font-size: 12px; line-height: 1.4; }

  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-product-content {
    height: calc(100dvh - 66px);
    min-height: 550px;
    gap: 14px;
    padding-top: 27px;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-page-heading { margin-bottom: 0; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-messenger {
    grid-template-columns: 350px minmax(0, 1fr);
    border-color: var(--tp-color-border);
    border-radius: 9px;
    background: var(--tp-color-surface);
    box-shadow: 0 14px 32px rgba(0,0,0,.17);
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-messenger__sidebar {
    padding: 16px 13px;
    border-color: var(--tp-color-border);
    background: var(--tp-color-bg-secondary, var(--tp-color-page));
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-messenger-list-header strong { font-size: 17px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages #messages-unread-summary { font-size: 12px; color: var(--tp-color-text-muted); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row {
    min-height: 72px;
    padding: 10px 8px;
    border-color: color-mix(in srgb, var(--tp-color-border) 65%, transparent);
    transition: background-color 160ms ease;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row:hover,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row.is-active { background: var(--tp-color-surface-raised); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row__top strong { font-size: 14px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row__avatar {
    display: grid;
    place-items: center;
    border: 1px solid var(--tp-color-border);
    border-radius: 50%;
    background: var(--tp-color-surface-raised);
    color: var(--tp-color-primary);
    font-size: 13px;
    font-weight: 700;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row__preview,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row__top time { font-size: 12px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-placeholder { gap: 10px; font-size: 14px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-placeholder strong { font-size: 19px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-placeholder i { font-size: 25px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-header,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-composer { border-color: var(--tp-color-border); }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-header__identity h2 { font-size: 16px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-chat-header__identity p { font-size: 12px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-message {
    max-width: min(70%, 620px);
    padding: 10px 12px 8px;
    border-color: color-mix(in srgb, var(--tp-color-border) 75%, transparent);
    border-radius: 9px 9px 9px 3px;
    background: var(--tp-color-surface-raised);
    color: var(--tp-color-text);
    font-size: 14px;
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-message.is-mine {
    border-color: color-mix(in srgb, var(--tp-color-primary) 27%, var(--tp-color-border));
    border-radius: 9px 9px 3px 9px;
    background: color-mix(in srgb, var(--tp-color-primary) 8%, var(--tp-color-surface));
  }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-message p { line-height: 1.48; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-message__meta { margin-top: 5px; color: var(--tp-color-text-muted); font-size: 11px; }
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages :is(button, input, textarea):focus-visible,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends :is(button, input, summary):focus-visible {
    outline: 2px solid var(--tp-color-primary);
    outline-offset: 2px;
  }
  /* Steppe Light: softer elevation on light surfaces. */
  html[data-theme="steppe-light"] #screen-messages .tp-messenger { box-shadow: var(--tp-shadow-md); }
}
@media (min-width: 1025px) and (prefers-reduced-motion: reduce) {
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-person-row,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-friends .tp-section-tabs button,
  html:is([data-theme="obsidian-sand"], [data-theme="steppe-light"]) #screen-messages .tp-conversation-row { transition: none; }
}
