/**
 * Typography
 */
b,
strong {
  font-weight: bolder;
}

sub,
sup {
  position: relative;
  font-size: var(--toddyi-size-0-75em);
  line-height: 0;
  vertical-align: baseline;
}

sub {
  bottom: var(--toddyi-size-neg-0-25em);
}

sup {
  top: var(--toddyi-size-neg-0-5em);
}

address,
blockquote,
dl,
ol,
p,
pre,
table,
ul {
  margin-top: 0;
  margin-bottom: var(--pico-typography-spacing-vertical);
  color: var(--pico-color);
  font-style: normal;
  font-weight: var(--pico-font-weight);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0;
  margin-bottom: var(--pico-typography-spacing-vertical);
  color: var(--pico-color);
  font-weight: var(--pico-font-weight);
  font-size: var(--pico-font-size);
  line-height: var(--pico-line-height);
  font-family: var(--pico-font-family);
}

h1 {
  --pico-color: var(--pico-h1-color);
}

h2 {
  --pico-color: var(--pico-h2-color);
}

h3 {
  --pico-color: var(--pico-h3-color);
}

h4 {
  --pico-color: var(--pico-h4-color);
}

h5 {
  --pico-color: var(--pico-h5-color);
}

h6 {
  --pico-color: var(--pico-h6-color);
}

:where(article, address, blockquote, dl, figure, form, ol, p, pre, table, ul) ~ :is(h1, h2, h3, h4, h5, h6) {
  margin-top: var(--pico-typography-spacing-top);
}

p {
  margin-bottom: var(--pico-typography-spacing-vertical);
}

hgroup {
  margin-bottom: var(--pico-typography-spacing-vertical);
}
hgroup > * {
  margin-top: 0;
  margin-bottom: 0;
}
hgroup > *:not(:first-child):last-child {
  --pico-color: var(--pico-muted-color);
  --pico-font-weight: unset;
  font-size: var(--toddyi-size-1rem);
}

:where(ol, ul) li {
  margin-bottom: calc(var(--pico-typography-spacing-vertical) * 0.25);
}

:where(dl, ol, ul) :where(dl, ol, ul) {
  margin: 0;
  margin-top: calc(var(--pico-typography-spacing-vertical) * 0.25);
}

ul li {
  list-style: square;
}

mark {
  padding: var(--toddyi-size-0-125rem) var(--toddyi-size-0-25rem);
  background-color: var(--pico-mark-background-color);
  color: var(--pico-mark-color);
  vertical-align: baseline;
}

blockquote {
  display: block;
  margin: var(--pico-typography-spacing-vertical) 0;
  padding: var(--pico-spacing);
  border-inline-end: none;
  border-inline-start: var(--toddyi-size-0-25rem) solid var(--pico-blockquote-border-color);
  border-inline-start: 0.25rem solid var(--pico-blockquote-border-color);
  border-inline-end: none;
}
blockquote footer {
  margin-top: calc(var(--pico-typography-spacing-vertical) * 0.5);
  color: var(--pico-blockquote-footer-color);
}

abbr[title] {
  border-bottom: var(--toddyi-size-1px) dotted;
  text-decoration: none;
  cursor: help;
}

ins {
  color: var(--pico-ins-color);
  text-decoration: none;
}

del {
  color: var(--pico-del-color);
}

::-moz-selection {
  background-color: var(--pico-text-selection-color);
}

::selection {
  background-color: var(--pico-text-selection-color);
}

/**
 * Link
 */
:where(a:not([role=button])),
[role=link] {
  --pico-color: var(--pico-primary);
  --pico-background-color: transparent;
  --pico-underline: var(--pico-primary-underline);
  outline: none;
  background-color: var(--pico-background-color);
  color: var(--pico-color);
  -webkit-text-decoration: var(--pico-text-decoration);
  text-decoration: var(--pico-text-decoration);
  text-decoration-color: var(--pico-underline);
  text-underline-offset: 0.125em;
  transition: background-color var(--pico-transition), color var(--pico-transition), box-shadow var(--pico-transition), -webkit-text-decoration var(--pico-transition);
  transition: background-color var(--pico-transition), color var(--pico-transition), text-decoration var(--pico-transition), box-shadow var(--pico-transition);
  transition: background-color var(--pico-transition), color var(--pico-transition), text-decoration var(--pico-transition), box-shadow var(--pico-transition), -webkit-text-decoration var(--pico-transition);
}
:where(a:not([role=button])):is([aria-current]:not([aria-current=false]), :hover, :active, :focus),
[role=link]:is([aria-current]:not([aria-current=false]), :hover, :active, :focus) {
  --pico-color: var(--pico-primary-hover);
  --pico-underline: var(--pico-primary-hover-underline);
  --pico-text-decoration: underline;
}
:where(a:not([role=button])):focus-visible,
[role=link]:focus-visible {
  box-shadow: 0 0 0 var(--pico-outline-width) var(--pico-primary-focus);
}
:where(a:not([role=button])).secondary,
[role=link].secondary {
  --pico-color: var(--pico-secondary);
  --pico-underline: var(--pico-secondary-underline);
}
:where(a:not([role=button])).secondary:is([aria-current]:not([aria-current=false]), :hover, :active, :focus),
[role=link].secondary:is([aria-current]:not([aria-current=false]), :hover, :active, :focus) {
  --pico-color: var(--pico-secondary-hover);
  --pico-underline: var(--pico-secondary-hover-underline);
}
:where(a:not([role=button])).contrast,
[role=link].contrast {
  --pico-color: var(--pico-contrast);
  --pico-underline: var(--pico-contrast-underline);
}
:where(a:not([role=button])).contrast:is([aria-current]:not([aria-current=false]), :hover, :active, :focus),
[role=link].contrast:is([aria-current]:not([aria-current=false]), :hover, :active, :focus) {
  --pico-color: var(--pico-contrast-hover);
  --pico-underline: var(--pico-contrast-hover-underline);
}

a[role=button] {
  display: inline-block;
}

/* Button — relocated to components/buttons.css (#55/#108) */

