/* ===== Layering: 親ページTOCよりツールバー dropdown を前面に出す ===== */
:root {
  --pod-z-parent-toc: 20;
  --pod-z-parent-toolbar: 25;
  --pod-z-parent-toolbar-dropdown: 2147483647;
  --pod-mobile-parent-header-height: 50px;
}

.pod-editor-toolbar{
	text-align: left;	
}
.pod-toolbar-row > button,
.pod-toolbar-row > .pod-toolbar-split-button > button {
  height: 36px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #3c4043;
  padding: 0 8px;
  cursor: pointer;
}

.pod-toolbar-row > button:hover,
.pod-toolbar-row > .pod-toolbar-split-button > button:hover {
  background: #e8eaed;
}

.pod-toolbar-row > button.is-active,
.pod-toolbar-row > .pod-toolbar-split-button > button.is-active {
  background: #e8f0fe;
  color: #1a73e8;
}

.pod-toolbar-separator {
  display: inline-block;
  width: 1px;
  height: 24px;
  margin: 0 4px;
  background: #dadce0;
  flex: 0 0 auto;
}

.pod-color-swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-left: 4px;
  border: 1px solid #c7c7c7;
  border-radius: 2px;
  vertical-align: middle;
  background: #000;
  box-sizing: border-box;
}

#podHighlightSwatch {
  background: #fff2cc;
}


  

.pod-table-grid {
  display: grid;
  grid-template-columns: repeat(8, 22px);
  gap: 4px;
  padding: 4px 0;
}

.pod-table-grid-cell {
  box-sizing: border-box;
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  min-height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  aspect-ratio: 1 / 1;

  padding: 0 !important;
  border: 1px solid #dadce0;
  border-radius: 3px;
  background: #ffffff;
  line-height: 1;
}

.pod-toolbar-dropdown .pod-table-grid-cell {
  display: block;
  flex: none;
}

.pod-table-grid-cell.is-active {
  border-color: #1a73e8;
  background: #e8f0fe;
}

.pod-toolbar-dropdown-label {
  padding: 4px 0 8px;
  font-size: 12px;
  color: #5f6368;
}

.pod-color-grid {
  display: grid;
  grid-template-columns: repeat(10, 22px);
  gap: 4px;
  padding: 8px;
}

.pod-color-cell {
  width: 22px;
  height: 22px;
  padding: 0;
  border: 1px solid #dadce0;
  border-radius: 4px;
}

.pod-color-hex-input {
  box-sizing: border-box;
  width: calc(100% - 16px);
  height: 32px;
  margin: 4px 8px 8px;
  padding: 0 8px;
  border: 1px solid #dadce0;
  border-radius: 6px;
}

/* ===== 通常のプルダウンMENU ===== */

#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker),
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) {
  position: fixed;
  z-index: var(--pod-z-parent-toolbar-dropdown) !important;

  min-width: 160px;
  max-width: none;
  width: auto;

  max-height: 320px;
  overflow-y: auto;

  padding: 6px;
  border: 1px solid #dadce0;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 12px 32px rgba(60, 64, 67, 0.18);
}

#podToolbarDropdown,
.pod-toolbar-dropdown,
#podToolbarDropdown.pod-toolbar-dropdown-color-picker,
.pod-toolbar-dropdown.pod-toolbar-dropdown-color-picker {
  position: fixed !important;
  z-index: var(--pod-z-parent-toolbar-dropdown) !important;
}

#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item,
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item {
  display: block;
  width: 100%;
  min-height: 36px;
  box-sizing: border-box;

  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: #ffffff;
  color: #3c4043;

  text-align: left;
  font-size: 14px;
  line-height: 1.35;
  cursor: pointer;

  transition:
	background-color 0.12s ease,
	color 0.12s ease;
}

#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item:hover,
#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item:focus-visible,
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item:hover,
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item:focus-visible {
  background: #e8f0fe;
  color: #1a73e8;
  outline: none;
}

#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item.is-active,
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) .pod-toolbar-dropdown-item.is-active {
  background: #e8f0fe;
  color: #1a73e8;
}


