/* Fonts */
@font-face {
  font-family: Archivo;
  src: url("fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("fonts/geist-mono-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
/* Theme tokens */
:root {
  --bg: #f2f1ee;
  --sunken: #e9e8e4;
  --ink: #101014;
  --muted: #656562;
  --faint: #797975;
  --line: #cfcec9;
  --good: #08775e;
  --warning: #906000;
  --bad: #a62e32;
  --sans: Archivo, system-ui, sans-serif;
  --mono: "Geist Mono", "Liberation Mono", "DejaVu Sans Mono", ui-monospace, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #111214;
  --sunken: #08090a;
  --ink: #f4f3f0;
  --muted: #a4a5a3;
  --faint: #959694;
  --line: #343538;
  --good: #65d3b1;
  --warning: #f3c366;
  --bad: #ff9196;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111214;
    --sunken: #08090a;
    --ink: #f4f3f0;
    --muted: #a4a5a3;
    --faint: #959694;
    --line: #343538;
    --good: #65d3b1;
    --warning: #f3c366;
    --bad: #ff9196;
    color-scheme: dark;
  }
}
/* Base and shared controls */
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 14px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button,
select,
input {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 0;
}
button,
select {
  cursor: pointer;
}
button {
  padding: 8px 12px;
}
button:hover,
a.button:hover {
  background: var(--sunken);
}
a:hover {
  text-decoration: underline;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.hud-label,
.segments button,
.open,
.menu summary,
.card-links,
.status-pill {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.faint {
  color: var(--faint);
}
.wrap {
  width: 100%;
  max-width: 1480px;
  margin: auto;
  padding: 0 28px;
}
/* Brand, view controls and account */
.topbar {
  display: flex;
  align-items: center;
  min-height: 58px;
  border-bottom: 1px solid var(--line);
  padding: 0 20px;
  gap: 20px;
  background: var(--bg);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  white-space: nowrap;
  padding-right: 20px;
  border-right: 1px solid var(--line);
  min-height: 58px;
}
.brand img {
  object-fit: contain;
}
.suite {
  color: var(--muted);
  white-space: nowrap;
}
.topbar-end {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
}
.view-switch {
  border-left: 1px solid var(--line);
  padding-left: 12px;
}
.segments {
  display: flex;
  align-items: stretch;
}
.segments button {
  white-space: nowrap;
  border-right: 0;
  padding: 10px 12px;
}
.segments button:last-child {
  border-right: 1px solid var(--line);
}
.segments button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.view-switch button {
  border: 0 !important;
  padding: 5px 8px;
}
.theme-control select {
  max-width: 142px;
  padding: 7px;
  font-size: 12px;
}
.account {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 12px;
}
.account button {
  font-size: 12px;
  padding: 5px 8px;
}
.account a {
  text-decoration: none;
}
/* Toolbar */
.lineup {
  min-height: 55vh;
}
.toolbar {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 20px 0 8px;
}
.search-sort {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-left: auto;
}
.sort-control {
  display: flex;
  align-items: center;
  gap: 8px;
}
.sort-control select {
  padding: 8px 10px;
  max-width: 210px;
}
input[type="search"] {
  padding: 8px 12px;
  width: 210px;
  background: var(--sunken);
}
/* App list: grid cards */
#apps {
  margin: 18px 0 30px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.card {
  --app: #808080;
  --app-ink: var(--app-light);
  min-width: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
}
.app-tint {
  --app-ink: var(--app-light);
}
:root[data-theme="dark"] .app-tint {
  --app-ink: var(--app-dark);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .app-tint {
    --app-ink: var(--app-dark);
  }
}
.card-head {
  min-height: 40px;
  padding: 8px 19px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--line);
  gap: 10px;
}
.number {
  background: var(--app);
  color: #08090a;
  font: 700 11px var(--mono);
  letter-spacing: 0.14em;
  padding: 4px 7px;
}
.card-links {
  display: flex;
  gap: 13px;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--muted);
}
.card-links a {
  text-decoration: none;
}
.card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 19px 19px;
  min-height: 235px;
}
/* App identity and status */
.identity {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
}
.logo {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 12px;
}
.monogram {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--app);
  color: #08090a;
  font-size: 28px;
  font-weight: 700;
}
.identity-text {
  min-width: 0;
  padding-top: 1px;
}
.name {
  margin: 0;
  font-weight: 680;
  font-stretch: 110%;
  letter-spacing: -0.025em;
  font-size: 23px;
  line-height: 1.2;
}
.accent {
  color: var(--app-ink);
}
.tagline {
  color: var(--muted);
  margin: 7px 0 0;
  font-size: 14px;
  line-height: 1.45;
}
.status-pill {
  align-self: flex-start;
  display: inline-block;
  border: 1px solid var(--line);
  padding: 2px 5px;
  color: var(--good);
  font-size: 10px;
  letter-spacing: 0.05em;
  white-space: nowrap;
}
.status-pill.installing {
  color: var(--warning);
}
.status-pill.failed {
  color: var(--bad);
}
.card-body > .status-pill {
  margin: 24px 0 0;
}
.version {
  color: var(--muted);
  margin: 13px 0 15px;
  font-size: 13px;
}
.identity + .version {
  margin-top: 24px;
}
/* Open links and app menus */
.actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
}
/* Open: outlined, as in ArtCraft Launcher (filled buttons there are for installs and updates). */
.open {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  border: 1px solid var(--muted);
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.15em;
  padding: 8px 16px;
  flex: 1;
}
.open:hover {
  background: var(--sunken);
  border-color: var(--ink);
  text-decoration: none;
}
.open.disabled {
  border-color: var(--line);
  background: transparent;
  color: var(--faint);
  cursor: default;
}
.menu {
  position: relative;
  flex-shrink: 0;
}
.menu summary {
  list-style: none;
  cursor: pointer;
  width: 37px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  font-size: 17px;
  letter-spacing: 0;
}
.menu summary::-webkit-details-marker {
  display: none;
}
.menu[open] summary {
  background: var(--sunken);
}
.menu-items {
  position: absolute;
  right: 0;
  top: 40px;
  z-index: 5;
  min-width: 215px;
  max-width: calc(100vw - 48px);
  padding: 5px;
  background: var(--bg);
  border: 1px solid var(--line);
  box-shadow: 0 6px 18px #0002;
}
.menu-items a {
  display: block;
  padding: 9px 12px;
  text-decoration: none;
  font-size: 13px;
}
.menu-items a:hover {
  background: var(--sunken);
}
/* Horizontally scrolling table */
.table-scroll {
  position: relative;
  overflow-x: auto;
  padding-bottom: 3px;
}
.app-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  min-width: 720px;
  text-align: left;
  table-layout: fixed;
}
.app-table th:nth-child(1) {
  width: 46%;
}
.app-table th:nth-child(2),
.app-table th:nth-child(3) {
  width: 17%;
}
.app-table th {
  font: 400 10px var(--mono);
  color: var(--faint);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
}
.app-table td {
  border-bottom: 1px solid var(--line);
  padding: 14px 16px;
  vertical-align: middle;
  white-space: nowrap;
}
.app-table .app-cell {
  white-space: normal;
}
.app-table .logo {
  width: 40px;
  height: 40px;
  border-radius: 8px;
}
.app-table .identity {
  gap: 12px;
  align-items: center;
}
.app-table .name {
  font-size: 18px;
}
.app-table .tagline {
  font-size: 12px;
  margin-top: 3px;
}
.app-table .version-cell {
  font: 13px var(--mono);
}
.app-table .released-cell {
  color: var(--muted);
  font-size: 13px;
}
.app-table .actions {
  min-width: 145px;
}
.app-table .menu-items {
  top: auto;
  bottom: 40px;
}
/* Footer and notices */
.footer {
  border-top: 1px solid var(--line);
  padding-top: 14px;
  padding-bottom: 24px;
  color: var(--muted);
  font-size: 12px;
}
.footer p {
  margin: 7px 0;
}
.footer a {
  text-underline-offset: 3px;
}
.notice {
  border: 1px solid var(--line);
  padding: 12px;
  margin-bottom: 0;
  color: var(--warning);
}
.placeholder {
  padding: 32px 0;
  color: var(--muted);
}
/* App details and screenshot gallery */
.details {
  padding: 24px 0 40px;
  max-width: 1100px;
  margin: auto;
}
.back-link {
  display: inline-block;
  margin-bottom: 28px;
  text-decoration: none;
}
.details-hero {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-bottom: 30px;
}
.details-hero .logo {
  width: 88px;
  height: 88px;
  border-radius: 18px;
}
.details-hero .name {
  font-size: 38px;
}
.headline {
  font-size: clamp(24px, 3.5vw, 42px);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.2;
  max-width: 850px;
  margin: 0 0 24px;
}
.about {
  max-width: 850px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}
