/* ===================================
   TIMEマニュアル カスタムデザイン
   =================================== */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@300;400;500;700&display=swap');

/* ===== 基本フォント ===== */
:root {
  --md-text-font: "Noto Sans JP", sans-serif;
  --md-code-font: "Roboto Mono", monospace;
}

body {
  font-family: "Noto Sans JP", sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ===== 本文エリア ===== */
.md-content__inner {
  line-height: 1.9;
  font-size: 0.92rem;
  max-width: 860px;
}

/* ===== 段落・リスト間のスペースを整える ===== */
.md-content p {
  margin-bottom: 0.9rem;
  margin-top: 0;
}

/* リストを読みやすく */
.md-content ul,
.md-content ol {
  padding-left: 1.4rem;
  margin: 0.5rem 0 1rem 0;
}

.md-content li {
  margin-bottom: 0.35rem;
  line-height: 1.85;
}

/* ネストされたリスト */
.md-content li > ul,
.md-content li > ol {
  margin: 0.25rem 0 0.25rem 0;
}

/* ===== 見出し ===== */
.md-content h1 {
  font-size: 1.7rem;
  font-weight: 700;
  border-bottom: 3px solid var(--md-primary-fg-color);
  padding-bottom: 0.5rem;
  margin-top: 0;
  margin-bottom: 1.5rem;
  letter-spacing: 0.02em;
}

.md-content h2 {
  font-size: 1.2rem;
  font-weight: 700;
  border-left: 5px solid var(--md-primary-fg-color);
  background: linear-gradient(to right, rgba(63,81,181,0.07), transparent);
  padding: 0.45rem 0.8rem;
  border-radius: 0 6px 6px 0;
  margin-top: 2rem;
  margin-bottom: 0.8rem;
}

.md-content h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--md-primary-fg-color);
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px dashed rgba(63,81,181,0.3);
}

.md-content h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-top: 1.2rem;
  margin-bottom: 0.4rem;
}

/* ===== 画像 ===== */
.md-content img {
  border-radius: 8px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.13);
  max-width: 100%;
  display: block;
  margin: 1.2rem auto;
}

/* ===== テーブル ===== */
.md-content table {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 6px rgba(0,0,0,0.09);
  font-size: 0.88rem;
  width: auto;
  min-width: 320px;
  margin: 1rem 0;
  border-collapse: collapse;
}

.md-content thead tr {
  background-color: var(--md-primary-fg-color);
  color: white;
}

.md-content thead th {
  padding: 0.6rem 1rem;
  font-weight: 700;
  white-space: nowrap;
}

.md-content tbody tr:nth-child(even) {
  background-color: rgba(63,81,181,0.04);
}

.md-content tbody tr:hover {
  background-color: rgba(63,81,181,0.08);
}

.md-content td {
  padding: 0.55rem 1rem;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  line-height: 1.6;
  word-break: break-all;
}

/* ===== 水平線 ===== */
.md-content hr {
  border: none;
  border-top: 1px solid rgba(63,81,181,0.15);
  margin: 1.5rem 0;
}

/* ===== admonitionボックス ===== */
.md-typeset .admonition,
.md-typeset details {
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.07);
  font-size: 0.9rem;
  margin: 1rem 0;
}

.md-typeset .admonition p,
.md-typeset details p {
  margin-bottom: 0.4rem;
}

/* ===== コードブロック ===== */
.md-content pre {
  border-radius: 8px;
  font-size: 0.85rem;
  margin: 0.8rem 0;
}

.md-content code {
  font-size: 0.85em;
  padding: 0.15em 0.4em;
  border-radius: 3px;
}

/* ===== 強調 ===== */
.md-content strong {
  font-weight: 700;
  color: #1a237e;
}

[data-md-color-scheme="slate"] .md-content strong {
  color: #90caf9;
}

/* ===== ヘッダー ===== */
.md-header {
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.md-header__title {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.05em;
}

/* ===== サイドバー幅 ===== */
:root {
  --md-sidebar-width: 24rem;
}

/* ===== サイドバー ===== */
.md-nav__link {
  font-size: 0.86rem;
  line-height: 1.55;
  padding: 0.25rem 0.2rem;
  border-radius: 4px;
  transition: background-color 0.15s;
}

/* サイドバー自体を左端に寄せる */
.md-sidebar--primary {
  left: 0;
  padding-left: 1.6rem;
}

.md-sidebar--primary .md-sidebar__scrollwrap {
  margin-left: 0;
}

.md-grid {
  margin-left: 0;
  max-width: 100%;
}

.md-nav__link:hover {
  background-color: rgba(63,81,181,0.07);
}

.md-nav__link--active {
  font-weight: 700 !important;
  color: var(--md-primary-fg-color) !important;
}

/* ===== ライトモード背景 ===== */
[data-md-color-scheme="default"] .md-main {
  background: #f8f9fc;
}

[data-md-color-scheme="default"] .md-sidebar {
  background: #ffffff;
}