.CC_RenderingV3gPodBodyToolBar {
  position: -webkit-sticky !important;
  position: sticky !important;
  top: 0 !important;
  z-index: var(--pod-z-parent-toolbar) !important;
  align-self: flex-start;
  isolation: isolate;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  background: #f8f9fa;
  border-bottom: 1px solid #dadce0;
  overflow: visible !important;
}

/*
 * 0091: 狭幅（768px以下）だけモバイル配置。広いタッチPCは通常のstickyを使う。
 * - 初期状態ではタイトル入力欄の下に置き、ページと一緒に上へ移動する。
 * - ツールバー上端が親ヘッドメニュー直下（50px）へ到達した後だけ、
 *   JS が fixed class を付けてその位置に固定する。
 * - 5px 上へ寄せる場合は、下の margin-top を有効にする。
 */
@media (max-width: 768px) {
  .pod-parent-toolbar-sticky-sentinel {
	display: block;
	box-sizing: border-box;
	width: 100%;
	height: 0;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	pointer-events: none;
  }

  .CC_RenderingV3gPodBodyToolBar {
	/* 固定開始前は sticky にせず、タイトル欄と一緒にスクロールさせる */
	position: relative !important;
	top: auto !important;
	/* margin-top: -5px; */
  }

  .CC_RenderingV3gPodBodyToolBar.pod-parent-toolbar-mobile-fixed {
	position: fixed !important;
	top: var(
	  --pod-mobile-toolbar-fixed-top,
	  var(--pod-mobile-parent-header-height, 50px)
	) !important;
	right: auto !important;
	left: var(--pod-mobile-toolbar-fixed-left, 0px) !important;
	width: var(--pod-mobile-toolbar-fixed-width, 100%) !important;
	max-width: none !important;
	margin-top: 0 !important;
  }
}

.pod-toolbar-scroll {
  width: 100%;
  max-width: 100%;
  min-width: 0;

  overflow-x: auto;
  overflow-y: hidden;

  -webkit-overflow-scrolling: touch;
  
  text-align: left;
}


.pod-toolbar-row {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 4px;

  min-width: max-content;
  min-height: 52px;
  padding: 8px 12px;

  white-space: nowrap;
  overflow: visible;
}

.pod-toolbar-row > * {
  flex: 0 0 auto;
}

.pod-toolbar-icon-button {
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #3c4043;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.pod-toolbar-icon-button.pod-toolbar-icon-color-button{
   width: 50px;
}

.pod-toolbar-icon-button:hover {
  background: #e8eaed;
}

.pod-toolbar-icon-button.is-active {
  background: #e8f0fe;
  color: #1a73e8;
}

.pod-toolbar-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}



.pod-toolbar-split-button {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  height: 36px;
  border-radius: 6px;
  overflow: hidden;
}

