@use "../../wc";

:host {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  *, *::before, *::after {
    box-sizing: border-box;
    border-width: 0;
    border-style: solid;
    border-color: rgb(var(--zn-border-color));
  }
}

zn-header div[slot='actions'] {
  display: flex;
  align-items: center;
  gap: 10px;
}

.content-block--collapsible {
  zn-header::part(base) {
    cursor: pointer;
  }
}

zn-header::part(header-left) {
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

zn-navbar {
  cursor: default;
}

.content-block--short {
  zn-sp, zn-navbar {
    display: none;
  }

  zn-header::part(base) {
    border-bottom: none;
  }
}

zn-panel.content-block--short::part(mid) {
  display: none;
}

zn-panel.content-block--short zn-header::part(header-description) {
  @include wc.container-query(null, ph) {
    display: none;
  }
}

zn-panel:not(.content-block--short) zn-header::part(header-description) {
  display: none;
}

.text-section {
  font-size: 13px;
  line-height: 19px;

  a {
    font-size: 10px;
    opacity: 0.8;
  }
}

.hidden {
  display: none;
}

ol {
  counter-reset: list-0 0;
}

@supports (counter-set:none) {
  ol li, ul li {
    counter-set: list-1 0 list-2 0 list-3 0 list-4 0 list-5 0 list-6 0 list-7 0 list-8 0 list-9 0;
  }
}

ol, ul {
  padding: 0;
  margin: 0;
}

li[data-list=checked] > .ql-ui, li[data-list=unchecked] > .ql-ui {
  color: #777;
}

li {
  list-style-type: none;
  padding-left: 1em;
  position: relative;
}

ul > li::before {
  content: "•";
}

ol > li {
  counter-increment: list-0;
}

ol > li::before {
  content: counter(list-0) ". ";
}

/* Checkbox list markers */
li[data-list="checked"]::before {
  content: "☑";
}

li[data-list="unchecked"]::before {
  content: "☐";
}

li[data-list="checked"]::before,
li[data-list="unchecked"]::before {
  color: #777;
}

ol li::before,
ul li::before {
  display: inline-block;
  margin-left: -1.5em;
  margin-right: 0.3em;
  text-align: right;
  white-space: nowrap;
  width: 1.2em;
}

li:has(> .ql-ui)::before {
  content: none;
  display: none;
}
