﻿html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #eceef2;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  display: flex;
  flex-direction: column;
}

#toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: #ffffff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}

.group {
  display: flex;
  align-items: center;
  gap: 6px;
}

#toolbar button,
#toolbar select,
#toolbar input {
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  background: #fff;
  color: #111827;
  height: 32px;
  font-size: 13px;
}

#toolbar button {
  padding: 0 10px;
  cursor: pointer;
}

#toolbar button.active {
  background: #eef2ff;
  border-color: #4f46e5;
  color: #312e81;
}

#toolbar button[disabled] {
  cursor: not-allowed;
  opacity: 0.5;
}

#toolbar select {
  padding: 0 6px;
}

#toolbar input {
  width: 60px;
  text-align: center;
  padding: 0 6px;
}

#docTitle {
  margin-left: auto;
  min-width: 120px;
  max-width: 42vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  color: #4b5563;
}

#viewport {
  flex: 1;
  overflow: auto;
  padding: 16px;
}

#status {
  font-size: 13px;
  color: #111827;
}

#canvasWrap {
  width: fit-content;
  margin: 0 auto;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
  overflow: hidden;
}

#pageCanvas {
  display: block;
}
