* {
  box-sizing: border-box;
}

*:active {
  outline: none;
}

*:focus-visible {
  outline: none;
  box-shadow: var(--const-double-focus-ring, 0 0 0 2px #ffffff, 0 0 0 4px #0066cc);
}

:host {
  box-shadow: none !important;
}

::-moz-focus-inner {
  border: none;
}

input,
textarea,
button {
  font-family: inherit;
  font-size: inherit;
  font-stretch: inherit;
}

:host(.sr),
:host(.sr) button {
  border: 0;
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  white-space: nowrap;
}

.sr,
.sr button {
  border: 0;
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  white-space: nowrap;
}

.hidden {
  display: none;
}

:host([hidden]) {
  display: none;
}

.invisible {
  visibility: hidden;
}

@container style(--t-prefers-motion: "reduced") {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    transition-delay: 0ms !important;
  }
}
@container (not style(--t-prefers-motion: "normal")) and (not style(--t-prefers-motion: "reduced")) {
  @media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
      animation-duration: 0.01ms !important;
      transition-duration: 0.01ms !important;
      animation-delay: 0ms !important;
      transition-delay: 0ms !important;
    }
  }
}
/**
 * @prop --tct-pagination-color?: (<color>) Controls the optional text color of the pagination container.
 * @prop --tct-pagination-font-size?: (<length-percentage>) Controls the optional font size of pagination text.
 * @prop --tct-pagination-font-weight?: (<number>) Controls the optional font weight of pagination text.
 * @prop --tct-pagination-height: (<length>) Controls the height of the pagination container and input wrapper.
 * @prop --tct-pagination-column-gap: (<length-percentage>) Controls the column gap between pagination groups.
 * @prop --tct-pagination-row-gap: (<length-percentage>) Controls the row gap between pagination groups in the stacked layout.
 * @prop --tct-pagination-controls-gap: (<length-percentage>) Controls the gap between elements within the input-display controls.
 * @prop --tct-pagination-btn-gap?: (<length-percentage>) Controls the optional gap between previous/next buttons in the button group.
 * @prop --tct-pagination-btn-border?: (*) Controls the optional border shorthand of pagination buttons.
 * @prop --tct-pagination-btn-border-radius?: (<length-percentage>) Controls the optional corner radius of pagination buttons.
 * @prop --tct-pagination-btn-hover-background: (<color>) Controls the background color of pagination buttons on hover.
 * @prop --tct-pagination-btn-icon-stroke-primary: (<color>) Controls the primary stroke color of pagination button icons.
 * @prop --tct-pagination-btn-icon-stroke-secondary: (<color>) Controls the secondary stroke color of pagination button icons.
 * @prop --tct-pagination-icon-color: (<color>) Controls the color of pagination icons (non-button icons).
 * @prop --tct-pagination-icon-size: (<length>) Controls the size of pagination icons (non-button icons).
 * @prop --tct-pagination-input-height: (<length>) Controls the height of the pagination page-number input.
 * @prop --tct-pagination-input-width: (<length>) Controls the width of the pagination page-number input.
 * @prop --tct-pagination-select-height: (<length>) Controls the height of the per-page select input.
 * @prop --tct-pagination-perpage-width: (<length-percentage>) Controls the width of the per-page select.
 * @prop --tct-pagination-perpage-min-width: (<length>) Controls the minimum width of the per-page select.
 */
:host {
  display: flex;
  width: 100%;
}

:host([align=right]),
:host([alignment=right]) {
  justify-content: flex-end;
}

:host([align=center]),
:host([alignment=center]) {
  justify-content: center;
}

:host([align=left]),
:host([alignment=left]) {
  justify-content: flex-start;
}

:host([hidden]) {
  display: none;
}

.container {
  display: inline-flex;
  column-gap: var(--tct-pagination-column-gap, var(--t-pagination-column-gap, var(--app-scale-2x, 10px)));
  align-items: center;
  height: var(--tct-pagination-height, var(--t-pagination-height, 44px));
  color: var(--tct-pagination-color, inherit);
  font-size: var(--tct-pagination-font-size, inherit);
  font-weight: var(--tct-pagination-font-weight, inherit);
}
.container.stacked {
  flex-direction: column;
  column-gap: 0;
  row-gap: var(--tct-pagination-row-gap, var(--app-scale-2x, 10px));
  height: auto;
  align-items: stretch;
}
.container.stacked .description {
  text-align: center;
}
.container.stacked .controls {
  justify-content: center;
}
.container.stacked .per-page {
  display: flex;
  justify-content: center;
}
.container.stacked q2-select {
  --tct-select-margin: 0;
  width: var(--tct-pagination-perpage-width, 60%);
}

.controls {
  display: flex;
}

.btn-group {
  display: flex;
  gap: var(--tct-pagination-btn-gap, var(--t-pagination-btn-gap, 0));
}

.description,
.input-display {
  white-space: nowrap;
}

.input-display {
  display: grid;
  grid-template-columns: auto var(--tct-pagination-input-width, 50px) auto;
  align-items: center;
  gap: var(--tct-pagination-controls-gap, var(--t-pagination-controls-gap, var(--app-scale-1x, 5px)));
}
.input-display[hidden] {
  display: none;
}

.input-wrapper {
  height: var(--tct-pagination-height, var(--t-pagination-height, 44px));
  display: flex;
  align-items: center;
}

q2-btn {
  --tct-btn-border-radius: var(--tct-pagination-btn-border-radius, var(--t-pagination-btn-border-radius));
  --tct-btn-border: var(--tct-pagination-btn-border, var(--t-pagination-btn-border));
  --tct-btn-icon-hover-background: var(--tct-pagination-btn-hover-background, var(--app-gray-l3, #f2f2f2));
  --tct-icon-stroke-primary: var(--tct-pagination-btn-icon-stroke-primary, var(--app-gray, #747474));
  --tct-icon-stroke-secondary: var(--tct-pagination-btn-icon-stroke-secondary, var(--app-gray, #747474));
}

q2-icon {
  --tct-icon-size: var(--tct-pagination-icon-size, var(--t-pagination-icon-size, 12px));
  color: var(--tct-pagination-icon-color, var(--t-pagination-icon-color, var(--t-text, #4d4d4d)));
}

q2-input {
  --tct-input-margin-top: 0;
  --tct-input-margin-bottom: 0;
  --tct-input-height: var(--tct-pagination-input-height, var(--t-pagination-input-height, 30px));
  --tct-input-min-height: var(--tct-input-height);
  --tct-input-align: center;
}

q2-select {
  --tct-input-align: start;
  --tct-select-input-min-height: var(--tct-pagination-select-height, var(--t-pagination-select-height, 30px));
  --tct-select-input-max-height: var(--tct-pagination-select-height, var(--t-pagination-select-height, 30px));
  width: var(--tct-pagination-perpage-width, var(--t-pagination-perpage-width, 100%));
  min-width: var(--tct-pagination-perpage-min-width, var(--t-pagination-perpage-min-width, 110px));
}