.pod-toolbar-split-button .pod-toolbar-icon-button {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.pod-toolbar-split-main {
  width: 36px;
  min-width: 36px;
}

.pod-toolbar-split-caret {
  width: 18px;
  min-width: 18px;
  height: 36px;
  padding: 0;
  border: 0;
  border-left: 1px solid rgba(60, 64, 67, 0.14);
  border-radius: 0 6px 6px 0;
  background: transparent;
  color: #5f6368;
  font-size: 9px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.pod-toolbar-split-button:hover {
  background: transparent;
}

.pod-toolbar-split-button .pod-toolbar-split-main:hover {
  background: #e8eaed;
}

.pod-toolbar-split-button .pod-toolbar-split-caret:hover {
  background: #e8eaed;
}

.pod-toolbar-split-button .pod-toolbar-icon-button.is-active {
  background: #e8f0fe;
  color: #1a73e8;
}

.pod-toolbar-split-button:has(.pod-toolbar-icon-button.is-active) {
  background: transparent;
}


/* split button は親全体を hover させない */
.pod-toolbar-split-button:hover {
  background: transparent;
}

/* 本体アイコン hover は本体だけ */
.pod-toolbar-split-button .pod-toolbar-split-main:hover {
  background: #e8eaed;
}

/* ▼ hover は ▼ だけ */
.pod-toolbar-split-button .pod-toolbar-split-caret:hover {
  background: #e8eaed;
}

/* active は本体アイコンだけに付ける */
.pod-toolbar-split-button .pod-toolbar-split-main.is-active {
  background: #e8f0fe;
  color: #1a73e8;
}

/* 親グループ全体は active 背景にしない */
.pod-toolbar-split-button:has(.pod-toolbar-split-main.is-active) {
  background: transparent;
}


/* ===== 親ページ用カラーパレット：iframe内デザイン寄せ ===== */

#podToolbarDropdown.pod-toolbar-dropdown-color-picker,
.pod-toolbar-dropdown.pod-toolbar-dropdown-color-picker {
  width: 320px;
  max-width: calc(100vw - 16px);
  min-width: 0;
  max-height: calc(100vh - 16px);
  overflow-y: auto;
  box-sizing: border-box;

  padding: 0;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  background: #ffffff;
  box-shadow:
	0 20px 25px -5px rgba(0, 0, 0, 0.12),
	0 10px 10px -5px rgba(0, 0, 0, 0.06);
}

.pod-color-picker-panel {
  box-sizing: border-box;
  width: 320px;
  max-width: calc(100vw - 16px);
  padding: 13px 13px 12px;
  background: #ffffff;
  text-align: left;
}

.pod-color-picker-section {
  margin-bottom: 14px;
  text-align: left;
}

.pod-color-picker-section-last {
  margin-bottom: 0;
}

.pod-color-picker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.pod-color-picker-title {
  font-size: 13px;
  line-height: 1.2;
  font-weight: 600;
  color: #374151;
  text-align: left;
}

.pod-color-picker-clear {
  width: auto;
  height: auto;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #6b7280;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 500;
  cursor: pointer;
}

.pod-color-picker-clear:hover,
.pod-color-picker-clear:focus-visible {
  background: transparent;
  color: #1a73e8;
  outline: none;
}

.pod-color-picker-label {
  display: block;
  width: 100%;
  margin: 0 0 8px;
  padding: 0;
  color: #6b7280;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 600;
  text-align: left;
}

.pod-color-picker-grid {
  display: grid;
  grid-template-columns: repeat(8, 24px);
  gap: 8px;
  justify-content: start;
  align-items: center;
}

.pod-color-picker-cell {
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  aspect-ratio: 1 / 1;
  padding: 0;
  border: 1px solid #cfd4dc;
  border-radius: 5px;
  background: transparent;
  cursor: pointer;
}

.pod-color-picker-cell:hover,
.pod-color-picker-cell:focus-visible {
  border-color: #1a73e8;
  outline: none;
  box-shadow: 0 0 0 1px #1a73e8;
}

.pod-color-picker-cell.is-active,
.pod-color-picker-cell[aria-selected="true"] {
  border-color: #1a73e8;
  box-shadow: 0 0 0 1px #1a73e8;
}

.pod-color-picker-hex-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px 44px;
  align-items: center;
  gap: 8px;
}

.pod-color-picker-hex-input {
  box-sizing: border-box;
  min-width: 0;
  width: 100%;
  height: 36px;
  padding: 0 12px;
  border: 1px solid #cfd4dc;
  border-radius: 7px;
  background: #ffffff;
  color: #374151;
  font-size: 14px;
  line-height: 36px;
  text-align: left;
}

.pod-color-picker-hex-input:focus {
  border-color: #1a73e8;
  outline: none;
  box-shadow: 0 0 0 1px #1a73e8;
}

.pod-color-picker-preview {
  box-sizing: border-box;
  width: 44px;
  height: 36px;
  padding: 4px;
  border: 1px solid #cfd4dc;
  border-radius: 7px;
  background: #ffffff;
}

.pod-color-picker-preview-inner {
  width: 100%;
  height: 100%;
  border: 1px solid #e5e7eb;
  border-radius: 3px;
}

.pod-color-picker-native-input {
  box-sizing: border-box;
  width: 44px;
  height: 36px;
  padding: 0;
  border: 1px solid #cfd4dc;
  border-radius: 7px;
  background: #ffffff;
  cursor: pointer;
}

.pod-color-picker-native-input::-webkit-color-swatch-wrapper {
  padding: 4px;
}

.pod-color-picker-native-input::-webkit-color-swatch {
  border: 1px solid #e5e7eb;
  border-radius: 3px;
}

.pod-color-picker-native-input::-moz-color-swatch {
  border: 1px solid #e5e7eb;
  border-radius: 3px;
}

.pod-color-picker-apply {
  grid-column: 1 / 2;
  grid-row: 2;
  justify-self: start;
  margin-top: 8px;

  width: 96px;
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  background: #1a73e8;
  color: #ffffff;
  font-size: 14px;
  line-height: 36px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
}

.pod-color-picker-apply:hover,
.pod-color-picker-apply:focus-visible {
  background: #1765cc;
  color: #ffffff;
  outline: none;
}


.pod-color-picker-panel button {
  box-sizing: border-box;
}

.pod-color-picker-cell {
  width: 24px !important;
  height: 24px !important;
  min-width: 24px !important;
  min-height: 24px !important;
  padding: 0 !important;
  border: 1px solid #cfd4dc !important;
  border-radius: 5px !important;
}

.pod-color-picker-clear {
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
}

.pod-color-picker-apply {
  width: 80px !important;
  height: 36px !important;
  min-width: 80px !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-radius: 7px !important;
  background: #1a73e8 !important;
  color: #ffffff !important;
}



/* ===== iframe内 select 風ボタン ===== */

.pod-toolbar-row > button.pod-toolbar-select-button {
  height: 36px !important;
  box-sizing: border-box;

  padding: 0 12px 0 14px !important;
  border: 1px solid #d1d5db !important;
  border-radius: 8px !important;
  background: #ffffff !important;
  color: #555555 !important;

  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  font-size: 15px;
  font-weight: 500;
  line-height: 1;

  cursor: pointer;
  white-space: nowrap;
}

.pod-toolbar-row > button.pod-toolbar-select-button:hover {
  background: #f8f9fa !important;
  border-color: #c7cdd4 !important;
}

.pod-toolbar-row > button.pod-toolbar-select-button:focus-visible {
  outline: none;
  border-color: #9aa0a6 !important;
  box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.14);
}

