/*
 * sticky header
 */
body:has([data-testid="home-page-container"]) {
  height: auto !important;
}

body:has([data-testid="home-page-container"]) [data-testid="header"] {
  position: sticky;
  top: 0;
  z-index: 999;
  border-bottom: solid 1px #0003;
  box-shadow: 0 2px 4px #0003, 0 3px 8px #0006, 0 4px 12px #0009;
  box-shadow: 0 0 10px 6px #000c;
}

body:has([data-testid="home-page-container"]) .css-vnw1ik {
  position: sticky;
  top: 60px;
  z-index: 998;
  box-shadow: 0 2px 4px #0003, 0 3px 8px #0006, 0 4px 12px #0009;
  box-shadow: 0 4px 12px #000;
  box-shadow: 0 0 10px 6px #000c;
  background-color: rgb(26, 32, 44);
}

.css-1jhxu0 {
  color: revert;
}

/* footer - replace the heart and globel with emojis */
.css-1f08qtk {
  font-size: 0;
  padding: 0 2px;
  visibility: hidden;
}

.css-1f08qtk::before {
  content: "❤️";
  color: white;
  font-size: 16px;
  visibility: visible;
}

.css-16hvy3b {
  font-size: 0;
  height: revert;
  padding: 0 2px;
  visibility: hidden;
}

.css-16hvy3b::before {
  content: "🌎";
  color: white;
  font-size: 18px;
  visibility: visible;
}

.css-16hvy3b > svg {
  /* the globe svg */
  outline: 1px dashed red;
  display: none;
}

.css-dwaskj {
  /* the flag foldout */
  height: 22px;
  margin-left: 4px;
  position: relative;
  top: 1px;
}

.css-dwaskj::before {
  top: 6px;
  left: -5px;
}

.css-1g2l0a9 {
  /* the flag */
  width: 20px;
}

/*
 * remove some inline styles
 */
[data-testid="home-page-container"] > div {
  width: revert !important;
}

[data-testid="home-page-container"] [role="grid"] {
  overflow: revert !important;
  width: revert !important;
}

/*
 * list
 */
[data-testid="home-page-container"] [role="rowgroup"] {
  /* the box shadow on the inner elements requires overflow to be visible */
  overflow: revert !important;
}

/*
 * list-item
 */
[data-testid="home-page-container"] [role="rowgroup"] > div {
  /* the list item has absolute positioning set by JS. */
  /* the list item height is determined by its contents and set as an inline style by JS */
}

/*
 * list-item HR (on all items except first)
 */
[data-testid="home-page-container"] [role="rowgroup"] > div > hr {
  display: none;
}

/*
 * the UL wrapping the two LI elements
 */
[data-testid="package-item-list"] {
  list-style: none;
  margin: 0px;
  padding: 0;
  position: relative;
  /* --- */
  background-color: rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  padding: 1rem;
  -webkit-box-shadow: rgba(0, 0, 0, 0.8) 0px 0 10px;
  -moz-box-shadow: rgba(0, 0, 0, 0.8) 0 0 10px;
  box-shadow: rgba(0, 0, 0, 0.8) 0 0 10px;
  box-shadow: inset 0 0.125rem 0.25rem black;
  cursor: default;
  margin: 0 0 15px 0;
}
[data-testid="package-item-list"]:hover {
  background-color: revert;
  /* --- */
  background-color: rgba(255, 255, 255, 0.01);
  border-color: rgba(255, 255, 255, 0.25);
  -webkit-box-shadow: rgba(0, 0, 0, 1) 0px 0 10px;
  -moz-box-shadow: rgba(0, 0, 0, 1) 0 0 10px;
  box-shadow: rgba(0, 0, 0, 1) 0 0 10px;
}
[data-testid="package-item-list"] li {
  padding: 0;
}

.card-content, [data-testid="package-item-list"] li:first-of-type {
  display: flex;
  max-width: 100%;
  gap: 1rem;
}

.package-link {
  margin: 0;
  padding: 0;
}

.package-link > span {
  height: 42px;
}

.card-title, .package-link > span > div > div:first-of-type {
  margin: 0;
  text-shadow: 0 0.125rem 0.25rem black;
  overflow: hidden;
  max-width: 100%;
  
  max-width: calc(100% - 96px);
  overflow: hidden;
  position: relative;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-testid="package-title"] {
  color: revert;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 576px) {
  [data-testid="package-title"] {
    margin-bottom: 12px;
  }
}

a:has([data-testid="package-title"]) {
  background-color: rgba(0, 0, 0, 0);
  box-sizing: border-box;
  color: #3cf;
  cursor: pointer;
  font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 20px;
  font-weight: 400;
  font-weight: 700;

  text-decoration-color: #09c0;
  text-decoration-line: none;
  text-decoration-style: solid;
  text-decoration-thickness: auto;
  transition: 0.5s;
}

a:has([data-testid="package-title"]):hover {
  text-decoration-line: underline;
  text-decoration-color: #09cf;
  color: #6ef;
  transition: 0.5s;
}

