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

body {
  font-family: sans-serif;
  background-color: #f5f5f5;
  display: flex;
  height: 100vh;
  align-items: center;
  justify-content: center;
}

.container {
  background: #fff;
  padding: 3rem;
  border-radius: 8px;
  width: 90%;
  max-width: 480px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  text-align: center;
}

/* ヘッダー */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.help-btn {
  background: #dbf1ff;
  border: none;
  font-size: 1rem;
  color: #0078d4;
  cursor: pointer;
  border-radius: 8px;
}

.mode-selector {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  text-align: left;
}

.mode-selector input[type="radio"] {
  transform: scale(1.2);
  margin-right: 0.3rem;
}

.mode-selector label {
  margin-right: 1.2rem;
}

.mode label {
  display: block;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  text-align: left;
}

textarea {
  width: 100%;
  height: 150px;
  margin-bottom: 1.5rem;
  padding: 0.8rem;
  font-size: 1.1rem;
  line-height: 1.4;
  border: 1px solid #ddd;
  border-radius: 4px;
  resize: vertical;
}

#number-mode input {
  width: 100%;
  margin-bottom: 1rem;
  padding: 0.8rem;
  font-size: 1.1rem;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.hidden {
  display: none;
}

.buttons {
  margin: 1.5rem 0;
}

button {
  background: #0078d4;
  color: #fff;
  border: none;
  padding: 0.8rem 1.2rem;
  margin: 0 0.5rem;
  font-size: 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}

button:hover {
  background: #005a9e;
}

.result {
  min-height: 2.5rem;
  font-size: 1.5rem;
  font-weight: bold;
  color: #333;
  margin-top: 1.5rem;
  line-height: 1.3;
  word-break: break-word;
}

/* モーダル背景 */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  align-items: center;
  justify-content: center;
}

/* モーダル本体 */
.modal-content {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  max-width: 400px;
  width: 90%;
  position: relative;
  text-align: left;
}

.modal-content h2 {
  margin-bottom: 1rem;
}

.modal-content h3 {
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}

.modal-content ol {
  padding-left: 1.2rem;
  margin-bottom: 1rem;
}

.close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 1.5rem;
  cursor: pointer;
}

.Clockbutton{
  background-color: #fff;
  border: solid 2px #2f4f4f;
  color: #2f4f4f;
  padding: 10px 30px;
  text-decoration: none;
  font-size: 1em;
}
.Clockbutton:hover {
  color: #2f4f4f;
  background-color: #b0e0e6;
}