.pod-toolbar-select-label {
  display: inline-block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #555555;
}

.pod-toolbar-select-caret {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;

  color: #555555;
  font-size: 16px;
  line-height: 1;
  transform: translateY(1px);
}

/* 個別幅。大きすぎる場合はここだけ調整 */
#podZoomButton.pod-toolbar-select-button {
  width: max-content;
  min-width: 120px;
}

#podHeadingButton.pod-toolbar-select-button {
  width: max-content;
  min-width: 168px;
}

#podFontSizeButton.pod-toolbar-select-button {
  width: 95px;
}

#podFontFamilyButton.pod-toolbar-select-button {
  width: 180px;
}


/* ===== 0091: 広幅は入力機器に関係なくtoolbar 2 rows ===== */

.pod-toolbar-rows {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.pod-toolbar-row {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 4px;
  box-sizing: border-box;

  min-width: max-content;
  min-height: 44px;
  padding: 6px 12px;

  white-space: nowrap;
  overflow: visible;
}

.pod-toolbar-row-primary {
  display: flex;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding-bottom: 2px;
}

.pod-toolbar-row-secondary {
  width: max-content;
  min-width: max-content;
  padding-top: 2px;
}


@media (max-width: 768px) {
  .pod-toolbar-scroll {
	overflow-x: auto;
	overflow-y: hidden;
	-webkit-overflow-scrolling: touch;
  }

  .pod-toolbar-rows {
	display: inline-flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;

	width: max-content;
	min-width: max-content;
  }

  .pod-toolbar-row {
	flex: 0 0 auto;
	min-width: max-content;
	min-height: 52px;
	padding: 8px 4px;

	overflow: visible;
	white-space: nowrap;
  }

  .pod-toolbar-row-primary {
	padding-left: 12px;
	padding-right: 0;
  }

  .pod-toolbar-row-secondary {
	padding-left: 4px;
	padding-right: 12px;
  }
}


@media (max-width: 768px), (pointer: coarse) {
  #podToolbarDropdown,
  .pod-toolbar-dropdown {
	max-width: calc(100vw - 16px);
  }

  #podToolbarDropdown.pod-toolbar-dropdown-color-picker,
  .pod-toolbar-dropdown.pod-toolbar-dropdown-color-picker {
	width: min(320px, calc(100vw - 16px));
	max-width: calc(100vw - 16px);
  }
}


.pod-table-grid {
  width: max-content;
  max-width: calc(100vw - 32px);
}

#podToolbarDropdown:not(.pod-toolbar-dropdown-color-picker),
.pod-toolbar-dropdown:not(.pod-toolbar-dropdown-color-picker) {
  max-width: calc(100vw - 16px);
}




/* ===== 親ツールバー：全画面ボタン ===== */

.pod-toolbar-row-primary {
  width: 100%;
  min-width: 0;
}

.pod-toolbar-row > .pod-toolbar-flex-spacer {
  flex: 1 1 auto;
  min-width: 8px;
}

.pod-toolbar-fullscreen-button {
  flex: 0 0 auto;
  margin-left: auto;
  height: 36px;
  box-sizing: border-box;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;

  padding: 0 12px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #ffffff;
  color: #555555;

  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}

.pod-toolbar-fullscreen-button:hover {
  background: #f8f9fa;
  border-color: #c7cdd4;
}

.pod-toolbar-fullscreen-button.is-active {
  background: #e8f0fe;
  color: #1a73e8;
  border-color: #aecbfa;
}

.pod-toolbar-fullscreen-button .pod-toolbar-icon {
  width: 16px;
  height: 16px;
}

.pod-parent-fullscreen-target:fullscreen {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background: #ffffff;
}

.pod-parent-fullscreen-target:fullscreen .CC_RenderingV3gPodBodyToolBar,
.pod-parent-fullscreen-target:fullscreen #podEditorToolbar {
  display: none !important;
}

