/* Robinhood — 500 error page
   Geometry and colour sampled from the Cloudflare reference screenshot
   (1113px viewport, 983px content column). */

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: #ffffff;
  color: #404040;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
}

p { margin: 0; }

.wrapper {
  max-width: 1113px;
  margin: 0 auto;
  padding: 0 65px;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.brand { color: #4479ba; }

/* ---------- Header ---------- */

.page-header { padding-top: 28px; }

.page-title {
  margin: 0;
  font-size: 60px;
  font-weight: 300;
  line-height: 1.2;
  color: #404040;
  overflow-wrap: break-word;
}

.error-code {
  display: inline-block;
  margin-left: 7px;
  padding: 2px 10px;
  border-radius: 11px;
  background: #d9d9d9;
  color: #313131;
  font-size: 13px;
  font-weight: 400;
  line-height: 18px;
  vertical-align: 11px;
  white-space: nowrap;
}

.page-info { margin-top: 8px; }

.page-time { margin-top: 6px; }

/* ---------- Contract address ---------- */

.ca {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 8px;
  margin: 16px auto 0;
  max-width: 560px;
  font-size: 13px;
  line-height: 1.45;
  text-align: center;
  color: #636363;
}

.ca-value {
  min-width: 0;
  max-width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Courier New", monospace;
  font-size: 13px;
  color: #404040;
  overflow-wrap: anywhere;
  word-break: break-all;
}

.ca-copy {
  flex: 0 0 auto;
  padding: 2px 9px;
  border: 1px solid #d0d0d0;
  border-radius: 3px;
  background: #ffffff;
  color: #636363;
  font-family: inherit;
  font-size: 12px;
  line-height: 1.5;
  cursor: pointer;
}

.ca-copy:hover { background: #f5f5f5; }
.ca-copy:active { background: #ebebeb; }
.ca-copy:focus-visible { outline: 2px solid #4479ba; outline-offset: 1px; }
.ca-copy[hidden] { display: none; }

/* ---------- Status band ---------- */

.status-band {
  position: relative;
  margin-top: 29px;
  padding: 61px 0 0;
  height: 342px;
  background:
    linear-gradient(to bottom, rgba(0, 0, 0, 0.047), rgba(0, 0, 0, 0)) top / 100% 9px no-repeat,
    linear-gradient(to top, rgba(0, 0, 0, 0.047), rgba(0, 0, 0, 0)) bottom / 100% 12px no-repeat,
    #ebebeb;
}

/* White notch pointing at the failing column */
.status-band::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 21px solid transparent;
  border-right: 21px solid transparent;
  border-bottom: 22px solid #ffffff;
}

.status-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
}

.status-column { text-align: center; }

.status-icon {
  display: block;
  width: auto;
  height: 104px;
  margin: 0 auto;
}

.status-who {
  margin-top: 22px;
  font-size: 16px;
  line-height: 1;
  color: #404040;
}

.status-role {
  margin-top: 17px;
  font-size: 24px;
  font-weight: 400;
  line-height: 1;
  color: #999999;
}

.status-role--brand { color: #4479ba; }

.status-state {
  margin-top: 8px;
  font-size: 24px;
  line-height: 1;
}

.status-state--ok { color: #a5c956; }
.status-state--bad { color: #ae342e; }

/* ---------- What happened / What can I do ---------- */

.explain {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin: 35px 0 0;
}

.explain h2 {
  margin: 0;
  font-size: 30px;
  font-weight: 400;
  line-height: 1.2;
  color: #404040;
}

.explain p {
  margin-top: 21px;
  font-size: 17px;
  line-height: 1.5;
  color: #404040;
}

/* ---------- Footer ---------- */

.page-footer {
  margin-top: 55px;
  padding: 39px 0 40px;
  border-top: 1px solid #ebebeb;
  font-size: 14px;
  line-height: 1.4;
  text-align: center;
  color: #636363;
}

/* ---------- Medium screens ---------- */

@media (max-width: 860px) {
  .wrapper { padding: 0 32px; }
  .page-title { font-size: 44px; }
  .error-code { margin-left: 5px; vertical-align: 9px; }
  .status-band { height: auto; padding-bottom: 61px; }
}

/* ---------- Narrow screens ---------- */

@media (max-width: 700px) {
  .wrapper { padding: 0 24px; }

  .page-header { padding-top: 22px; }

  .page-title {
    font-size: 32px;
    line-height: 1.25;
  }

  .error-code {
    display: block;
    width: -moz-fit-content;
    width: fit-content;
    margin: 12px 0 0;
    vertical-align: baseline;
  }

  .page-info,
  .explain p,
  body { font-size: 16px; }

  .ca { justify-content: flex-start; text-align: left; margin-left: 0; }

  .status-band {
    margin-top: 22px;
    padding: 34px 0;
    height: auto;
  }

  .status-band::after { display: none; }

  .status-columns {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .status-icon { height: 84px; }
  .status-who { margin-top: 22px; }
  .status-role { margin-top: 15px; font-size: 21px; }
  .status-state { margin-top: 11px; font-size: 21px; }

  .explain {
    grid-template-columns: 1fr;
    gap: 26px;
    margin-top: 32px;
  }

  .explain h2 { font-size: 26px; }
  .explain p { margin-top: 14px; }

  .page-footer {
    margin-top: 36px;
    padding: 20px 0 32px;
  }
}
