/* Daily Tester frontend styles */
/* テキスト色はテーマ CSS の影響（テーマによっては body color: #fff）を遮断するため、
   コンテナと操作要素すべてに明示色を指定する。 */
.dt-block { max-width: 720px; margin: 1em auto; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #1a1a1a; }
.dt-card { background: #fff; border: 1px solid #e0e0e0; border-radius: 8px; padding: 24px;
  color: #1a1a1a; }
.dt-card h1, .dt-card h2, .dt-card h3, .dt-card p, .dt-card label { color: #1a1a1a; }
.dt-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1em; }
.dt-header h2 { margin: 0; font-size: 1.2em; }
.dt-sub { margin: 0; color: #666; font-size: 0.9em; }
.dt-progress { color: #555; font-size: 0.95em; }

.dt-field { display: block; margin: 0.8em 0; }
.dt-field span { display: block; font-size: 0.9em; color: #555; margin-bottom: 0.2em; }
.dt-field input,
.dt-field select { width: 100%; padding: 8px; border: 1px solid #ccc; border-radius: 4px; font-size: 1em;
  color: #1a1a1a; background: #fff; }

.dt-btn { background: #f5f5f5; border: 1px solid #ccc; padding: 8px 16px; border-radius: 4px; cursor: pointer; font-size: 0.95em;
  color: #1a1a1a; }
.dt-btn:hover:not(:disabled) { background: #ebebeb; }
.dt-btn-primary { background: #2563eb; color: #fff; border-color: #2563eb; }
.dt-btn-primary:hover:not(:disabled) { background: #1d4ed8; }
.dt-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.dt-error { color: #b91c1c; background: #fef2f2; padding: 8px 12px; border-radius: 4px; }

.dt-quiz-notice { background: #fffbeb; border: 1px solid #fcd34d; padding: 16px; border-radius: 6px; }

.dt-prompt { font-size: 1.05em; line-height: 1.6; margin: 0 0 1em; }

.dt-options { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.dt-option { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  background: #fff; border: 1px solid #ccc; border-radius: 4px; padding: 10px 12px; cursor: pointer; font-size: 1em;
  color: #1a1a1a !important; }
.dt-option:hover:not(:disabled) { background: #f3f4f6; color: #1a1a1a !important; }
.dt-option.active { background: #dbeafe; border-color: #2563eb; color: #1a1a1a !important; }
.dt-option-no { color: #555; font-weight: bold; min-width: 1.2em; }

.dt-sentence { font-size: 1.05em; line-height: 1.8; color: #1a1a1a; }
.dt-underline { background: none; border: none; border-bottom: 2px solid #444; padding: 0 2px; cursor: pointer; font: inherit;
  color: #1a1a1a; }
.dt-underline.active { background: #fde68a; border-bottom-color: #b45309; color: #1a1a1a; }
.dt-underline sup { font-size: 0.75em; color: #666; margin-right: 1px; }

.dt-hint { background: #f3f4f6; padding: 6px 10px; border-left: 3px solid #6b7280; margin: 0 0 0.5em; font-size: 0.95em;
  color: #1a1a1a; }
.dt-sentence-frame { font-size: 1.05em; line-height: 1.8; color: #1a1a1a; }
.dt-arr-slot { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px; vertical-align: middle; color: #1a1a1a; }
.dt-token-pool { list-style: none; padding: 0; margin: 0.8em 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.dt-chip { background: #fff; border: 1px solid #2563eb; color: #2563eb; padding: 4px 10px; border-radius: 16px; cursor: pointer; font: inherit; }
.dt-chip:hover:not(:disabled) { background: #eff6ff; }
.dt-chip.used { opacity: 0.3; cursor: not-allowed; }
.dt-chip-placed { background: #2563eb; color: #fff; }
.dt-arr-help { color: #888; font-size: 0.85em; margin: 0.5em 0 0; }

.dt-feedback { margin: 1em 0; padding: 12px 16px; border-radius: 6px; }
.dt-feedback.ok { background: #ecfdf5; border: 1px solid #34d399; color: #065f46; }
.dt-feedback.ng { background: #fef2f2; border: 1px solid #fca5a5; color: #7f1d1d; }
.dt-feedback pre { background: #fff; padding: 6px 8px; border-radius: 4px; font-size: 0.95em; margin: 6px 0 0; white-space: pre-wrap; }

.dt-actions { margin-top: 1em; display: flex; justify-content: flex-end; }

.dt-summary { text-align: center; padding: 1em 0; }
.dt-summary h3 { font-size: 2em; margin: 0 0 0.5em; }
.dt-summary h3.pass { color: #047857; }
.dt-summary h3.fail { color: #b91c1c; }

/* 古文 共通 */
.dt-q-cls { color: #1a1a1a; }
.dt-q-cls .dt-sentence { font-size: 1.1em; line-height: 1.9; color: #1a1a1a; }
.dt-target { background: #fef3c7; padding: 0 2px; border-radius: 2px; color: #1a1a1a; }
.dt-asks { display: flex; flex-direction: column; gap: 8px; margin: 0.8em 0; color: #1a1a1a; }
.dt-ask { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; color: #1a1a1a; }
.dt-ask label { min-width: 8em; color: #555; font-size: 0.95em; }
.dt-ask input[type=text],
.dt-ask select { padding: 6px 8px; border: 1px solid #ccc; border-radius: 4px; min-width: 12em; font: inherit;
  color: #1a1a1a; background: #fff; }
.dt-checkbox { display: flex; align-items: center; gap: 6px; padding: 4px 8px; cursor: pointer; color: #1a1a1a; }
.dt-checkbox span { color: #1a1a1a; }
.dt-checkbox input[type=checkbox] { transform: scale(1.2); }

/* 英文解釈 structure_identification */
.dt-q-si { color: #1a1a1a; }
.dt-si-prompt { background: #eff6ff; border-left: 3px solid #2563eb; padding: 8px 12px; margin: 0 0 0.6em; color: #1e3a8a; font-weight: 600; }
.dt-q-si .dt-q-type-header,
.dt-q-ct4 .dt-q-type-header,
.dt-q-pt .dt-q-type-header,
.dt-q-type-header { display: inline-block !important; background: #1f2937 !important; color: #ffffff !important; padding: 4px 10px !important; border-radius: 4px !important; margin: 0 0 0.6em !important; font-size: 0.9em !important; font-weight: 600 !important; text-shadow: none !important; }
.dt-si-help { color: #555; font-size: 0.9em; margin: 0 0 0.5em; }
.dt-si-sentence { font-size: 1.1em; line-height: 2.2; padding: 8px; background: #fafafa; border-radius: 6px; color: #1a1a1a; }
.dt-si-token { display: inline-block; padding: 2px 4px; margin: 0 1px; border-radius: 3px; cursor: pointer; user-select: none; color: #1a1a1a; }
.dt-si-token:hover { background: #e5e7eb; }
.dt-si-token.selecting { background: #fde68a !important; color: #92400e !important; }
.dt-si-token.in-item { cursor: pointer; }
.dt-si-token.punctuation { color: #9ca3af; cursor: default; padding: 2px 0; margin: 0; }
.dt-si-token.punctuation:hover { background: transparent; }
.dt-si-controls { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 0.6em; }
.dt-si-status { color: #555; min-width: 12em; font-size: 0.95em; }
.dt-si-role-btn { padding: 4px 12px; border: 1px solid #ccc; background: #fff; border-radius: 4px; cursor: pointer; font-weight: bold; color: #1a1a1a; }
.dt-si-role-btn:hover:not(:disabled) { background: #f3f4f6; }
.dt-si-role-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.dt-si-role-btn[data-role=S] { border-color: #1d4ed8; color: #1d4ed8; }
.dt-si-role-btn[data-role=V] { border-color: #b91c1c; color: #b91c1c; }
.dt-si-role-btn[data-role=O] { border-color: #047857; color: #047857; }
.dt-si-role-btn[data-role=C] { border-color: #b45309; color: #b45309; }
.dt-si-role-btn[data-role=M] { border-color: #6b21a8; color: #6b21a8; }
.dt-si-overlay { font-size: 1.05em; line-height: 2; padding: 6px 8px; background: #fff; border: 1px solid #e0e0e0; border-radius: 4px; color: #1a1a1a; }
.dt-si-compare h4 { margin: 0.6em 0 0.2em; font-size: 0.95em; color: #444; }

/* 英文解釈 comprehensive_translation_4 */
.dt-q-ct4 { color: #1a1a1a; }
.dt-ct4-sentence { font-size: 1.1em; line-height: 1.6; padding: 10px 12px; background: #fafafa; border-radius: 6px; color: #1a1a1a; margin: 0 0 0.8em; }

/* 英文解釈 partial_translation */
.dt-q-pt { color: #1a1a1a; }
.dt-pt-sentence { font-size: 1.1em; line-height: 1.8; padding: 10px 12px; background: #fafafa; border-radius: 6px; color: #1a1a1a; margin: 0 0 0.6em; }
.dt-pt-target { background: #fef08a; color: #713f12; padding: 1px 2px; border-radius: 2px; font-weight: 600; }
.dt-pt-hint { color: #555; font-size: 0.9em; margin: 0 0 0.5em; }
.dt-pt-input { width: 100%; box-sizing: border-box; padding: 8px 10px; font-size: 1em; border: 1px solid #cbd5e1; border-radius: 4px; color: #1a1a1a; font-family: inherit; resize: vertical; }
.dt-pt-input:focus { outline: none; border-color: #2563eb; box-shadow: 0 0 0 2px rgba(37,99,235,0.2); }
