:root {
  font-family: system-ui, sans-serif;
  color: #eae5d8;
  background: #101c24;
  font-size: 16px;
  color-scheme: dark;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
header,
main,
footer {
  max-width: 1240px;
  margin: auto;
  padding: 24px;
}
header {
  padding-top: 48px;
  border-bottom: 1px solid #50616c;
}
h1 {
  font-family: Georgia, serif;
  font-size: clamp(2.2rem, 5vw, 4rem);
  margin: 8px 0;
}
h2 {
  font-family: Georgia, serif;
  margin-top: 0;
}
p {
  line-height: 1.5;
}
.eyebrow {
  color: #d3b778;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
}
.muted,
footer {
  color: #b4c2ca;
  overflow-wrap: anywhere;
}
section {
  background: #192a35;
  border: 1px solid #3b505e;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
}
form {
  display: grid;
  gap: 14px;
}
label {
  display: grid;
  gap: 6px;
  font-weight: 550;
}
input,
select,
button {
  font: inherit;
  padding: 11px 12px;
  border-radius: 6px;
  border: 1px solid #71818a;
  min-width: 0;
  max-width: 100%;
}
input,
select {
  background: #101e28;
  color: #fff;
}
button {
  background: #d3b778;
  color: #18232a;
  font-weight: 650;
  cursor: pointer;
  width: fit-content;
}
.secondary {
  background: transparent;
  color: #ead59f;
  margin: 12px 0;
}
button:hover {
  filter: brightness(1.15);
}
button:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid #f2d383;
  outline-offset: 3px;
}
.columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.card-row {
  display: grid;
  grid-template-columns: 1fr 72px;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
  font-size: 0.92rem;
}
.card-row input {
  width: 72px;
}
.catalogue {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(210px, 100%), 1fr));
  gap: 12px;
}
.catalogue article {
  border: 1px solid #526a77;
  padding: 8px;
  border-radius: 7px;
  overflow-wrap: anywhere;
}
.catalogue h3 {
  margin-top: 0;
}
.badge {
  font-size: 0.8rem;
  color: #a9e4bb;
}
.unsupported {
  color: #e3b5a1;
}
#status {
  white-space: pre-wrap;
  min-height: 24px;
  color: #f3d089;
}
summary {
  cursor: pointer;
  margin: 12px 0;
}
details form {
  padding: 12px 0;
}
#auth {
  max-width: 540px;
}
#restriction-visible {
  color: #d3b778;
  overflow-wrap: anywhere;
}
[hidden] {
  display: none !important;
}
@media (max-width: 760px) {
  .columns {
    grid-template-columns: 1fr;
  }
  header,
  main,
  footer {
    padding: 18px;
  }
  section {
    padding: 18px;
  }
  h1 {
    font-size: 2.5rem;
  }
  .card-row {
    font-size: 0.85rem;
  }
  button {
    min-height: 44px;
  }
}
.duel-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.duel-card {
  padding: 12px;
  border: 1px solid #789188;
  background: #102a2c;
  border-radius: 6px;
  overflow-wrap: anywhere;
}
.duel-card h4 {
  margin: 0 0 8px;
  color: #ead59f;
}
.duel-card p {
  font-size: 0.85rem;
}
.duel-card button {
  font-size: 0.8rem;
  margin: 4px 0;
  width: 100%;
}
.duel-controls {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 16px 0;
}
.duel-field {
  padding: 16px 0;
  border-top: 1px solid #526a77;
}
#duel-invite,
#game-pins,
#duel-pins,
#invitation-pins {
  overflow-wrap: anywhere;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
#duel-room > label {
  margin: 12px 0;
}

.catalogue img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}
.catalogue img[hidden] {
  display: none;
}
.browse-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 12px 0;
}
.browse-controls [aria-pressed="true"] {
  outline: 3px solid #f3d089;
}
