/* TINTE.LV V2.8.48.2.1 — article-end dark mode polish
   Scope: Preferred Sources, reactions, tags and sources only.
   No Google widget internals are overridden; Google branding remains native. */

/* Fix the root bug: --card is not a Tinte theme token, so the old fallback was white. */
.preferred-source-v2846{
  background:var(--paper,#fff);
  color:var(--ink,#11120f);
  border-color:var(--line,#dedfd8);
  box-shadow:0 10px 28px rgba(0,0,0,.045);
  transition:background-color .16s ease,border-color .16s ease,box-shadow .16s ease;
}
.preferred-source-v2846 strong{color:var(--ink,#11120f)}
.preferred-source-v2846 span{color:var(--muted,#686b63)}
.preferred-source-v2846>div[google-add-preferred-source-btn]{
  flex:0 0 auto;
  min-width:240px;
}

/* Keep the end-of-article surfaces visually consistent in both themes. */
.story-engagement-v2830,
.tags.story-tags span,
.story-sources{
  transition:background-color .16s ease,border-color .16s ease,color .16s ease;
}
.tags.story-tags span{
  border:1px solid transparent;
  transition:background-color .14s ease,border-color .14s ease,transform .14s ease;
}
.tags.story-tags span:hover{transform:translateY(-1px)}
.story-sources summary{color:var(--ink,#11120f)}
.story-sources a{color:var(--accent,#e53935)}

/* Dark mode: one coherent visual language for everything after the article body. */
body[data-theme=dark] .preferred-source-v2846{
  background:#181a17;
  border-color:#343831;
  color:#f4f5ef;
  box-shadow:
    0 12px 30px rgba(0,0,0,.20),
    inset 0 1px 0 rgba(255,255,255,.025);
}
body[data-theme=dark] .preferred-source-v2846 strong{color:#f7f8f3}
body[data-theme=dark] .preferred-source-v2846 span{color:#b8bcb2}

body[data-theme=dark] .story-engagement-v2830{
  background:#171916;
  border-color:#343831;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.02);
}
body[data-theme=dark] .engagement-title-v2830{color:#f4f5ef}
body[data-theme=dark] .reaction-btn-v2830{
  background:#1f221e;
  border-color:#3a3f37;
  color:#f4f5ef;
}
body[data-theme=dark] .reaction-btn-v2830:hover{
  background:#282c26;
  border-color:rgba(229,57,53,.72);
}
body[data-theme=dark] .reaction-btn-v2830[aria-pressed="true"]{
  background:rgba(229,57,53,.17);
  border-color:#e53935;
  box-shadow:inset 0 0 0 1px rgba(229,57,53,.12);
}
body[data-theme=dark] .reaction-count-v2830{color:#c6cac0;opacity:1}
body[data-theme=dark] .reaction-status-v28301{color:#b8bcb2}
body[data-theme=dark] .reaction-status-v28301.error{color:#ff8581}

body[data-theme=dark] .story-tags{
  border-top-color:#30332d;
}
body[data-theme=dark] .tags.story-tags span{
  background:#20231e;
  border-color:#343831;
  color:#f3f4ef;
}
body[data-theme=dark] .tags.story-tags span:hover{
  background:#292d27;
  border-color:#4a5046;
}

body[data-theme=dark] .story-sources{
  border-top-color:#30332d;
  color:#aaada4;
}
body[data-theme=dark] .story-sources summary{
  color:#e1e4dc;
}
body[data-theme=dark] .story-sources a{
  color:#ff817d;
}
body[data-theme=dark] .story-sources a:hover{
  color:#ffaaa7;
}

/* Keyboard focus remains obvious on dark surfaces. */
body[data-theme=dark] .reaction-btn-v2830:focus-visible,
body[data-theme=dark] .story-sources summary:focus-visible,
body[data-theme=dark] .story-sources a:focus-visible{
  outline:2px solid #ff817d;
  outline-offset:3px;
}

@media(max-width:640px){
  .preferred-source-v2846>div[google-add-preferred-source-btn]{
    min-width:0;
    width:100%;
  }
}

@media(prefers-reduced-motion:reduce){
  .preferred-source-v2846,
  .story-engagement-v2830,
  .reaction-btn-v2830,
  .tags.story-tags span,
  .story-sources{
    transition:none!important;
  }
  .tags.story-tags span:hover,
  .reaction-btn-v2830:hover{transform:none}
}