.pod-parent-fullscreen-target:fullscreen #podEditorToolbar {
  display: none !important;
}

.pod-parent-fullscreen-target:fullscreen iframe {
  width: 100% !important;
  max-width: 100% !important;
  height: 100vh !important;
  height: 100dvh !important;
  min-height: 100vh !important;
  min-height: 100dvh !important;
  display: block;
  border: 0;
}

@media (max-width: 768px) {
  #podFullscreenButton,
  .pod-toolbar-fullscreen-button {
	display: none !important;
  }

  .pod-toolbar-row > .pod-toolbar-flex-spacer {
	display: none;
  }

  .pod-toolbar-row-primary {
	width: max-content;
	min-width: max-content;
  }

  .pod-toolbar-fullscreen-label {
	display: none;
  }

  .pod-toolbar-fullscreen-button {
	width: 36px;
	min-width: 36px;
	padding: 0;
  }
}


/* ===== 親ツールバー：保存状態表示 ===== */

.pod-toolbar-save-status {
  height: 28px;
  box-sizing: border-box;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;

  padding: 0 8px;
  border-radius: 9999px;
  border: 1px solid transparent;

  font-size: 12px;
  line-height: 1;
  font-weight: 500;
  white-space: nowrap;
}

.pod-toolbar-save-status[hidden] {
  display: none !important;
}

.pod-toolbar-save-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: currentColor;
  opacity: 0.8;
  animation: podSaveStatusPulse 1.2s ease-in-out infinite;
}

.pod-toolbar-save-status-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 14px;
  height: 14px;
  font-size: 12px;
  line-height: 1;
  font-weight: 700;
}

/* ===== 親ツールバー：保存状態表示を無彩色に統一 ===== */

