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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  padding: 16px;
  min-height: 100vh;
}

h1 {
  margin-bottom: 30px;
  font-size: 2rem;
  font-weight: 600;
  color: #333;
}

.github-link {
  color: #666;
  text-decoration: none;
  margin-left: 2px;
  display: inline-block;
  font-size: 0.8rem;
}

.github-link:hover {
  color: #666;
}

.visualizer {
  background-color: white;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: 90vw;
}

.visualizer-content {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 0;
}

#canvas {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
}

.text-display {
  position: relative;
  z-index: 1;
  white-space: nowrap;
  word-wrap: normal;
  overflow-wrap: normal;
  outline: none;
  cursor: text;
  padding: 0 60px;
  box-sizing: border-box;
  text-align: center;
  overflow-x: auto;
  overflow-y: visible;
}

.text-display:focus {
  background-color: rgba(0, 0, 0, 0.02);
}

.section {
  padding: 20px;
  margin-bottom: 20px;
}

.section h2 {
  margin-bottom: 15px;
  font-size: 1.2rem;
  color: #333;
}

.metrics-info {
  position: fixed;
  left: 0;
  bottom: 24px;
  width: 100%;
  text-align: center;
  font-size: 0.8rem;
  color: #999;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 8px;
  line-height: 2;
}

.font-name {
  font-weight: bold;
  color: #333;
  font-size: 1rem;
}

.metric-inline {
  margin: 0 8px;
  display: inline-block;
}

.metric-label {
  font-weight: normal;
  color: #999;
  margin: 0;
}

.metric-value {
  font-family: "Courier New", monospace;
  font-weight: bold;
  color: #666;
  margin: 0;
}

.metric-formula {
  font-family: "Courier New", monospace;
  font-size: 0.8rem;
  color: #333;
  margin: 0 4px;
}

.metric-equals {
  color: #333;
  margin: 0 4px;
}

.drag-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
}

.drag-message {
  background-color: white;
  padding: 32px 64px;
  border-radius: 4px;
  font-size: 1.5rem;
  font-weight: bold;
  color: #333;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
