/**
 * A heuristic that applies CSS to tablet
 * viewports.
 *
 * Usage:
 * @include tablet-viewport() {
 *   :host {
 *     background-color: green;
 *   }
 * }
 */
/**
 * A heuristic that applies CSS to mobile
 * viewports (i.e. phones, not tablets).
 *
 * Usage:
 * @include mobile-viewport() {
 *   :host {
 *     background-color: blue;
 *   }
 * }
 */
/**
 * Convert a pixels given value into rem
 * 
 * @param pixels - Value in pixels to be converted (i.e. px)
 * @param context (optional) - Baseline value
 */
/**
 * Convert a font size to a dynamic font size.
 * Fonts that participate in Dynamic Type should use
 * dynamic font sizes.
 * @param size - The initial font size including the unit (i.e. px or pt)
 * @param unit (optional) - The unit to convert to. Use this if you want to
 * convert to a unit other than $baselineUnit.
 */
/**
 * Convert a font size to a dynamic font size but impose
 * a maximum font size.
 * @param size - The initial font size including the unit (i.e. px or pt)
 * @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
 * @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
 * convert to a unit other than $baselineUnit.
 */
/**
 * Convert a font size to a dynamic font size but impose
 * a minimum font size.
 * @param size - The initial font size including the unit (i.e. px or pt)
 * @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
 * @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
 * convert to a unit other than $baselineUnit.
 */
/**
 * Convert a font size to a dynamic font size but impose
 * maximum and minimum font sizes.
 * @param size - The initial font size including the unit (i.e. px or pt)
 * @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
 * @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
 * @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
 * convert to a unit other than $baselineUnit.
 */
:host {
  display: block;
  position: relative;
  width: 100%;
  overflow: hidden;
  /**
   * This is required to force WebKit
   * to create a new stacking context
   * otherwise the border radius is
   * temporarily lost when hovering over
   * the ion-item or expanding/collapsing
   * the accordion.
   */
  z-index: 0;
}

:host(.accordion-expanding) ::slotted(ion-item[slot=header]),
:host(.accordion-expanded) ::slotted(ion-item[slot=header]) {
  --border-width: 0px;
}

#content {
  overflow: hidden;
  will-change: max-height;
}

:host(.accordion-collapsing) #content {
  /* stylelint-disable-next-line declaration-no-important */
  max-height: 0 !important;
}

:host(.accordion-collapsed) #content {
  display: none;
}

:host(.accordion-expanding) #content {
  max-height: 0;
}

/**
 * Prevent margins of content-wrapper
 * from collapsing, breaking the animation.
 */
:host(.accordion-expanding) #content-wrapper {
  overflow: auto;
}

:host(.accordion-disabled) #header,
:host(.accordion-readonly) #header,
:host(.accordion-disabled) #content,
:host(.accordion-readonly) #content {
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  :host,
  #content {
    /* stylelint-disable declaration-no-important */
    transition: none !important;
  }
}
:host {
  position: relative;
}

:host::after {
  -webkit-margin-start: var(--token-space-400, var(--token-scale-400, 16px));
  margin-inline-start: var(--token-space-400, var(--token-scale-400, 16px));
  -webkit-margin-end: var(--token-space-400, var(--token-scale-400, 16px));
  margin-inline-end: var(--token-space-400, var(--token-scale-400, 16px));
  right: 0;
  left: 0;
  bottom: 0;
  display: block;
  position: absolute;
  height: var(--token-border-size-025, var(--token-scale-025, 1px));
  background-color: var(--token-border-default, var(--token-primitives-neutral-400, #d5d5d5));
  content: "";
  z-index: 3;
}

:host(.accordion-animated) {
  transition: all 300ms cubic-bezier(0.25, 0.8, 0.5, 1);
}

:host(.accordion-animated) #content {
  transition: max-height 300ms cubic-bezier(0.25, 0.8, 0.5, 1);
}

::slotted(ion-item[slot=header]) {
  --border-radius: inherit;
  --color: var(--token-text-default, var(--token-primitives-neutral-1200, #242424));
  --border-width: var(--token-border-size-0, var(--token-scale-0, 0px));
  --inner-border-width: var(--token-scale-0, 0px);
  --min-height: var(--token-scale-700, 28px);
  --padding-top: var(--token-space-300, var(--token-scale-300, 12px));
  --padding-end: var(--token-space-400, var(--token-scale-400, 16px));
  --padding-bottom: var(--token-space-300, var(--token-scale-300, 12px));
  --padding-start: var(--token-space-400, var(--token-scale-400, 16px));
  font-size: var(--token-font-size-450, 18px);
  font-weight: var(--token-font-weight-medium, 500);
  letter-spacing: var(--token-font-letter-spacing-0, 0%);
  line-height: var(--token-font-line-height-700, var(--token-scale-700, 28px));
  text-decoration: none;
  text-transform: none;
}

#content-wrapper {
  -webkit-padding-start: var(--token-space-400, var(--token-scale-400, 16px));
  padding-inline-start: var(--token-space-400, var(--token-scale-400, 16px));
  -webkit-padding-end: var(--token-space-400, var(--token-scale-400, 16px));
  padding-inline-end: var(--token-space-400, var(--token-scale-400, 16px));
  padding-top: var(--token-space-300, var(--token-scale-300, 12px));
  padding-bottom: var(--token-space-300, var(--token-scale-300, 12px));
  font-size: var(--token-font-size-350, 14px);
  font-weight: var(--token-font-weight-regular, 400);
  letter-spacing: var(--token-font-letter-spacing-0, 0%);
  line-height: var(--token-font-line-height-600, var(--token-scale-600, 24px));
  text-decoration: none;
  text-transform: none;
  color: var(--token-text-default, var(--token-primitives-neutral-1200, #242424));
}

:host(.accordion-disabled)::before {
  border-radius: inherit;
  right: 0;
  left: 0;
  top: 0;
  bottom: 0;
  position: absolute;
  background-color: var(--token-state-disabled, rgba(255, 255, 255, 0.6));
  content: "";
  pointer-events: none;
  z-index: 2;
}