.card-tags, .package-link > p > span:nth-child(2) {
  flex-direction: row;
  flex-wrap: wrap;
  display: flex;
  align-items: flex-start;
  align-content: flex-start;
  justify-content: flex-start;
  gap: 0.5rem;
  margin: 1rem 0 0;
}

.card-tag, .package-link > p > span:nth-child(2) span {
  background-color: rgba(0, 0, 0, 0);
  background-image: linear-gradient(to top, #123, #234);
  border: solid 1px #345;
  border-bottom-color: #234;
  border-radius: 0.375rem;
  box-sizing: border-box;
  color: rgba(255, 255, 255, 0.75);
  display: block;
  font-family: "JetBrains Mono", "Roboto Mono", "Fira Code", "Source Code Pro", "Inconsolata", "SF Mono", SFMono-Regular, ui-monospace, "Menlo-Regular", Menlo, monospaced;
  font-size: 12px;
  font-weight: 400;
  height: 21px;
  line-height: normal;
  list-style-image: none;
  list-style-position: outside;
  list-style-type: none;
  margin: 0;
  padding-bottom: 0px;
  padding-left: 4px;
  padding-right: 6px;
  padding-top: 0px;
  text-align: left;
  text-decoration-thickness: auto;
  text-size-adjust: 100%;
  vertical-align: middle;
  -webkit-font-smoothing: antialiased;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-tag::before, .package-link > p > span:nth-child(2) span::before {
  box-sizing: border-box;
  content: "🏷️";
  display: inline;
  height: auto;
  width: auto;
  margin-right: 4px;
  color: white;
}

@supports (-webkit-touch-callout: none) {
  /* CSS specific to iOS devices */ 
  .card-tag, .package-link > p > span:nth-child(2) span {
    /* the 'normal' line-height (20px) made the text and emoji rest a bit too low */
	line-height: 18px;
    position: relative;
  }
}

.card-meta, [data-testid="package-item-list"] li:last-of-type {
  color: blue;
  display: flex;
  flex-wrap: wrap;
  font-size: 12px;
  font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
  gap: 0 1rem;
  line-height: 12px;
  margin: 1rem 0 0;
  cursor: default;
}

.card-meta-author-icon, [data-testid="package-item-list"] li:last-of-type > div > div {
  border-radius: 50%;
  vertical-align: top;
  display: inline-block;
  height: 20px;
  overflow: hidden;
  user-select: none;
  width: 20px;
}
.card-meta-author-icon img, [data-testid="package-item-list"] li:last-of-type > div > div img {
  width: 100%;
  height: 100%;
}

.card-meta-author-text, [data-testid="package-item-list"] li:last-of-type > div > span > div,
.card-meta-version-text, [data-testid="package-item-list"] li:last-of-type > span,
.card-meta-publish-text, [data-testid="package-item-list"] li:last-of-type > span > span {
  color: #fff9 !important;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-testid="package-item-list"] li:last-of-type > span {
  height: 20px;
  margin: 0;
}

[data-type="version"]::before, [data-testid="package-item-list"] li:last-of-type > span:nth-of-type(1)::before {  content: "📦";}
[data-type="date"]::before,[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(2)::before { content: "📅"; }
[data-type="license"]::before,[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(3)::before { content: "⛔"; }

[data-type="version"]::before,
[data-type="date"]::before,
[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(1)::before,
[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(2)::before,
[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(3)::before {
  box-sizing: border-box;
  display: inline;
  height: auto;
  width: auto;
  position: relative;
  top: -1px;
  margin-right: 4px;
  color: white;
}

[data-testid="package-item-list"] li:last-of-type > span:nth-of-type(3)::before {
  top: -1px;
  margin-right: 3px;
}

[data-testid="package-item-list"] li:last-of-type > span > svg {
  display: none;
}

.card-links, .package-link > span > div > div:last-of-type {
  width: revert;
  /* --- */
  position: absolute;
  right: -2px;
  top: -2px;
  align-items: center;
  box-sizing: border-box;
  color: rgb(255, 255, 255);
  direction: ltr;
  display: flex;
  flex-basis: 0px;
  flex-direction: row;
  flex-grow: 1;
  font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  margin: 0;
  text-align: right;
  text-size-adjust: 100%;
  -webkit-box-align: center;
  -webkit-box-flex: 1;
  -webkit-font-smoothing: antialiased;
  
  background-color: rgb(11,14,20);
  border-radius: 8px;
  padding: 2px;
}

.card-links a, .package-link > span > div > div:last-of-type a {
  tabindex="-1"
  background-color: rgba(0, 0, 0, 0);
  box-sizing: border-box;
  color: rgb(0, 0, 238);
  cursor: pointer;
  direction: ltr;
  display: block;
  font-family: Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  font-weight: 400;
  height: 28.8438px;
  line-height: 24px;
  list-style-image: none;
  list-style-position: outside;
  list-style-type: none;
  text-align: right;
  text-decoration-color: rgb(0, 0, 238);
  text-decoration-line: underline;
  text-decoration-style: solid;
  text-decoration-thickness: auto;
  text-size-adjust: 100%;
  width: 28px;
  -webkit-font-smoothing: antialiased;
}

.card-links button:focus, .package-link > span > div > div:last-of-type button:focus,
.card-links button:hover, .package-link > span > div > div:last-of-type button:hover {
  background-color: rgba(255, 255, 255, 0.08);
  border-color: white;
  opacity: 1;
  
  transition-property: background-color, border-color;
  transition-duration: 0.5s;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.card-links button, .package-link > span > div > div:last-of-type button {
  opacity: 0.8;
  border: solid 1px white;
  border-color: transparent;
  border-radius: 50%;
  border-radius: 6px;

  align-items: center;
  appearance: button;
  background-color: rgba(0, 0, 0, 0);

  box-sizing: border-box;
  color: rgb(255, 255, 255);
  cursor: pointer;
  direction: ltr;
  display: inline-flex;
  flex-basis: auto;
  flex-grow: 0;
  flex-shrink: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 28px;
  font-stretch: 100%;
  font-style: normal;
  font-variant-caps: normal;
  font-variant-east-asian: normal;
  font-variant-ligatures: normal;
  font-variant-numeric: normal;
  font-weight: 400;
  height: 28px;
  justify-content: center;
  letter-spacing: normal;
  line-height: 32.2px;
  list-style-image: none;
  list-style-position: outside;
  list-style-type: none;
  margin-bottom: 0px;
  margin-left: 0px;
  margin-right: 0px;
  margin-top: 0px;
  outline-color: rgb(255, 255, 255);
  outline-style: none;
  outline-width: 0px;
  overflow-x: visible;
  overflow-y: visible;
  padding-bottom: 6px;
  padding-left: 6px;
  padding-right: 6px;
  padding-top: 6px;
  position: relative;
  text-align: center;
  text-decoration-color: rgb(255, 255, 255);
  text-decoration-line: none;
  text-decoration-style: solid;
  text-decoration-thickness: auto;
  text-indent: 0px;
  text-rendering: auto;
  text-shadow: none;
  text-size-adjust: 100%;
  text-transform: none;
  transition-delay: 0s;
  transition-duration: 0.15s;
  transition-property: background-color;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  vertical-align: middle;
  width: 28px;
  word-spacing: 0px;
  writing-mode: horizontal-tb;
  -webkit-box-align: center;
  -webkit-box-pack: center;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-border-image: none;
}

.card-links svg, .package-link > span > div > div:last-of-type svg {
  fill: white;
  height: 16px;
  width: 16px;

  box-sizing: border-box;
  cursor: pointer;
  direction: ltr;
  display: block;
  flex-shrink: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  font-stretch: 100%;
  font-style: normal;
  font-variant-caps: normal;
  font-variant-east-asian: normal;
  font-variant-ligatures: normal;
  font-variant-numeric: normal;
  font-weight: 400;
  letter-spacing: normal;
  line-height: 18.4px;
  list-style-image: none;
  list-style-position: outside;
  list-style-type: none;
  overflow-x: hidden;
  overflow-y: hidden;
  text-align: center;
  text-decoration-thickness: auto;
  text-indent: 0px;
  text-rendering: auto;
  text-shadow: none;
  text-size-adjust: 100%;
  text-transform: none;
  transition-delay: 0s;
  transition-duration: 0.2s;
  transition-property: fill;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  word-spacing: 0px;
  writing-mode: horizontal-tb;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

/*
 * light-mode overrides
 */
.dark-mode, .css-1emskik {
}

.light-mode, .css-ws4un3 {
}

/* sticky search foldout */
.css-ws4un3 .css-vnw1ik {
  background-color: #eee;
}

/* title */
.css-ws4un3 a:has([data-testid="package-title"]) {
  color: rgb(75, 94, 64);;
  text-decoration-color: #09c0;
}

.css-ws4un3 a:has([data-testid="package-title"]):hover {
  color: #382;
  text-decoration-color: #453f;
}

.css-ws4un3 .package-link > span > div > div:first-of-type {
  text-shadow: 0 0.125rem 0.25rem white;
}

/* links */
.css-ws4un3 .package-link > span > div > div:last-of-type {
  color: rgb(255, 255, 255);
  background-color: rgb(75, 94, 64);
}

/* tags */
.css-ws4un3 .package-link > p > span:nth-child(2) span {
  background-color: rgba(0, 0, 0, 0);
  background-image: linear-gradient(to top, #cde, #def);
  border: solid 1px #789;
  border-bottom-color: #678;
  color: rgba(0, 0, 0, 0.75);
}

/* meta */
.css-ws4un3 [data-testid="package-item-list"] li:last-of-type > div > span > div,
.css-ws4un3 [data-testid="package-item-list"] li:last-of-type > span,
.css-ws4un3 [data-testid="package-item-list"] li:last-of-type > span > span {
  color: #0009 !important;
}

