/* AI度チェッカー（common.css の上に重ねる。色は変数から作る） */
:root {
    --aido-ai: 244, 81, 30;
    --aido-human: 56, 132, 230;
    --aido-card-bg: #fff;
    --aido-border: #e3e6ec;
    --aido-text-sub: #5b6270;
}
.aido { box-sizing: border-box; width: 100%; max-width: 920px; margin: 0 auto; }
.aido *, .aido *::before, .aido *::after { box-sizing: border-box; }

.aido-hero { text-align: center; padding: .5rem 0 1rem; }
.aido-lead { font-size: 1.15rem; line-height: 1.8; margin: 0 0 .3rem; }
.aido-sub { color: var(--aido-text-sub); font-size: .92rem; margin: 0; }

.aido-card { background: var(--aido-card-bg); border: 1px solid var(--aido-border); border-radius: 12px; padding: 1.2rem 1.3rem; margin: 0 0 1.2rem; box-shadow: 0 1px 3px rgba(0,0,0,.04); }
.aido-label { display: block; font-weight: bold; margin-bottom: .4rem; }
.aido-textarea { width: 100%; min-height: 260px; resize: vertical; padding: .8rem .9rem; font-size: 1rem; line-height: 1.8; border: 1px solid var(--aido-border); border-radius: 8px; font-family: inherit; background: #fbfcfd; }
.aido-textarea:focus { outline: 2px solid rgba(var(--capital-color-r), var(--capital-color-g), var(--capital-color-b), .45); border-color: transparent; background: #fff; }
.aido-input-bar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .5rem; margin: .5rem 0 1rem; font-size: .88rem; color: var(--aido-text-sub); }
.aido-over { color: rgb(var(--aido-ai)); font-weight: bold; }
.aido-input-actions { display: flex; gap: .5rem; }
.aido-btn-sub { border: 1px solid var(--aido-border); background: #fff; border-radius: 999px; padding: .35rem .9rem; font-size: .85rem; cursor: pointer; color: inherit; }
.aido-btn-sub:hover { border-color: var(--capital-color); color: var(--capital-color); }

.aido-llm-box { background: #f6f8fb; border-radius: 8px; padding: .8rem 1rem; margin-bottom: 1rem; }
.aido-switch { display: inline-flex; align-items: center; gap: .6rem; cursor: pointer; font-weight: bold; }
.aido-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.aido-switch-track { position: relative; width: 42px; height: 24px; border-radius: 12px; background: #c9ced8; transition: background .2s; flex-shrink: 0; }
.aido-switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.aido-switch input:checked + .aido-switch-track { background: var(--capital-color); }
.aido-switch input:checked + .aido-switch-track::after { transform: translateX(18px); }
.aido-switch input:focus-visible + .aido-switch-track { outline: 2px solid var(--capital-color); outline-offset: 2px; }
.aido-llm-note { font-size: .82rem; color: var(--aido-text-sub); margin: .5rem 0 0; line-height: 1.7; }
.aido-progress { margin-top: .6rem; }
.aido-progress-bar { height: 8px; background: #dfe3ea; border-radius: 4px; overflow: hidden; }
.aido-progress-bar span { display: block; height: 100%; width: 0; background: var(--capital-color); transition: width .3s; }
.aido-progress-text { font-size: .8rem; color: var(--aido-text-sub); margin: .3rem 0 0; }

.aido-run { display: block; width: 100%; padding: .95rem 1rem; font-size: 1.1rem; font-weight: bold; color: #fff; background: var(--capital-color); border: none; border-radius: 10px; cursor: pointer; transition: filter .15s, transform .05s; }
.aido-run:hover { filter: brightness(1.08); }
.aido-run:active { transform: translateY(1px); }
.aido-run:disabled { opacity: .65; cursor: wait; }
.aido-privacy { font-size: .82rem; color: var(--aido-text-sub); margin: .7rem 0 0; text-align: center; }
.aido-lock { display: inline-block; width: .8em; height: .65em; border: 2px solid currentColor; border-radius: 2px; margin-right: .4em; position: relative; vertical-align: -1px; }
.aido-lock::before { content: ""; position: absolute; left: 50%; top: -.55em; width: .5em; height: .5em; margin-left: -.3em; border: 2px solid currentColor; border-bottom: none; border-radius: .3em .3em 0 0; }
.aido-error { color: rgb(var(--aido-ai)); font-size: .9rem; margin: .7rem 0 0; }

/* スコア */
.aido-score-card { display: flex; gap: 1.5rem; align-items: center; }
.aido-gauge { --p: 0; --c: var(--capital-color); flex-shrink: 0; width: 170px; height: 170px; border-radius: 50%; background: conic-gradient(var(--c) calc(var(--p) * 1%), #e8ebf0 0); display: grid; place-items: center; transition: background .4s; }
.aido-gauge.v-high { --c: rgb(var(--aido-ai)); }
.aido-gauge.v-mid { --c: rgb(250, 140, 30); }
.aido-gauge.v-low { --c: rgb(240, 190, 40); }
.aido-gauge.v-none { --c: rgb(var(--aido-human)); }
.aido-gauge-inner { width: 132px; height: 132px; border-radius: 50%; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.aido-gauge-label { font-size: .85rem; color: var(--aido-text-sub); }
.aido-gauge-value { font-size: 2.6rem; font-weight: bold; line-height: 1.1; }
.aido-gauge-value small { font-size: 1.1rem; margin-left: 2px; }
.aido-verdict { flex: 1; min-width: 0; }
.aido-verdict-title { font-size: 1.4rem; font-weight: bold; margin: 0 0 .3rem; }
.aido-verdict-title.v-high { color: rgb(var(--aido-ai)); }
.aido-verdict-title.v-mid { color: rgb(220, 115, 10); }
.aido-verdict-title.v-low { color: rgb(170, 130, 0); }
.aido-verdict-title.v-none { color: rgb(var(--aido-human)); }
.aido-verdict-text { margin: 0 0 .6rem; }
.aido-summary { list-style: none; padding: 0; margin: 0 0 .4rem; display: flex; flex-wrap: wrap; gap: .3rem .9rem; font-size: .9rem; }
.aido-mode { font-size: .8rem; color: var(--aido-text-sub); margin: 0; }

.aido-section-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .5rem; }
.aido-h2 { font-size: 1.15rem; margin: 0 0 .5rem; padding: 0; border: none; }
.aido-h2::before, .aido-h2::after { display: none; }
.aido-hint { font-size: .82rem; color: var(--aido-text-sub); margin: 0 0 .8rem; line-height: 1.7; }
.aido-legend { display: flex; align-items: center; gap: .4rem; font-size: .78rem; color: var(--aido-text-sub); }
.aido-legend-item { display: inline-flex; align-items: center; gap: .3rem; }
.aido-sw { display: inline-block; width: 14px; height: 14px; border-radius: 3px; }
.aido-sw-human { background: rgba(var(--aido-human), .3); }
.aido-legend-scale i { display: inline-block; width: 90px; height: 10px; border-radius: 5px; background: linear-gradient(90deg, rgba(var(--aido-ai), .05), rgba(var(--aido-ai), .58)); vertical-align: middle; }
.aido-u-ai { text-decoration: underline wavy rgb(var(--aido-ai)); text-underline-offset: 3px; }
.aido-u-human { text-decoration: underline dotted rgb(var(--aido-human)); text-decoration-thickness: 2px; text-underline-offset: 3px; }

/* ヒートマップ */
.aido-heatmap { white-space: pre-wrap; word-break: break-word; line-height: 2.1; font-size: 1rem; padding: .9rem 1rem; border: 1px solid var(--aido-border); border-radius: 8px; background: #fff; max-height: 70vh; overflow-y: auto; }
.aido-sent { border-radius: 3px; padding: .12em 0; cursor: pointer; transition: box-shadow .15s; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.aido-sent:hover, .aido-sent:focus { box-shadow: 0 0 0 2px rgba(var(--capital-color-r), var(--capital-color-g), var(--capital-color-b), .55); outline: none; }
.aido-sent.is-active { box-shadow: 0 0 0 2px var(--capital-color); }
.aido-hit-ai { background: none; color: inherit; text-decoration: underline wavy rgb(var(--aido-ai)); text-decoration-thickness: 1.5px; text-underline-offset: 4px; font-weight: bold; }
.aido-hit-human { background: none; color: inherit; text-decoration: underline dotted rgb(var(--aido-human)); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.aido-detail { margin-top: .8rem; border: 1px solid var(--aido-border); border-left: 4px solid var(--capital-color); border-radius: 8px; padding: .8rem 1rem; background: #fafbfd; }
.aido-detail-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .4rem; }
.aido-detail-level { font-weight: bold; }
.aido-detail-close { border: none; background: none; color: var(--aido-text-sub); cursor: pointer; font-size: .85rem; text-decoration: underline; }
.aido-detail-sent { margin: 0 0 .6rem; line-height: 1.8; }
.aido-detail-none { font-size: .85rem; color: var(--aido-text-sub); margin: 0; }

/* 表現の一覧 */
.aido-badge { display: inline-block; min-width: 1.6em; padding: .05em .5em; border-radius: 999px; background: rgb(var(--aido-ai)); color: #fff; font-size: .8rem; text-align: center; vertical-align: 2px; }
.aido-badge-human { background: rgb(var(--aido-human)); }
.aido-phrases { list-style: none; padding: 0; margin: 0; }
.aido-phrase { border-top: 1px solid var(--aido-border); padding: .7rem 0; }
.aido-phrase:first-child { border-top: none; padding-top: .2rem; }
.aido-phrase-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .7rem; }
.aido-phrase-label { font-weight: bold; }
.aido-phrase-count { font-size: .82rem; color: var(--aido-text-sub); }
.aido-phrase-ratio { font-size: .78rem; color: rgb(var(--aido-ai)); background: rgba(var(--aido-ai), .09); border-radius: 4px; padding: .05em .45em; }
.aido-phrase.is-human .aido-phrase-ratio { color: rgb(var(--aido-human)); background: rgba(var(--aido-human), .1); }
.aido-phrase-reason, .aido-phrase-fix { margin: .25rem 0 0; font-size: .88rem; line-height: 1.7; }
.aido-phrase-fix { color: var(--aido-text-sub); }
.aido-empty { font-size: .9rem; color: var(--aido-text-sub); margin: 0; }

/* 特徴 */
.aido-metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .8rem; }
.aido-metric { border: 1px solid var(--aido-border); border-radius: 8px; padding: .7rem .8rem; }
.aido-metric-name { font-size: .82rem; color: var(--aido-text-sub); margin: 0; }
.aido-metric-value { font-size: 1.35rem; font-weight: bold; margin: .1rem 0; }
.aido-metric-ref { font-size: .78rem; margin: 0; }
.aido-metric-note { font-size: .76rem; color: var(--aido-text-sub); margin: .3rem 0 0; line-height: 1.6; }
.aido-caution { font-size: .82rem; color: var(--aido-text-sub); line-height: 1.8; background: #fff8e6; border: 1px solid #f3e0a8; border-radius: 8px; padding: .8rem 1rem; }

/* 説明・FAQ */
.aido-faq { margin: 0 0 1rem; }
.aido-faq dt { font-weight: bold; margin-top: .9rem; }
.aido-faq dd { margin: .25rem 0 0; line-height: 1.8; font-size: .94rem; }

/* 検知の仕組みページ */
.aido-doc h2 { font-size: 1.25rem; margin: 2rem 0 .7rem; }
.aido-doc h3 { font-size: 1.05rem; margin: 1.4rem 0 .5rem; }
.aido-doc p, .aido-doc li { line-height: 1.9; }
.aido-table-wrap { overflow-x: auto; margin: .6rem 0 1rem; }
.aido-table { border-collapse: collapse; width: 100%; font-size: .88rem; min-width: 520px; }
.aido-table th, .aido-table td { border: 1px solid var(--aido-border); padding: .45rem .6rem; text-align: left; vertical-align: top; }
.aido-table th { background: #f4f6f9; white-space: nowrap; }
.aido-table td.num { text-align: right; white-space: nowrap; }
.aido-flow { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .8rem; margin: .8rem 0; }
.aido-flow > div { border: 1px solid var(--aido-border); border-radius: 10px; padding: .8rem 1rem; background: #fff; }
.aido-flow h3 { margin: 0 0 .3rem; font-size: 1rem; }
.aido-flow p { margin: 0; font-size: .88rem; line-height: 1.7; }
.aido-note { font-size: .85rem; color: var(--aido-text-sub); }

@media screen and (max-width: 600px) {
    .aido-card { padding: 1rem; }
    .aido-score-card { flex-direction: column; text-align: center; }
    .aido-summary { justify-content: center; }
    .aido-lead { font-size: 1.02rem; }
    .aido-textarea { min-height: 220px; }
}

/* メインカラーが濃い青のため、メインカラーで塗る部品の文字は白にする（本文の色 --capital-text-color は暗いまま） */
.menu-item.active > .menu-link, .table-tile th, .txt { color: #fff; }

