:root {
  --hisar: #203c32;
  --ivory: #f1ebdd;
  --gold: #b48b51;
  --ink: #242824;
  --red: #a63d40;
  --stone: #dcd5c5;
  --line: color-mix(in srgb, var(--hisar), transparent 68%);
  --label: .78rem;
  --serif: Georgia, "Times New Roman", serif;
  font-family: system-ui, sans-serif;
  color: var(--hisar);
  background: var(--ivory);
  line-height: 1.45;
}
* { box-sizing: border-box; }
body { margin: 0; }
h1, h2, h3, p { margin: 0; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
button { border: 1px solid var(--hisar); padding: .62rem 1rem; background: var(--hisar); color: var(--ivory); font-weight: 650; }
button:disabled { opacity: .5; cursor: default; }
button.secondary { color: var(--hisar); background: transparent; }
input, select, textarea { max-width: 100%; border: 1px solid var(--line); padding: .55rem .65rem; background: var(--ivory); color: var(--ink); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.mast { display: flex; justify-content: space-between; align-items: center; gap: 1rem; letter-spacing: .095em; font-size: var(--label); border-bottom: 1px solid currentColor; padding-bottom: .8rem; }
.kicker { text-transform: uppercase; letter-spacing: .13em; font-weight: 700; font-size: var(--label); }
.timer { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink); }
.error { color: var(--red); }
dialog { color: var(--hisar); background: var(--ivory); border: 1px solid var(--hisar); max-width: min(28rem, 90vw); padding: 1.5rem; }
dialog::backdrop { background: #203c3270; }
.live-connection { margin: .5rem 0; color: var(--red); font-size: .85rem; }
.live-connection[hidden] { display: none; }
.mechanic-question:has(figure) { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 1rem; }
.mechanic-question figure, .memory-study figure { margin: 0; }
.mechanic-question img, .memory-study img { display: block; max-width: 100%; max-height: 48vh; margin-inline: auto; object-fit: contain; }
.memory-study { text-align: center; }
.memory-study h1 { max-width: none; }
.estimate-axis { position: relative; border-top: 2px solid var(--hisar); margin: .6rem .5rem; }
.estimate-axis span { position: absolute; top: -.35rem; width: .7rem; height: .7rem; background: var(--gold); border-radius: 50%; transform: translateX(-50%); }
.estimate-axis .target { background: var(--hisar); z-index: 1; }
.estimate-results { width: 100%; border-collapse: collapse; text-align: left; }
.estimate-results :is(th, td) { padding: .12em .35em; border-bottom: 1px solid var(--line); }
.ordering-list { display: grid; gap: .4rem; padding-inline-start: 1.5rem; }
.ordering-list li { display: grid; grid-template-columns: 1fr auto auto; gap: .5rem; align-items: center; border-bottom: 1px solid var(--line); }
.ordering-list button { min-width: 44px; min-height: 44px; }

@font-face {
  font-family: "Hisar Arabic";
  src: url("../fonts/NotoSansArabic.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}

.round-results { width: 100%; border-collapse: collapse; }
.round-results :is(th, td) {
  padding: .45em .35em;
  text-align: start;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