.pod-toolbar-save-status,
.pod-toolbar-save-status-initializing,
.pod-toolbar-save-status-processing,
.pod-toolbar-save-status-saving,
.pod-toolbar-save-status-saved,
.pod-toolbar-save-status-unsaved,
.pod-toolbar-save-status-error,
.pod-toolbar-save-status-offline,
.pod-toolbar-save-status-idle {
  color: #5f6368 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.pod-toolbar-save-status-text,
.pod-toolbar-save-status-icon {
  color: #5f6368 !important;
}

.pod-toolbar-save-status-dot {
  color: #5f6368 !important;
  background: #5f6368 !important;
}

@keyframes podSaveStatusPulse {
  0% {
	opacity: 0.35;
	transform: scale(0.85);
  }
  50% {
	opacity: 1;
	transform: scale(1);
  }
  100% {
	opacity: 0.35;
	transform: scale(0.85);
  }
}

@media (max-width: 768px) {
  .pod-toolbar-save-status {
	display: none !important;
  }
}


.pod-parent-editor-with-toc {
  display: grid;
  grid-template-columns: 14rem minmax(0, 1fr);
  align-items: start;
  width: 100%;
}

.pod-parent-editor-iframe-with-toc {
  width: 100%;
  min-width: 0;
}

.pod-parent-toc-root {
  position: sticky;
  /* 0090: 固定バーのtopをTOC側だけに加算。非固定時は従来と同じ。 */
  top: calc(var(--pod-parent-toolbar-height, 52px) + var(--pod-parent-toc-toolbar-top, 0px));
  z-index: var(--pod-z-parent-toc);
  width: 14rem;
/*  --pod-parent-toc-bottom-guard: 72px; */
  --pod-parent-toc-bottom-guard: 22px;
  height: calc(
	100vh
	- var(--pod-parent-toolbar-height, 52px)
	- var(--pod-parent-toc-toolbar-top, 0px)
	- var(--pod-parent-toc-bottom-guard)
  );
  height: calc(
	100dvh
	- var(--pod-parent-toolbar-height, 52px)
	- var(--pod-parent-toc-toolbar-top, 0px)
	- var(--pod-parent-toc-bottom-guard)
  );
  max-height: calc(
	100dvh
	- var(--pod-parent-toolbar-height, 52px)
	- var(--pod-parent-toc-toolbar-top, 0px)
	- var(--pod-parent-toc-bottom-guard)
  );  min-height: 0;
  background: #ffffff;
  border-right: 1px solid #e5e7eb;
}

.pod-parent-toc-root.is-collapsed {
  width: 3rem;
  border-right: 0;
}

.pod-parent-toc-root.is-collapsed .pod-parent-toc-panel {
  width: 3rem;
}

.pod-parent-toc-root.is-collapsed .pod-parent-toc-toggle-row {
  width: 3rem;
  min-width: 3rem;
  max-width: 3rem;
}

.pod-parent-toc-root.is-collapsed .pod-parent-toc-list {
  display: none !important;
}

.pod-parent-editor-with-toc:has(.pod-parent-toc-root.is-collapsed) {
  grid-template-columns: 3rem minmax(0, 1fr);
}

.pod-parent-toc-panel {
  height: 100%;
  min-height: 0;
  overflow: hidden;
  background: #ffffff;
  display: flex;
  flex-direction: column;
}
 
.pod-parent-toc-toggle-row {
  flex: 0 0 3.5rem;
  width: 3rem;
  min-width: 3rem;
  max-width: 3rem;
  min-height: 3.5rem;
  background: #ffffff;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 0.75rem;
  box-sizing: border-box;
  z-index: 1;
  align-self: flex-start;
}

.pod-parent-toc-list {
  flex: 1 1 auto;
  height: auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 0 0.75rem 1rem;
}

.pod-parent-toc-toggle-button {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 9999px;
  background: transparent;
  cursor: pointer;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.pod-parent-toc-toggle-button img {
  width: 32px;
  height: 32px;
  display: block;
  object-fit: contain;
  pointer-events: none;
}

.pod-parent-toc-item {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  text-align: left;
  font-size: 15px;
  line-height: 1.45;
  padding: 5px 8px;
  border-radius: 6px;
  cursor: pointer;
}

.pod-parent-toc-item:hover {
  background: #f1f3f4;
}

/* iframe 内TOCの bg-amber-300 / text-white と同じクリック表示 */
.pod-parent-toc-item.is-active,
.pod-parent-toc-item.is-active:hover,
.pod-parent-toc-item.is-active:focus-visible {
  background: #dab88b;
  color: #ffffff;
}

.pod-parent-toc-level-2 { padding-left: 16px; }
.pod-parent-toc-level-3 { padding-left: 26px; }
.pod-parent-toc-level-4 { padding-left: 36px; }
.pod-parent-toc-level-5 { padding-left: 46px; }
.pod-parent-toc-level-6 { padding-left: 56px; }

.pod-parent-fullscreen-target:fullscreen .pod-parent-toc-root {
  display: none !important;
}


/* fullscreen 中は、通常表示用の親ページTOC grid を必ず解除する */
.pod-parent-fullscreen-target:fullscreen.pod-parent-editor-with-toc,
.pod-parent-fullscreen-target:fullscreen .pod-parent-editor-with-toc {
  display: block !important;
  grid-template-columns: none !important;
}

.pod-parent-fullscreen-target:fullscreen .pod-parent-editor-iframe-with-toc,
.pod-parent-fullscreen-target:fullscreen.pod-parent-editor-with-toc > iframe {
  grid-column: 1 / -1 !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100vh !important;
  height: 100dvh !important;
  min-height: 100vh !important;
  min-height: 100dvh !important;
  display: block !important;
}


/* ===== 0090: TOCだけはレイアウト幅で非表示（ツールバーの判定は変更しない） ===== */
@media (max-width: 768px) {
  .pod-parent-toc-root {
	display: none !important;
  }

  .pod-parent-editor-with-toc {
   display: block !important;
	grid-template-columns: none !important;
  }

  .pod-parent-editor-with-toc:has(.pod-parent-toc-root.is-collapsed) {
	grid-template-columns: none !important;
  }

  .pod-parent-editor-iframe-with-toc {
	grid-column: 1 / -1 !important;
	width: 100% !important;
	max-width: 100% !important;
	min-width: 0 !important;
	display: block !important;
  }
}


/* ===== 0049: 閲覧本文の表枠線・表内チェックリスト ===== */
/*
 * 保存HTMLがborder-collapse: collapseを持つ表は、隣接セルの枠線を
 * 1本へ統合する。data属性は0049以降、style条件は既存保存データ用。
 */
#HI_RenderingV3gV3PodBody table[data-border-collapse="collapse"],
#HI_RenderingV3gV3PodBody table[style*="border-collapse: collapse"],
#HI_RenderingV3gV3PodBody table[style*="border-collapse:collapse"] {
  border-collapse: collapse !important;
  border-spacing: 0 !important;
}

/* 表セル内のTaskListだけ、通常本文用の上下余白を解除する。 */
#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"],
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li {
  display: flex !important;
  align-items: center !important;
  gap: 0.5em !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  line-height: 1.35 !important;
}

#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > label,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > label {
  display: flex !important;
  align-items: flex-start !important;
  justify-content: center !important;
  flex: 0 0 14px !important;
  width: 14px !important;
  min-width: 14px !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}

