/* AI検索対策相談（ナビ） */
.nbn { position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; font-family: inherit; }
.nbn[hidden] { display: none; }
html.nbn-open { overflow: hidden; }
.nbn-bg { position: absolute; inset: 0; background: rgba(20, 20, 20, .55); }
.nbn-panel { position: relative; width: min(460px, calc(100% - 24px)); height: min(720px, calc(100% - 40px)); background: #f6f6f3; border-radius: 18px; display: flex; flex-direction: column; overflow: hidden; box-shadow: 0 24px 60px rgba(0, 0, 0, .3); color: #141414; }
.nbn-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: #141414; color: #fff; }
.nbn-title { margin: 0; font-weight: 800; font-size: 16px; }
.nbn-sub { margin: 0; font-size: 11.5px; font-weight: 700; background: #f2c200; color: #141414; border-radius: 99px; padding: 3px 9px; }
.nbn-x { margin-left: auto; background: none; border: 0; color: #fff; font-size: 26px; line-height: 1; cursor: pointer; padding: 2px 6px; }
.nbn-log { flex: 1; overflow-y: auto; padding: 16px 14px 6px; display: flex; flex-direction: column; gap: 10px; overscroll-behavior: contain; }
.nbn-row { display: flex; align-items: flex-end; gap: 8px; animation: nbn-in .25s ease both; }
.nbn-row.is-me { justify-content: flex-end; }
.nbn-face { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; background: #fff; border: 2px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .12); }
.nbn-bubble { max-width: 82%; padding: 10px 13px; border-radius: 16px; font-size: 14px; line-height: 1.7; white-space: pre-line; overflow-wrap: anywhere; }
.is-guide .nbn-bubble { background: #fff; border-bottom-left-radius: 4px; box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.is-me .nbn-bubble { background: #06c755; color: #fff; border-bottom-right-radius: 4px; font-weight: 700; }
.nbn-bubble.is-typing { display: inline-flex; gap: 4px; padding: 14px 16px; }
.nbn-bubble.is-typing i { width: 7px; height: 7px; border-radius: 50%; background: #b5b5b0; animation: nbn-dot 1s infinite; }
.nbn-bubble.is-typing i:nth-child(2) { animation-delay: .15s; }
.nbn-bubble.is-typing i:nth-child(3) { animation-delay: .3s; }
.nbn-act { padding: 10px 14px 12px; display: grid; gap: 8px; background: #f6f6f3; max-height: 60%; overflow-y: auto; }
.nbn-opts { display: grid; gap: 8px; }
.nbn-opt { text-align: left; background: #fff; border: 2px solid #e2e2dd; border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 14.5px; font-weight: 700; color: #141414; cursor: pointer; min-height: 48px; transition: border-color .15s, background .15s; }
.nbn-opt:hover { border-color: #141414; }
.nbn-opt:focus-visible, .nbn-next:focus-visible, .nbn-skip:focus-visible, .nbn-line:focus-visible, .nbn-back:focus-visible { outline: 3px solid #f2c200; outline-offset: 2px; }
.nbn-opts.is-multi .nbn-opt { padding-left: 42px; position: relative; }
.nbn-opts.is-multi .nbn-opt::before { content: ""; position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; margin-top: -9px; border: 2px solid #c8c8c2; border-radius: 5px; background: #fff; }
.nbn-opt[aria-pressed="true"] { border-color: #141414; background: #fff8d6; }
.nbn-opts.is-multi .nbn-opt[aria-pressed="true"]::before { background: #141414 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f2c200' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 14px no-repeat; border-color: #141414; }
.nbn-next { background: #141414; color: #fff; border: 0; border-radius: 12px; padding: 12px 18px; font: inherit; font-weight: 800; font-size: 15px; cursor: pointer; min-height: 48px; }
.nbn-next:disabled { background: #c8c8c2; cursor: not-allowed; }
.nbn-next-wide { width: 100%; }
.nbn-skip { background: #fff; color: #141414; border: 1.5px solid #d4d4ce; border-radius: 10px; padding: 9px 14px; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; text-decoration: none; text-align: center; }
.nbn-back { justify-self: start; background: none; border: 0; color: #6b6b66; font: inherit; font-size: 12.5px; cursor: pointer; padding: 4px 2px; text-decoration: underline; }
.nbn-input { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.nbn-input input { font: inherit; font-size: 16px; padding: 12px 14px; border: 2px solid #e2e2dd; border-radius: 12px; min-width: 0; background: #fff; }
.nbn-input input:focus { outline: none; border-color: #141414; }
.nbn-input .nbn-skip { grid-column: 1 / -1; }
.nbn-summary { background: #fff; border: 2px solid #141414; border-radius: 12px; padding: 12px 14px; }
.nbn-summary-h { margin: 0 0 6px; font-size: 12px; font-weight: 800; color: #6b6b66; }
.nbn-summary-body { margin: 0; font: inherit; font-size: 13px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 150px; overflow-y: auto; }
.nbn-line { display: flex; align-items: center; justify-content: center; gap: 8px; background: #06c755; color: #fff !important; border-radius: 12px; padding: 14px 18px; font-weight: 800; font-size: 16px; text-decoration: none; min-height: 54px; box-shadow: 0 6px 16px rgba(6, 199, 85, .3); }
.nbn-line svg { width: 22px; height: 22px; }
.nbn-subrow { display: flex; flex-wrap: wrap; gap: 8px; }
.nbn-subrow > * { flex: 1 1 auto; }
.nbn-note { margin: 0; font-size: 11.5px; color: #6b6b66; line-height: 1.6; white-space: pre-line; }
.nbn-foot { padding: 8px 14px 12px; text-align: center; border-top: 1px solid #e6e6e1; background: #f6f6f3; }
.nbn-direct { font-size: 12px; color: #6b6b66; }
@keyframes nbn-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes nbn-dot { 0%, 80%, 100% { opacity: .3; } 40% { opacity: 1; } }
@media (max-width: 600px) {
	.nbn { align-items: flex-end; }
	.nbn-panel { width: 100%; height: 92%; height: 92dvh; border-radius: 18px 18px 0 0; }
}
@media (prefers-reduced-motion: reduce) {
	.nbn-row { animation: none; }
	.nbn-bubble.is-typing i { animation: none; }
}

/* サイト内の「AI検索対策相談」ボタン */
.nb-navi-btn { cursor: pointer; }
/* 「次へ」はいつも見える位置に */
.nbn-act > .nbn-next-wide { position: sticky; bottom: -12px; box-shadow: 0 -10px 14px #f6f6f3; }
.nbn-act { max-height: 66%; }
@media (max-width: 600px) {
	.nbn-opt { padding: 10px 12px; min-height: 44px; font-size: 14px; }
	.nbn-opts.is-multi .nbn-opt { padding-left: 40px; }
	.nbn-opts { gap: 6px; }
}
