@import url("https://fonts.googleapis.com/css2?family=Hina+Mincho&display=swap");

@font-face {
  font-family: "Oradano GSRR";
  src: url("/font/OradanoGSRR.ttf?v=2") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

/*ホーム画面だけHina Minchoに変更*/
.home-page {
  --font-ja: "Hina Mincho", "Yu Mincho", "Hiragino Mincho ProN", serif;
  --font-en: "Hina Mincho", Georgia, "Times New Roman", serif;
  --font-special: "Hina Mincho", "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-family: "Hina Mincho", "Yu Mincho", "Hiragino Mincho ProN", serif;
  transition: background-color 0.25s ease, color 0.25s ease;
}

/*lightモードの色*/
html[data-theme="light"] .home-page {
  --bg: #f0f0f0;
  --text: #232125;
  --text2: #272627;
}

/*darkモードの色*/
html[data-theme="dark"] .home-page {
  --bg: #0f0f0f;
  --text: #e4ded8;
  --text2: #aaa19a;
  color-scheme: dark;
}



.theme-toggle {
  position: fixed;
  right: 18px;/*ボタンの場所右*/
  bottom: 76px;/*ボタンの場所↓*/
  z-index: 110;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 92px;
  min-height: 38px;
  padding: 7px 13px;
  color: #201d1f;
  background: rgba(240, 240, 240, 0.94);
  border: 0;
  border-radius: 999px;
  box-shadow: none;/*0 4px 18px rgba(0, 0, 12, 0.24)*/
  font-family: Consolas, "Courier New", monospace;
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.theme-toggle:hover {
  transform: translateY(-2px);
}

.theme-toggle:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

html[data-theme="dark"] .theme-toggle {
  color: #f0f0f0;
  background: rgba(15, 15, 15, 0.94);
}

.theme-toggle-icon {
  display: block;
  width: 40px;
  height: 40px;
  object-fit: contain;
}

/* 強調する見出しだけ個性のあるOradanoへ戻す */
.home-page .main-content h1,
.home-page .main-content h2 {
  font-family: "Oradano GSRR", "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-weight: 400;
}


/* タイプライターテキスト */
.typewriter-text {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
  margin-bottom: 20px;
}

.text-content {
  display: inline-block;
}

/* 高速タイピング */
.speed-cursor.fast {
  animation: fastBlink 50.3s infinite;
}

/* 削除カーソル */
.delete-cursor {
  display: inline-block;
  width: 2px;
  height: 2rem;
  background-color: #dc3545;
  margin-left: 2px;
  animation: deleteBlink 0.6s infinite;
}

@keyframes deleteBlink {
  0%, 50% {
    opacity: 1;
    background-color: #dc3545;
  }
  51%, 100% {
    opacity: 0.3;
    background-color: #ff6b6b;
  }
}

/*削除中のアニメーション*/
.delete-cursor.deleting {
  animation: deleteAnimation 0.3s infinite;
}

@keyframes deleteAnimation {
  0%, 50% {
    opacity: 1;
    transform: scaleX(1);
  }
  51%, 100% {
    opacity: 0.5;
    transform: scaleX(0.5);
  }
}



/*レスポンシブ_darklight場所*/
@media (max-width: 768px) {
  .theme-toggle {
    right: 12px;
    bottom: 70px;
    width: 40px;
    min-width: 40px;
    height: 40px;
    min-height: 40px;
    padding: 0;
  }

  .theme-toggle-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  #typewriter-text3 {
    font-size: clamp(16px, 5vw, 20px);
    line-height: 1.4;
    letter-spacing: 0;
    white-space: nowrap;
  }

  .typewriter-text {
    font-size: 1.5rem;
  }

  .delete-cursor {
    height: 1.25em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-page,
  .theme-toggle {
    transition: none;
  }
}

/* 異なる削除速度 */
.delete-cursor.deleting {
  animation: deleteAnimation 0.2s infinite;
}

/* カスタム削除カーソル */
.delete-cursor {
  background-color: #ff6b6b;
  box-shadow: 0 0 5px rgba(255, 107, 107, 0.5);
}

/*速度変化*/
.speed-cursor.fast {
  animation: fastBlink 60.2s infinite;
}

/*カスタム速度カーソル*/
.speed-cursor {
  background-color: #6f42c1;
  border-radius: 1px;
}

.copyright{
  text-align: center;
  collar:var(--text2);
}


