* {
  box-sizing: border-box;
}
html {
  color-scheme: light;
  scroll-padding-top: 16px;
}
body {
  margin: 0;
  color: #183349;
  background: #f7f9fa;
  font:
    15px/1.65 Inter,
    Arial,
    sans-serif;
}
html[lang="ar"] body {
  font-family: Cairo, "Segoe UI", Tahoma, sans-serif;
}
a {
  color: #165177;
  text-underline-offset: 3px;
}
button,
input,
select {
  font: inherit;
}
button {
  cursor: pointer;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #152734;
  outline-offset: 3px;
}
.wrap {
  width: min(1440px, calc(100% - 48px));
  margin-inline: auto;
}
header {
  background: white;
  border-bottom: 1px solid #d8e1e7;
}
.bar,
nav,
.switch,
.heading,
.source-links,
.results {
  display: flex;
  align-items: center;
}
.bar {
  min-height: 67px;
  gap: 24px;
}
.client img {
  display: block;
  height: 38px;
  width: auto;
}
nav {
  gap: 20px;
  margin-inline-start: auto;
}
nav a,
.source-links a,
.diagram-link {
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
.switch {
  border: 1px solid #d8e1e7;
  background: #f3f6f8;
  border-radius: 24px;
  padding: 3px;
  gap: 2px;
}
.switch button {
  border: 0;
  border-radius: 24px;
  padding: 5px 13px;
  font-weight: 700;
  font-size: 12px;
  background: transparent;
  color: #153e61;
}
.switch button[aria-pressed="true"] {
  color: white;
  background: #114a76;
}
.heading {
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  margin: 34px 0 24px;
}
.eyebrow,
.pill {
  color: #215d7c;
  font-weight: 750;
  font-size: 12px;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: clamp(29px, 4vw, 44px);
  line-height: 1.4;
  color: #103855;
}
.intro,
.meaning,
.purpose {
  color: #4f6574;
}
.diagram-link {
  border-radius: 24px;
  padding: 10px 16px;
  background: #123f62;
  color: white;
  white-space: nowrap;
}
.explorer {
  display: grid;
  grid-template-columns: minmax(225px, 285px) minmax(0, 1fr);
  align-items: start;
  gap: 16px;
}
.explorer > aside,
.explorer > article {
  background: white;
  border: 1px solid #d6e1e8;
  border-radius: 17px;
}
.explorer > aside {
  padding: 16px;
  position: sticky;
  top: 12px;
}
.explorer > article {
  padding: clamp(18px, 3vw, 34px);
  scroll-margin: 12px;
}
.explorer > article:focus {
  outline: none;
}
label {
  display: block;
  font-size: 12px;
  font-weight: 750;
  margin-bottom: 4px;
}
input,
select {
  width: 100%;
  min-height: 41px;
  border: 1px solid #abbcc7;
  border-radius: 8px;
  background: white;
  color: #203c50;
  padding: 5px 9px;
  margin-bottom: 10px;
}
.results {
  justify-content: space-between;
  gap: 4px;
  font-size: 12px;
  color: #526976;
  margin-block: 3px 10px;
}
.results button,
.rel {
  border: 0;
  background: none;
  color: #124e75;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 2px;
  font-size: 12px;
}
.results button:disabled {
  opacity: 0.45;
  cursor: default;
}
.list {
  display: grid;
  gap: 3px;
  overflow: auto;
  max-height: max(210px, calc(100dvh - 295px));
  scrollbar-width: thin;
}
.entry {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 8px;
  background: white;
  text-align: start;
  padding: 7px 9px;
  color: #123b58;
  line-height: 1.45;
}
.entry:hover {
  background: #f1f5f7;
}
.entry[aria-current="true"] {
  background: #e9f1f5;
  border-color: #acd0df;
}
.entry strong,
.entry code {
  display: block;
}
.entry code {
  font-size: 11px;
  color: #516775;
  width: fit-content;
}
.pill {
  display: inline-flex;
  padding: 3px 10px;
  background: #edf5f8;
  border-radius: 20px;
}
.detail-heading {
  margin-top: 8px;
  font-size: clamp(22px, 3vw, 33px);
  line-height: 1.45;
}
.table-id {
  direction: ltr;
  display: inline-block;
  color: #4f6574;
  font-size: 13px;
}
.purpose {
  margin-top: 8px;
}
.detail-section {
  margin-top: 25px;
}
h3 {
  font-size: 18px;
  margin-bottom: 9px;
}
.rules {
  padding: 14px 16px;
  background: #fff8e8;
  border-radius: 10px;
  border-inline-start: 3px solid #eab053;
}
.field-grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  text-align: start;
}
.field-grid th,
.field-grid td {
  text-align: start;
  vertical-align: top;
  padding: 9px 8px;
  border-bottom: 1px solid #e1e7eb;
  overflow-wrap: anywhere;
}
.field-grid th {
  font-size: 12px;
  color: #475f71;
  background: #f3f6f8;
}
.field-grid th:first-child {
  width: 40%;
}
.field-grid td {
  font-size: 13px;
}
.field-grid code,
.relationship code {
  direction: ltr;
  unicode-bidi: isolate;
  word-break: break-word;
}
.field-type,
.flags {
  display: block;
  color: #526977;
  font-size: 11px;
}
.field-type {
  direction: ltr;
  width: fit-content;
}
.flags {
  margin-top: 2px;
}
.relationship {
  display: grid;
  gap: 6px;
}
.relationship button {
  border: 1px solid #d9e3e8;
  background: #fafcfd;
  color: #15466b;
  padding: 7px 10px;
  border-radius: 7px;
  text-align: start;
  font-size: 12px;
}
.source-links {
  flex-wrap: wrap;
  gap: 12px 24px;
  margin: 23px 0 38px;
}
.empty {
  padding: 16px;
  color: #596e7b;
}
.empty h2 {
  font-size: 20px;
}
@media (max-width: 740px) {
  .wrap {
    width: calc(100% - 24px);
  }
  .bar {
    gap: 8px;
    flex-wrap: wrap;
    padding: 7px 0;
  }
  .bar nav {
    gap: 9px;
    flex-wrap: wrap;
  }
  .bar nav a {
    font-size: 12px;
  }
  .switch button {
    padding: 5px 8px;
  }
  .client img {
    height: 29px;
  }
  .heading {
    display: block;
    margin: 24px 0 15px;
  }
  .diagram-link {
    display: inline-flex;
    margin-top: 13px;
  }
  .explorer {
    grid-template-columns: 1fr;
  }
  .explorer > aside {
    position: static;
  }
  .list {
    max-height: 163px;
  }
  .explorer > article {
    padding: 17px 12px;
  }
  .field-grid td,
  .field-grid th {
    padding: 7px 4px;
  }
  .field-grid th:first-child {
    width: 42%;
  }
}
@media print {
  body {
    background: #fff;
  }
  .bar nav,
  .switch,
  .source-links,
  .explorer > aside,
  .diagram-link {
    display: none;
  }
  .explorer {
    display: block;
  }
  .intro {
    max-width: 75ch;
  }
  .explorer > article {
    border: 0;
    padding: 0;
  }
  tr {
    break-inside: avoid;
  }
  .wrap {
    width: 100%;
  }
}

.action-icon {
  width: 1.15em;
  height: 1.15em;
  vertical-align: -0.18em;
  margin-inline-end: 0.45em;
  flex: none;
}
.intro,
.purpose,
.detail-section.rules p {
  max-inline-size: 82ch;
}
@media (max-width: 740px) {
  .diagram-link {
    white-space: normal;
    align-items: center;
  }
}
