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

html,
body {
  height: 100%;
}

body {
  background-color: #17171d;
  color: #f0f0f0;
  font-family: system-ui, -apple-system, sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.5rem 5rem;
}

.emoji {
  font-size: 5rem;
  line-height: 1;
  margin-bottom: 1.5rem;
}

h1 {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.content p {
  color: #a0a0a8;
  font-size: 1.125rem;
  max-width: 20rem;
  line-height: 1.6;
}

.content a {
  color: #9147ff;
  text-decoration: none;
}

.content a:hover {
  text-decoration: underline;
}

.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.25rem;
}

.footer-link {
  background: none;
  border: none;
  color: #a0a0a8;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.875rem;
  opacity: 0.7;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-link:hover:not(:disabled) {
  color: #f0f0f0;
  opacity: 1;
}

.footer-link:disabled {
  cursor: not-allowed;
  opacity: 0.4;
  text-decoration: none;
}

.footer-separator {
  color: #a0a0a8;
  opacity: 0.4;
  font-size: 0.875rem;
}

.dialog {
  border: none;
  border-radius: 0.75rem;
  padding: 0;
  width: min(42rem, calc(100vw - 2rem));
  max-height: min(80vh, 40rem);
  margin: auto;
  background: #1e1e26;
  color: #f0f0f0;
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.5);
  position: fixed;
  inset: 0;
  height: fit-content;
}

.dialog::backdrop {
  background: rgba(0, 0, 0, 0.6);
}

.dialog-inner {
  display: flex;
  flex-direction: column;
  max-height: min(80vh, 40rem);
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.dialog-title {
  font-size: 1.25rem;
  font-weight: 600;
}

.dialog-close {
  background: none;
  border: none;
  color: #a0a0a8;
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.25rem;
}

.dialog-close:hover {
  color: #f0f0f0;
}

.dialog-content {
  overflow-y: auto;
  padding: 1.5rem;
}

.markdown h2 {
  font-size: 1.25rem;
  margin: 1.5rem 0 0.75rem;
}

.markdown h2:first-child {
  margin-top: 0;
}

.markdown h3 {
  font-size: 1.1rem;
  margin: 1.25rem 0 0.5rem;
}

.markdown p {
  color: #a0a0a8;
  line-height: 1.7;
  margin-bottom: 0.75rem;
}

.markdown strong {
  color: #f0f0f0;
}

.markdown a {
  color: #9147ff;
}

.markdown a:hover {
  text-decoration: underline;
}

.markdown blockquote {
  border-left: 3px solid #9147ff;
  color: #a0a0a8;
  margin: 1rem 0;
  padding-left: 1rem;
}

.markdown hr {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 1.5rem 0;
}

.markdown ul,
.markdown ol {
  color: #a0a0a8;
  line-height: 1.7;
  margin: 0.75rem 0;
  padding-left: 1.5rem;
}

.markdown li {
  margin-bottom: 0.35rem;
}