.details-heading {
  margin: 34px 0 16px;
  font-size: 12px;
  font-weight: 500;
}
.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-left: 1px solid var(--line);
  border-top: 1px solid var(--line);
}
.feature {
  padding: 20px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.feature h3 {
  margin: 0 0 9px;
  font-size: 17px;
}
.feature p {
  margin: 0;
  color: var(--muted);
}
.gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 30px;
}
.gallery figure {
  margin: 0;
}
.gallery img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  display: block;
}
.gallery figcaption {
  color: var(--muted);
  margin-top: 8px;
  font-size: 13px;
}
.platforms {
  color: var(--muted);
  margin: 25px 0;
}
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
}
.detail-actions .open {
  flex: none;
  min-width: 180px;
}
.details .status-pill {
  margin-bottom: 16px;
}
/* Responsive layout */
@media (max-width: 1200px) {
  .topbar {
    flex-wrap: wrap;
    gap: 10px 18px;
  }
  .topbar-end {
    gap: 12px;
  }
  .account {
    font-size: 11px;
    gap: 8px;
  }
  .suite {
    font-size: 10px;
  }
  .toolbar {
    gap: 10px;
  }
  .search-sort {
    margin-left: auto;
  }
  #count {
    order: 3;
    width: 100%;
    margin-top: 4px;
  }
  .card-links {
    font-size: 9px;
    gap: 8px;
  }
}
@media (max-width: 950px) {
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .topbar-end {
    flex-basis: 100%;
    justify-content: flex-start;
    margin: 0;
    padding-bottom: 12px;
  }
  .view-switch {
    border: 0;
    padding: 0;
  }
  .account {
    margin-left: auto;
  }
  .toolbar {
    gap: 14px;
  }
  .search-sort {
    margin-left: 0;
    flex: 1;
    justify-content: flex-end;
  }
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .wrap {
    padding-left: 16px;
    padding-right: 16px;
  }
  .topbar {
    padding: 0 16px;
    gap: 10px;
  }
  .brand {
    font-size: 21px;
    padding-right: 12px;
  }
  .suite {
    font-size: 9px;
    letter-spacing: 0.08em;
  }
  .topbar-end {
    flex-wrap: wrap;
    gap: 12px;
  }
  .account {
    flex-basis: 100%;
    margin: 0;
  }
  .toolbar {
    padding-top: 18px;
  }
  .search-sort {
    width: 100%;
    justify-content: space-between;
    gap: 8px;
  }
  .sort-control {
    gap: 5px;
  }
  .sort-control > span {
    display: none;
  }
  .sort-control select {
    max-width: 150px;
    font-size: 12px;
  }
  input[type="search"] {
    width: 160px;
    font-size: 12px;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .group-head {
    margin-bottom: 16px;
    font-size: 10px;
  }
  .group {
    margin-top: 24px;
  }
  .card-body {
    min-height: 233px;
  }
  .card-links {
    font-size: 10px;
    gap: 13px;
  }
  .features,
  .gallery {
    grid-template-columns: 1fr;
  }
  .details-hero .name {
    font-size: 30px;
  }
  .details-hero .logo {
    width: 68px;
    height: 68px;
  }
  .details-hero {
    gap: 16px;
  }
  .menu-items {
    min-width: 200px;
  }
  .footer {
    font-size: 11px;
  }
}
