/* Trading-platform logos and favorite controls use the same treatment across templates. */
html body .fc-platform-mark {
  display: inline-grid;
  position: relative;
  flex: 0 0 auto;
  place-items: center;
  vertical-align: middle;
  min-width: 36px;
  max-width: 100%;
  min-height: 36px;
  margin-inline-end: 3px;
  padding: 4px;
  border: 1px solid #dcd2e8;
  border-radius: 9px;
  background: #fff;
}

html body .fc-platform-mark img {
  display: block;
  width: auto !important;
  min-width: 18px;
  height: 27px !important;
  max-width: 82px !important;
  object-fit: contain;
  border: 0;
  border-radius: 4px;
}

html[data-theme="dark"] body .fc-platform-mark { border-color: #9e8eac; }
html body .fc-platform-mark:focus-visible { outline: 2px solid #9761d4; outline-offset: 2px; }
html body .fc-platform-legend[hidden] { display: none !important; }

html body .fc-p-tags > span:has(.fc-platform-mark),
html body .fc-platform-pill:has(.fc-platform-mark) {
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

html body .fc-watch-btn,
html body .fc-watch-btn:is(:hover, .active, .compact),
html body .fc-p-actions .fc-watch-btn,
html body #fc-firm-grid .fc-row-brand .fc-watch-btn {
  --fc-heart-ink: #7137a2;
  --fc-heart-saved: #a52058;
  --fc-heart-shape: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' d='M20.8 4.8a5.5 5.5 0 0 0-7.8 0L12 6l-1.1-1.2a5.5 5.5 0 0 0-7.8 7.8l1.1 1.1L12 21l7.8-7.3 1-1.1a5.5 5.5 0 0 0 0-7.8Z'/%3E%3C/svg%3E");
  display: inline-flex !important;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 44px !important;
  min-height: 44px !important;
  padding: 6px 10px !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--fc-heart-ink) !important;
  font-size: 0 !important;
  line-height: 1;
  cursor: pointer;
}

html[data-theme="dark"] body .fc-watch-btn,
html[data-theme="dark"] body .fc-p-actions .fc-watch-btn,
html[data-theme="dark"] body #fc-firm-grid .fc-row-brand .fc-watch-btn {
  --fc-heart-ink: #e2c5fa;
  --fc-heart-saved: #ffabcf;
}

html body .fc-watch-btn::before {
  content: "";
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  background: currentColor;
  transition: transform .16s ease;
  -webkit-mask: var(--fc-heart-shape) center / contain no-repeat;
  mask: var(--fc-heart-shape) center / contain no-repeat;
}

html body .fc-watch-btn[aria-pressed="true"],
html body .fc-p-actions .fc-watch-btn[aria-pressed="true"],
html body #fc-firm-grid .fc-row-brand .fc-watch-btn[aria-pressed="true"] {
  --fc-heart-shape: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M20.8 4.8a5.5 5.5 0 0 0-7.8 0L12 6l-1.1-1.2a5.5 5.5 0 0 0-7.8 7.8l1.1 1.1L12 21l7.8-7.3 1-1.1a5.5 5.5 0 0 0 0-7.8Z'/%3E%3C/svg%3E");
  color: var(--fc-heart-saved) !important;
}

html body .fc-watch-btn > span:not(:empty) { font-size: 12px; line-height: 1.2; }
html body .fc-watch-btn:disabled { cursor: wait; }
html body .fc-watch-btn:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

@media (hover: hover) {
  html body .fc-watch-btn:not(:disabled):hover::before { transform: scale(1.12); }
}

@media (prefers-reduced-motion: reduce) {
  html body .fc-watch-btn::before { transition: none; }
  html body .fc-watch-btn:hover::before { transform: none; }
}

/* Quantower supplies a white mark. Use its dark contrast surface in both themes. */
html body .fc-platform-mark[data-platform-mark="quantower"] { background: #202137; }
