/* ═══════════════════════════════════════════════════════════════════════════
   PROFILE CONCEPT  (profile-concept.css)
   Implements concepts/New Profile Design.svg. Loads LAST on profile.html.

   Every selector is prefixed with `html :is(body, body.profile-theme-active)
   .profile-page`: :is() takes the specificity of its most specific argument,
   so each rule ties the legacy "body.profile-theme-active" rules in
   styles.css / profile-theme-override.css and wins by source order.
   Colours still read the --pt-* variables so the settings modal keeps working.
═══════════════════════════════════════════════════════════════════════════ */

/* ── Card ───────────────────────────────────────────────────────────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-profile-card {
  border-radius: var(--pt-card-radius, 5px) var(--pt-card-radius, 5px) 0 0 !important;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35) !important;
}

/* ── Header: 105px band, 89px square avatar, buttons bottom-right ───────── */
html :is(body, body.profile-theme-active) .profile-page .w2-avatar-wrap {
  position: relative;
  width: var(--pt-avatar-size, 89px);
  height: var(--pt-avatar-size, 89px);
  align-self: start;
}
/* With a decoration the avatar needs breathing room so the overlay isn't cut off by the card edge */
html :is(body, body.profile-theme-active) .profile-page .w2-channel-header.has-avatar-deco {
  padding: 17px 6px 17px 17px !important;
}
/* "Decoration" shortcut chip on your own avatar */
html :is(body, body.profile-theme-active) .profile-page .w2-avatar-deco-btn {
  position: absolute;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  z-index: 4;
  visibility: hidden;
  height: 22px;
  padding: 0 12px 0 10px;
  border: 1px solid #414141;
  border-radius: 0;
  font: inherit;
  font-size: 11px;
  font-weight: 600;
  line-height: 20px;
  color: #fff;
  white-space: nowrap;
  cursor: pointer;
  background: linear-gradient(to bottom, #323232, #1d1d1d);
  clip-path: polygon(0 0, calc(100% - 6px) 0, 100% 6px, 100% 100%, 0 100%);
}
html :is(body, body.profile-theme-active) .profile-page .w2-avatar-wrap.is-owner:hover .w2-avatar-deco-btn,
body.pe-editing .profile-page .w2-avatar-wrap.is-owner .w2-avatar-deco-btn {
  visibility: visible;
}
html :is(body, body.profile-theme-active) .profile-page .w2-channel-header {
  grid-template-columns: var(--pt-avatar-size, 89px) minmax(0, 1fr) auto !important;
  gap: 6px 13px !important;
  align-items: center !important;
  box-sizing: border-box !important;
  min-height: 105px !important;
  padding: 7px 6px 6px 7px !important;
  background: linear-gradient(to bottom,
    var(--pt-header-top, #0184f0) 0%,
    var(--pt-header-bottom, #004a87) 100%) !important;
  border: 0 !important;
  box-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-avatar {
  box-shadow: none !important;
  align-self: start !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy {
  min-width: 0 !important;
  /* Same height as the avatar, text sitting on its bottom edge */
  align-self: start !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-end !important;
  min-height: var(--pt-avatar-size, 89px) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy h2 {
  margin: 0 0 6px !important;
  font-size: var(--pt-username-size, 24px) !important;
  font-weight: 700 !important;
  line-height: 1.15 !important;
  letter-spacing: 0 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy .channel-meta {
  margin: 0 !important;
  font-size: 13px !important;
  line-height: 1.4 !important;
  color: rgba(255, 255, 255, 0.85) !important;
  text-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-profile-actions {
  align-self: end !important;
  gap: 5px !important;
}

/* Online / Offline line (concept: green "Online - in the hangout center") */
html :is(body, body.profile-theme-active) .profile-page .w2-presence {
  margin: 3px 0 0 !important;
  font-size: 12px !important;
  line-height: 1.4 !important;
  color: rgba(255, 255, 255, 0.85) !important;
  text-shadow: none !important;
  text-transform: lowercase;
}
/* Montserrat profiles get the light cut, like the rest of the stats line in the concept */
html :is(body, body.profile-theme-active) .profile-page .w2-presence.is-montserrat,
html :is(body, body.profile-theme-active) .profile-page .w2-presence.is-montserrat .w2-presence-state {
  font-weight: 300 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-state {
  font-weight: 600;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence[data-state="online"] .w2-presence-state {
  color: #00ff2f !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence[data-state="offline"] .w2-presence-state {
  color: #b8c4d0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence[data-state="dnd"] .w2-presence-state {
  color: #ff4d4d !important;
}

/* Own profile: the line opens a small Online / Do Not Disturb picker */
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy {
  position: relative;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-own {
  cursor: pointer;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-own .w2-presence-state::after {
  content: '';
  display: inline-block;
  margin-left: 5px;
  border: 3px solid transparent;
  border-top: 4px solid currentColor;
  border-bottom: 0;
  vertical-align: middle;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-menu {
  position: absolute;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 170px;
  padding: 4px;
  background: linear-gradient(to bottom, #323232, #1d1d1d);
  border-radius: 3px 0 0 0;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 0 100%);
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-menu[hidden] {
  display: none;
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-menu button {
  height: 32px;
  padding: 0 12px;
  border: 1px solid #414141;
  border-radius: 0;
  font: inherit;
  font-size: 13px;
  text-align: left;
  color: #ddd;
  cursor: pointer;
  background: linear-gradient(to top, #1b1b1b, #2d2d2d);
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-menu button:hover {
  filter: brightness(1.25);
}
html :is(body, body.profile-theme-active) .profile-page .w2-presence-menu button[aria-checked="true"] {
  border-color: #00ff62;
  color: #fff;
}

/* ── Header buttons: 40px tall, bottom-right corner cut 8px ─────────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-action-btn {
  min-height: 40px !important;
  box-sizing: border-box !important;
  padding: 0 20px !important;
  border: 0 !important;
  border-radius: 0 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  color: #fff !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35) !important;
  background: linear-gradient(to bottom,
    var(--pt-btn-bg-top, #00ff4c) 0%,
    var(--pt-btn-bg-bottom, #00992e) 100%) !important;
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.5), inset 0 0 0 1px rgba(0, 0, 0, 0.35) !important;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%);
}
html :is(body, body.profile-theme-active) .profile-page .w2-action-btn:hover {
  filter: brightness(1.1) !important;
}
html :is(body, body.profile-theme-active) .profile-page #friend-profile-btn.w2-action-btn,
html :is(body, body.profile-theme-active) .profile-page .w2-action-btn.w2-msg-btn {
  background: linear-gradient(to bottom,
    var(--pt-msg-btn-top, #00d0ff) 0%,
    var(--pt-msg-btn-bottom, #007d99) 100%) !important;
  color: #fff !important;
}
html :is(body, body.profile-theme-active) .profile-page #block-profile-btn.w2-action-btn {
  background: linear-gradient(to bottom,
    var(--pt-block-btn-top, #ff0000) 0%,
    var(--pt-block-btn-bottom, #990000) 100%) !important;
  color: #fff !important;
}

/* Message + Block are icon-only buttons drawn by buttons/Message.svg and buttons/Block.svg
   (the text stays in the DOM for screen readers; the title attribute is the tooltip). */
html :is(body, body.profile-theme-active) .profile-page #message-profile-btn.w2-action-btn,
html :is(body, body.profile-theme-active) .profile-page #block-profile-btn.w2-action-btn {
  width: 40px;
  padding: 0 !important;
  overflow: hidden;
  font-size: 0 !important;
  color: transparent !important;
  background-color: transparent !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  background-size: 100% 100% !important;
  box-shadow: none !important;
  clip-path: none !important;
}
html :is(body, body.profile-theme-active) .profile-page #message-profile-btn.w2-action-btn {
  background-image: url('../buttons/Message.svg') !important;
}
html :is(body, body.profile-theme-active) .profile-page #block-profile-btn.w2-action-btn {
  background-image: url('../buttons/Block.svg') !important;
}

/* Follow: 112px green button. Following shows a check (buttons/Following or Follow.svg);
   hovering it turns it into a red Unfollow button. */
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn {
  position: relative;
  width: 112px;
}
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn[data-following="true"] {
  padding: 0 0 0 9px !important;
  text-align: left;
}
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn[data-following="true"]::after {
  content: '';
  position: absolute;
  top: 13px;
  right: 8px;
  width: 17px;
  height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='87 13 17 14'%3E%3Cpath d='M89 19L87 21L93 27L104 15L102 13L93 23L89 19Z' fill='white'/%3E%3C/svg%3E") center / contain no-repeat;
}
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn[data-following="true"]:hover {
  font-size: 0 !important;
  background: linear-gradient(to bottom,
    var(--pt-block-btn-top, #ff0000) 0%,
    var(--pt-block-btn-bottom, #990000) 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn[data-following="true"]:hover::before {
  content: 'Unfollow';
  position: absolute;
  top: 0;
  left: 9px;
  font-size: 14px;
  line-height: 40px;
  color: #fff;
}
html :is(body, body.profile-theme-active) .profile-page #follow-profile-btn.w2-action-btn[data-following="true"]:hover::after {
  display: none;
}

/* ── Tab bar: 40px, flat active tab, highlight/shade hairlines ──────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-channel-tabs {
  gap: 8px !important;
  min-height: 40px !important;
  box-sizing: border-box !important;
  background: linear-gradient(to bottom,
    var(--pt-tabs-top, #00aaff) 0%,
    var(--pt-tabs-bottom, #0088cd) 100%) !important;
  border: 0 !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.29), inset 0 -1px 0 rgba(0, 0, 0, 0.19) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-channel-tabs a {
  min-height: 40px !important;
  box-sizing: border-box !important;
  padding: 0 14px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  color: var(--pt-tab-color, #fff) !important;
  border: 0 !important;
  text-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-channel-tabs a:hover {
  background: var(--pt-tab-hover-bg, rgba(255, 255, 255, 0.14)) !important;
  color: var(--pt-tab-active-color, #fff) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-channel-tabs a.active {
  /* Pressed-in look (same recipe as the pill nav): the bar's own colour, darker, with an inset shadow */
  background: linear-gradient(to bottom,
    color-mix(in srgb, var(--pt-tabs-bottom, #0088cd) 58%, #000) 0%,
    color-mix(in srgb, var(--pt-tabs-top, #00aaff) 70%, #000) 100%) !important;
  color: var(--pt-tab-active-color, #fff) !important;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.7), inset -2px 0 3px rgba(0, 0, 0, 0.4) !important;
  border: 0 !important;
}

/* ── Name row: username (or admin-granted name graphic) + verification mark ─ */
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy .w2-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: var(--pt-username-size, 24px);
}
html :is(body, body.profile-theme-active) .profile-page .w2-head-copy .w2-name-row h2 {
  margin: 0 !important;
  min-width: 0;
}
html :is(body, body.profile-theme-active) .profile-page .w2-name-row.has-name-art h2 {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.profile-page .profile-name-art {
  display: block;
  height: calc(1em * 1.6667);
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: left center;
}
.profile-page .profile-verified-mark {
  display: block;
  flex: 0 0 auto;
  height: 1em;
  width: auto;
  max-width: 2em;
  object-fit: contain;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.4));
}
.profile-page .w2-name-row.has-name-art .profile-verified-mark { height: 1.25em; max-width: 2.5em; }
.profile-page .profile-name-art[hidden],
.profile-page .profile-verified-mark[hidden] { display: none; }

/* ── Layout: 322px column + fluid column, 6px outer margin and gutter ───── */
html :is(body, body.profile-theme-active) .profile-page .channel-layout,
html :is(body, body.profile-theme-active) .profile-page .channel-layout.w2-home-grid {
  margin-top: 0 !important;
  padding: 6px 6px 0 !important;
  gap: 6px !important;
  grid-template-columns: minmax(180px, 322px) minmax(0, 1fr) !important;
}
html :is(body, body.profile-theme-active) .profile-page .channel-col {
  gap: 7px !important;
}
/* The legacy `display: grid !important` on the home grid defeated [hidden],
   so other tabs rendered underneath the Home panel. */
html :is(body, body.profile-theme-active) .profile-page .channel-panel[hidden],
html :is(body, body.profile-theme-active) .profile-page .channel-layout.w2-home-grid[hidden] {
  display: none !important;
}

/* ── Widgets: chamfered title bar sitting flush on its body panel ───────── */
html :is(body, body.profile-theme-active) .profile-page .yt-box.w2-widget {
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  clip-path: none !important;
  overflow: visible !important;
  margin: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .yt-box.w2-widget > h3.w2-widget-header {
  display: flex !important;
  align-items: center !important;
  box-sizing: border-box !important;
  min-height: 34px !important;
  margin: 0 !important;
  padding: 0 7px !important;
  font-size: var(--pt-widget-hdr-size, 16px) !important;
  font-weight: 700 !important;
  letter-spacing: 0 !important;
  color: var(--pt-widget-hdr-color, #fff) !important;
  text-shadow: none !important;
  background: linear-gradient(to bottom,
    var(--pt-widget-hdr-top, #00aaff) 0%,
    var(--pt-widget-hdr-bottom, #0088cd) 100%) !important;
  border: 0 !important;
  border-radius: 3px 0 0 0 !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3) !important;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 0 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page .yt-box.w2-widget > h3.w2-widget-header + * {
  box-sizing: border-box !important;
  background: var(--pt-widget-body-bg, linear-gradient(to bottom, #e5e5e5 0%, #fefefe 31.7%)) !important;
  border: 1px solid #adadad !important;
  border-radius: 0 !important;
  box-shadow: inset 0 2px 0 #fff, inset 0 3px 2px rgba(0, 0, 0, 0.1) !important;
  color: var(--pt-widget-text, #1a1a1a) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-widget-body p {
  font-size: 14px !important;
}

/* ── More info rows + badges ────────────────────────────────────────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-more-info-body {
  padding: 4px 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-info-row {
  gap: 10px !important;
  padding: 9px 12px !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-info-label,
html :is(body, body.profile-theme-active) .profile-page .w2-info-value {
  font-size: 14px !important;
}

/* White triangle with a black outline (outer clip = outline, ::before = fill) */
html :is(body, body.profile-theme-active) .profile-page .w2-badge-triangle {
  position: relative;
  align-items: flex-end !important;
  box-sizing: border-box;
  min-width: 38px !important;
  height: 33px !important;
  padding-bottom: 3px;
  font-size: 12px !important;
  color: #000 !important;
  text-shadow: none !important;
  background: #000 !important;
  clip-path: polygon(50% 0, 0 100%, 100% 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-badge-triangle::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: #fff;
  clip-path: polygon(50% 3px, 3px calc(100% - 1.5px), calc(100% - 3px) calc(100% - 1.5px));
}

/* Yellow star with an amber outline */
html :is(body, body.profile-theme-active) .profile-page .w2-badge-star {
  position: relative;
  min-width: 42px !important;
  height: 40px !important;
  font-size: 12px !important;
  color: #000 !important;
  text-shadow: none !important;
  background: #c5a800 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-badge-star::before {
  content: '';
  position: absolute;
  inset: 1.5px;
  z-index: -1;
  background: #ffe100;
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

/* ── Favorite consoles: image + name rows with a fading divider ─────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-console-list {
  min-height: 34px;
}
html :is(body, body.profile-theme-active) .profile-page .w2-console-item {
  position: relative;
  gap: 12px !important;
  min-height: 52px;
  padding: 8px 12px 8px 10px !important;
  border-top: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-console-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 10px;
  right: 7px;
  bottom: 0;
  height: 1px;
  background: linear-gradient(to right, #adadad, rgba(173, 173, 173, 0));
}
html :is(body, body.profile-theme-active) .profile-page .w2-console-img {
  width: 68px !important;
  height: 48px !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-console-name {
  font-size: 15px !important;
  font-weight: 500 !important;
}

/* ── New post box ───────────────────────────────────────────────────────── */
html :is(body, body.profile-theme-active) .profile-page #profile-post-input {
  border-radius: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn {
  min-height: 34px;
  padding: 0 20px !important;
  border: 0 !important;
  border-radius: 0 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.3) !important;
  background: linear-gradient(to bottom,
    var(--pt-post-btn-top, #00aaff) 0%,
    var(--pt-post-btn-bottom, #0088cd) 100%) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35) !important;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%);
}

/* ── Profile posts feed (uses the same chamfered buttons as the New Post box) ── */
html :is(body, body.profile-theme-active) .profile-page .pp-card {
  display: flex;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}
html :is(body, body.profile-theme-active) .profile-page .pp-card:first-child { padding-top: 2px; }
html :is(body, body.profile-theme-active) .profile-page .pp-card:last-child { border-bottom: 0; }
html :is(body, body.profile-theme-active) .profile-page .pp-card.pp-pinned {
  background: rgba(0, 136, 205, 0.08);
  margin: 0 -10px;
  padding-left: 10px;
  padding-right: 10px;
}
html :is(body, body.profile-theme-active) .profile-page .pp-avatar {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  object-fit: cover;
  border: 1px solid #000;
  border-radius: 0;
  background: #0088cd;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}
html :is(body, body.profile-theme-active) .profile-page .pp-avatar.pp-avatar-sm {
  width: 30px;
  height: 30px;
  font-size: 11px;
}
html :is(body, body.profile-theme-active) .profile-page .pp-main { flex: 1; min-width: 0; }
html :is(body, body.profile-theme-active) .profile-page .pp-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 3px;
}
html :is(body, body.profile-theme-active) .profile-page .pp-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--pt-widget-text, #1a1a1a);
}
html :is(body, body.profile-theme-active) .profile-page .pp-meta {
  font-size: 12px;
  color: #6b7785;
}
html :is(body, body.profile-theme-active) .profile-page .pp-text {
  font-size: 14px;
  line-height: 1.45;
  color: var(--pt-widget-text, #1a1a1a);
  word-break: break-word;
  white-space: pre-wrap;
}
html :is(body, body.profile-theme-active) .profile-page .pp-empty {
  margin: 0;
  padding: 14px 0;
  font-size: 14px;
  color: #6b7785;
}
html :is(body, body.profile-theme-active) .profile-page .pp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn {
  min-height: 26px;
  padding: 0 12px !important;
  font-size: 12px !important;
  cursor: pointer;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 5px), calc(100% - 5px) 100%, 0 100%);
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn-on {
  background: linear-gradient(to bottom, #2fbf5a 0%, #1d8f3f 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn-muted {
  background: linear-gradient(to bottom, #8f98a3 0%, #646d78 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn-danger {
  background: linear-gradient(to bottom, #e0443f 0%, #b02420 100%) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn:hover { filter: brightness(1.1); }
html :is(body, body.profile-theme-active) .profile-page .w2-post-btn.pp-btn:disabled { opacity: 0.6; cursor: default; }
html :is(body, body.profile-theme-active) .profile-page .pp-comments { margin-top: 10px; }
html :is(body, body.profile-theme-active) .profile-page .pp-comments .comments-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
html :is(body, body.profile-theme-active) .profile-page .pp-comment {
  display: flex;
  gap: 8px;
  padding: 6px 8px;
  background: rgba(0, 0, 0, 0.04);
  border-left: 2px solid #0088cd;
}
html :is(body, body.profile-theme-active) .profile-page .pp-comment .pp-text { font-size: 13px; }
html :is(body, body.profile-theme-active) .profile-page .pp-comment .pp-name { font-size: 13px; }
html :is(body, body.profile-theme-active) .profile-page .pp-reply {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}
html :is(body, body.profile-theme-active) .profile-page .pp-reply .comment-input {
  flex: 1;
  min-width: 0;
  box-sizing: border-box;
  height: 30px;
  padding: 0 8px;
  border: 1px solid #adadad;
  border-radius: 0;
  background: rgba(0, 0, 0, 0.03);
  color: var(--pt-widget-text, #1a1a1a);
  font-size: 13px;
  outline: none;
}
html :is(body, body.profile-theme-active) .profile-page .pp-reply .comment-input:focus { border-color: #0088cd; }

/* ── Pinned video player ────────────────────────────────────────────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-player-body {
  padding: 6px 5px 6px 6px !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-video-player {
  background: transparent !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-flash-controls {
  background: linear-gradient(to bottom, #222 0%, var(--pt-player-ctrl-bg, #101010) 100%) !important;
  border-top: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-progress-track {
  height: 6px !important;
  background: linear-gradient(to bottom, #a1a1a1 0%, #4b4b4b 100%) !important;
  border: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-progress-fill {
  background: linear-gradient(to bottom,
    color-mix(in srgb, var(--pt-player-progress, #05a141) 85%, #fff) 0%,
    color-mix(in srgb, var(--pt-player-progress, #05a141) 60%, #000) 100%) !important;
  box-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-progress-thumb {
  width: 15px !important;
  height: 15px !important;
  background: #d9d9d9 !important;
  border: 0 !important;
  box-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-progress-thumb::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--pt-player-progress, #05a141);
}
html :is(body, body.profile-theme-active) .profile-page .w2-ctrl-row {
  height: 35px !important;
  padding: 0 6px !important;
  gap: 4px !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-ctrl-btn {
  width: 28px !important;
  height: 28px !important;
  border-radius: 0 !important;
  color: #fff !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-ctrl-btn svg {
  width: 16px !important;
  height: 16px !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-ctrl-btn:hover {
  background: rgba(255, 255, 255, 0.14) !important;
  box-shadow: none !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-vol-slider {
  height: 6px !important;
  border-radius: 0 !important;
  background: linear-gradient(to right,
    var(--pt-player-progress, #05a141) var(--range-progress, 100%),
    #d9d9d9 var(--range-progress, 100%)) !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-vol-slider::-webkit-slider-thumb {
  width: 3px;
  height: 14px;
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}
html :is(body, body.profile-theme-active) .profile-page .w2-vol-slider::-moz-range-thumb {
  width: 3px;
  height: 14px;
  border: 0;
  border-radius: 0;
  background: #fff;
}
html :is(body, body.profile-theme-active) .profile-page .w2-time-display {
  font-family: inherit !important;
  font-size: 13px !important;
  color: #fff !important;
}

/* ── Video meta + "Play in watch view" split button ─────────────────────── */
html :is(body, body.profile-theme-active) .profile-page .w2-video-meta {
  padding: 8px 4px 2px !important;
  background: transparent !important;
  border-top: 0 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-video-title {
  font-size: 16px !important;
  font-weight: 600 !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-video-reactions {
  gap: 14px !important;
}
html :is(body, body.profile-theme-active) .profile-page .w2-watch-btn {
  position: relative;
  min-height: 40px;
  box-sizing: border-box;
  padding: 0 54px 0 16px !important;
  border: 0 !important;
  border-radius: 0 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  color: #fff !important;
  text-shadow: none !important;
  background: linear-gradient(to bottom,
    var(--pt-watch-btn-top, #00b300) 0%,
    var(--pt-watch-btn-bottom, #006c00) 100%) !important;
  box-shadow: none !important;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%);
}
html :is(body, body.profile-theme-active) .profile-page .w2-watch-ico {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 40px;
  background: rgba(0, 63, 41, 0.54);
}
html :is(body, body.profile-theme-active) .profile-page .w2-watch-ico::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 14px;
  transform: translate(-50%, -50%);
  background: #fff;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

/* ── Narrow screens ─────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  html :is(body, body.profile-theme-active) .profile-page .channel-layout,
  html :is(body, body.profile-theme-active) .profile-page .channel-layout.w2-home-grid {
    grid-template-columns: 1fr !important;
  }
  html :is(body, body.profile-theme-active) .profile-page .w2-channel-header {
    grid-template-columns: 60px minmax(0, 1fr) !important;
  }
}
