:root {
  color: #1c1917;
  background: #f4efe6;
  font-family: "PingFang SC", "Noto Sans CJK SC", sans-serif;
}

body {
  margin: 0;
  min-height: 100vh;
}

header, main {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
}

header {
  padding: 28px 0 8px;
}

h1 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 700;
}

header p, .hint {
  margin: 0;
  color: #57534e;
  line-height: 1.5;
}

.panel {
  margin-top: 20px;
  padding: 16px;
  background: #fffdf8;
  border: 1px solid #e7e0d4;
  border-radius: 12px;
}

.modes {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

button, textarea, input {
  font: inherit;
}

.modes button, .actions button {
  border: 1px solid #d6d3d1;
  background: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
}

.modes button.active {
  background: #1c1917;
  color: #fff;
  border-color: #1c1917;
}

label {
  display: block;
  margin: 14px 0 6px;
  font-size: 14px;
}

textarea, input[type="password"] {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d6d3d1;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
}

textarea {
  min-height: 140px;
  resize: vertical;
}

.actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.actions button {
  background: #9a3412;
  color: #fff;
  border-color: #9a3412;
}

.status {
  min-height: 1.4em;
  color: #9a3412;
}

.drawing {
  margin-top: 16px;
  overflow: auto;
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e7e0d4;
}

.drawing:empty {
  display: none;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  font-size: 14px;
}

th, td {
  text-align: left;
  padding: 8px 6px;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}

.hidden {
  display: none;
}
