/* Shared Scenvy typography for the website and editor interface. */
:root {
  --ui-font: "Inter Variable", ui-sans-serif, system-ui, sans-serif;
  --font-ui: var(--ui-font);
  --ui-font-weight: 400;
  --ui-line-height: 1.45;
  --ui-letter-spacing: -0.01em;
  --ui-prompt-line-height: 1.5;
  --ui-chat-line-height: 1.75;
  --ui-icon-stroke-width: 1.8;
  --ui-type-micro: 12px;
  --ui-type-caption: 13px;
  --ui-type-control: 14px;
  --ui-type-body: 15px;
  --ui-type-reading: 16px;
  --ui-type-lead: 18px;
  --ui-type-title: 20px;
}

@font-face {
  font-family: "Unbounded";
  src: url("./assets/unbounded-cyrillic.woff2") format("woff2");
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Unbounded";
  src: url("./assets/unbounded-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Rethink Sans";
  src: url("./assets/RethinkSans.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
}

/* The editor preview iframe owns its authored video typography. */
@font-face {
  font-family: "Inter Variable";
  src: url("./assets/InterVariable.woff2") format("woff2");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:where(.scenvy-design-system, .editor-ui, .scenvy-fatal) {
  font-family: var(--ui-font);
  font-size: var(--ui-type-body);
  font-weight: var(--ui-font-weight);
  line-height: var(--ui-line-height);
  letter-spacing: var(--ui-letter-spacing);
  font-optical-sizing: auto;
  font-synthesis: none;
}

/* Keep the product face while allowing headings, controls and long-form text
   to choose a suitable weight and line height. */
:is(.scenvy-design-system, .editor-ui, .scenvy-fatal) :where(*):not(:where([data-video-artwork], [data-video-artwork] *)) {
  font-family: inherit;
}

:is(.scenvy-design-system, .editor-ui, .scenvy-fatal) :where(h1, h2, h3, h4, h5, h6):not(:where([data-video-artwork], [data-video-artwork] *)) {
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

:where(.scenvy-design-system, .editor-ui, .scenvy-fatal) :where(input, textarea)::placeholder {
  font: inherit;
  letter-spacing: inherit;
}

/* Static editor action glyphs use the same soft outline as the web controls. */
.editor-ui :is(button, [role="button"]) :is(svg[stroke-width="2"], svg [stroke-width="2"]) {
  stroke-width: var(--ui-icon-stroke-width);
}
