:root {
  /* X10 theme colors */
  --colors-token-grey: #151515;
  --colors-token-green: #00bc84;
  --colors-token-white: #e8e8e8;
  --colors-token-white-alpha-48: rgba(255, 255, 255, 0.48);
  --colors-token-white-alpha-8: rgba(255, 255, 255, 0.08);
  --colors-token-black-60: #2b2b2b;

  --tv-color-platform-background: var(--colors-token-grey);
  --tv-color-pane-background: var(--colors-token-grey);
  --tv-color-toolbar-button-background-hover: var(--colors-token-white-alpha-8);
  --tv-color-toolbar-button-background-expanded: var(--colors-token-white-alpha-8);
  --tv-color-toolbar-button-background-active: var(--colors-token-white-alpha-8);
  --tv-color-toolbar-button-background-active-hover: var(--colors-token-white-alpha-8);
  --tv-color-toolbar-button-text: var(--colors-token-white-alpha-48);
  --tv-color-toolbar-button-text-hover: var(--colors-token-white);
  --tv-color-toolbar-button-text-active: var(--colors-token-white);
  --tv-color-toolbar-button-text-active-hover: var(--colors-token-white);
  --tv-color-item-active-text: var(--colors-token-white);
  --tv-color-toolbar-toggle-button-background-active: var(--colors-token-green);
  --tv-color-toolbar-toggle-button-background-active-hover: var(--colors-token-green);
  --tv-color-toolbar-divider-background: var(--colors-token-white-alpha-8);
  --tv-color-toolbar-save-layout-loader: var(--colors-token-white-alpha-8);

  --tv-color-popup-background: var(--colors-token-black-60);
  --tv-color-popup-element-text: var(--colors-token-white-alpha-48);
  --tv-color-popup-element-text-hover: var(--colors-token-white);
  --tv-color-popup-element-background-hover: var(--colors-token-white-alpha-8);
  --tv-color-popup-element-divider-background: var(--colors-token-white-alpha-8);
  --tv-color-popup-element-secondary-text: var(--colors-token-white);
  --tv-color-popup-element-hint-text: var(--colors-token-white);
  --tv-color-popup-element-text-active: var(--colors-token-white);
  --tv-color-popup-element-background-active: var(--colors-token-white-alpha-8);
  --tv-color-popup-element-toolbox-text: var(--colors-token-white);
  --tv-color-popup-element-toolbox-text-hover: var(--colors-token-white);
  --tv-color-popup-element-toolbox-text-active-hover: var(--colors-token-white);
  --tv-color-popup-element-toolbox-background-hover: var(--colors-token-green);
  --tv-color-popup-element-toolbox-background-active-hover: var(--colors-token-green);

  --tv-toolbar-opened-element-hover-border-radius: 4px;
}

/* Mobile */
@media (max-width: 480px) {
  html {
    font-size: 90%;
  }
}

/* Desktop, up to bp1728 */
@media (min-width: 480px) and (max-width: 1000px) {
  html {
    font-size: 70%;
  }
}

/* From bp1728 */
@media (min-width: 1000px) {
  html {
    font-size: 90%;
  }
}

/* Chart title */
.titlesWrapper-l31H9iuA {
  font-size: 14px !important;
}

/* Top toolbar - general */
.toolbar-qqNP9X6e {
  font-size: 1rem !important;
}

/* Values within selects */
.value-gwXludjS {
  font-size: 1rem !important;
}

/* Top toolbar - left items (interval) */
.item-jFqVJoPk {
  font-size: 1rem !important;
}

/* Bottom toolbar - left items (%/log/auto)*/
.item-BXXUwft2 {
  font-size: 1rem !important;
}

/* Bottom toolbar - right items (timeframe)*/
.item-SqYYy1zF {
  font-size: 1rem !important;
}

/* Dialogs (indicators, compare markets, calendar) */
html.theme-dark .dialog-aRAWUDhF {
  background-color: var(--colors-token-black-60);
}

/* Price type selector */
[data-is-custom-header-element] {
  padding: 0 10px 0 10px !important;
}

/* MOBILE */
@media (max-width: 480px) {
    /* We're targeting the parents of the items, which actually hold the width of each section */
    *:has(> [aria-label="Compare or Add Symbol"]),
    *:has(> div > [aria-label="Candles"]),
    *:has(> div > [aria-label="Indicators & Strategies"]),
    *:has(> [aria-label="All changes saved"]),
    *:has(> [aria-label="Manage layouts"]),
    *:has(> [aria-label="Quick Search"]),
    *:has(> [aria-label="Chart settings"]),
    *:has(> [aria-label="Take a snapshot"]),
    [aria-label="Go to"],
    *:has(> [aria-label="Timezone"]),
    *:has(> [aria-label="Toggle Percentage"]),
    *:has(> [aria-label="Toggle Log Scale"]) {
        display: none;
    }

    .separator-xVhBjD5m,
    .separator-yDfG9Ccu {
        display: none;
    }

    /* Timeframe selector (show "Date Range" instead of all timeframes) */
    *:has(> .dateRangeExpanded-BXXUwft2) {
        display: none;
    }
    .collapsed-BXXUwft2 {
        visibility: visible;
    }
}