#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > label input,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > label input {
  display: block !important;
  flex: 0 0 14px !important;
  width: 14px !important;
  height: 14px !important;
  margin: 0 !important;
}

#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > div,
#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > p,
#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > div > p,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > div,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > p,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > div > p {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  min-height: 0 !important;
  line-height: 1.35 !important;
}

#HI_RenderingV3gV3PodBody table td > ul[data-type="taskList"] > li > div,
#HI_RenderingV3gV3PodBody table th > ul[data-type="taskList"] > li > div {
  flex: 1 1 auto !important;
  min-width: 0 !important;
}

/* ===== 0050: 一般HTML表の最低100%幅を閲覧画面でも維持 ===== */
/*
 * ChatGPT / Claudeなど、コピー元に固定幅・列幅がない表だけが対象。
 * 内容が本文幅より短ければ100%、長ければmax-contentまで広がり、
 * 既存のtableWrapperで横スクロールする。
 */
#HI_RenderingV3gV3PodBody table[data-table-width-mode="full"]:not([data-preserve-table-width="true"]) {
  width: max-content !important;
  min-width: 100% !important;
  max-width: none !important;
  table-layout: auto !important;
}

/* 0097: 保存済みのfull+固定幅の同居にも、固定幅の優先順位を適用する。 */
#HI_RenderingV3gV3PodBody table[data-preserve-table-width="true"] {
  width: var(--table-width, max-content) !important;
  min-width: var(--table-min-width, 0px) !important;
  max-width: none !important;
  table-layout: var(--table-layout-mode, fixed) !important;
}

/* 0097: 元からあるセル内空白の部分だけを保持。通常の長文折り返しは変更しない。 */
#HI_RenderingV3gV3PodBody table span[data-pod-cell-whitespace="source"],
#HI_RenderingV3gV3PodBody table span[data-pod-cell-whitespace="source"] * {
  white-space: pre-wrap !important;
}
