@import './markdown.scss';
@import './ant.scss';
@import '../fonts/icon-fonts/iconfont.css';
@import '../fonts/ubuntu/ubuntu.css';

:root {
  --color-white: #ffffff;
  --color-white-soft: rgba(255, 255, 255, 0.8);
  --color-white-mute: rgba(255, 255, 255, 0.94);

  --color-black: #181818;
  --color-black-soft: #202020;
  --color-black-mute: #262626;

  --color-gray-1: #515c67;
  --color-gray-2: #414853;
  --color-gray-3: #32363f;

  --color-text-1: rgba(255, 255, 245, 0.86);
  --color-text-2: rgba(235, 235, 245, 0.6);
  --color-text-3: rgba(235, 235, 245, 0.38);

  --color-background: var(--color-black);
  --color-background-soft: var(--color-black-soft);
  --color-background-mute: var(--color-black-mute);

  --color-primary: #00b96b;
  --color-primary-soft: #00b96b99;
  --color-primary-mute: #00b96b33;

  --color-text: var(--color-text-1);
  --color-icon: #ffffff99;
  --color-icon-white: #ffffff;
  --color-border: #ffffff24;
  --color-border-soft: #ffffff20;
  --color-error: #f44336;
  --color-link: #1677ff;
  --color-code-background: #323232;
  --color-scrollbar-thumb: rgba(255, 255, 255, 0.08);
  --color-scrollbar-thumb-hover: rgba(255, 255, 255, 0.15);
  --color-scrollbar-thumb-active: rgba(255, 255, 255, 0.2);
  --color-hover: rgba(40, 40, 40, 1);
  --color-active: rgba(55, 55, 55, 1);

  --navbar-background-mac: rgba(30, 30, 30, 0.6);
  --navbar-background: rgba(30, 30, 30);

  --navbar-height: 40px;
  --sidebar-width: 50px;
  --status-bar-height: 40px;
  --input-bar-height: 85px;

  --assistants-width: 275px;
  --topic-list-width: 275px;
  --settings-width: 250px;
}

body[theme-mode='light'] {
  --color-white: #ffffff;
  --color-white-soft: #f2f2f2;
  --color-white-mute: #eee;

  --color-black: #1b1b1f;
  --color-black-soft: #262626;
  --color-black-mute: #363636;

  --color-gray-1: #8e8e93;
  --color-gray-2: #aeaeb2;
  --color-gray-3: #c7c7cc;

  --color-text-1: rgba(0, 0, 0, 1);
  --color-text-2: rgba(0, 0, 0, 0.6);
  --color-text-3: rgba(0, 0, 0, 0.38);

  --color-background: var(--color-white);
  --color-background-soft: var(--color-white-soft);
  --color-background-mute: var(--color-white-mute);

  --color-primary: #00b96b;
  --color-primary-soft: #00b96b99;
  --color-primary-mute: #00b96b33;

  --color-text: var(--color-text-1);
  --color-icon: #00000099;
  --color-icon-white: #000000;
  --color-border: #00000028;
  --color-border-soft: #00000028;
  --color-error: #f44336;
  --color-link: #1677ff;
  --color-code-background: #e3e3e3;
  --color-scrollbar-thumb: rgba(0, 0, 0, 0.08);
  --color-scrollbar-thumb-hover: rgba(0, 0, 0, 0.15);
  --color-scrollbar-thumb-active: rgba(0, 0, 0, 0.2);
  --color-hover: var(--color-white-mute);
  --color-active: var(--color-white-soft);

  --navbar-background-mac: rgba(255, 255, 255, 0.6);
  --navbar-background: rgba(255, 255, 255);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  font-weight: normal;
}

*:focus {
  outline: none;
}

* {
  -webkit-tap-highlight-color: transparent;
}

ul {
  list-style: none;
}

body {
  display: flex;
  min-height: 100vh;
  color: var(--color-text);
  font-size: 14px;
  line-height: 1.6;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans',
    'Helvetica Neue', sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s linear;
}

a {
  -webkit-user-drag: none;
}

html,
body,
#root {
  height: 100%;
  margin: 0;
}

#root {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: row;
  flex: 1;
}

#content-container {
  background-color: var(--color-background);
  border-top: 0.5px solid var(--color-border);
}

body[os='mac'] {
  #content-container {
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
    border-top-right-radius: 10px;
    border-left: 0.5px solid var(--color-border);
    box-shadow: 0 0 15px 1px rgba(0, 0, 0, 0.05);
  }
}

body[os='windows'] {
  #app-sidebar {
    border-right: 0.5px solid var(--color-border);
  }
}

.loader {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: #000;
  box-shadow:
    32px 0 #000,
    -32px 0 #000;
  position: relative;
  animation: flash 0.5s ease-out infinite alternate;
}

.drag {
  -webkit-app-region: drag;
}

.nodrag {
  -webkit-app-region: no-drag;
}

.text-nowrap {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
