/* UNDER LAYERS — 当直照会(メール認証)・作戦記録の入口・ヘッダーのログイン状態
   kb.css のトークンと部品(.box .band .kv .btn .field)だけを使う。接頭辞は auth- / ac- / ops- */

/* ============================================================ ヘッダーのログイン状態(全ページ) */

.auth-slot {
	display: inline-flex;
	align-items: center;
	min-width: 0;
}

.auth-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-width: 0;
	max-width: 100%;
	min-height: 44px;
	padding: 0 4px;
	color: var(--sub);
	font-size: var(--fs-s);
	line-height: 1.3;
	white-space: nowrap;
	text-decoration: none;
}

.auth-chip:link,
.auth-chip:visited {
	color: var(--sub);
	text-decoration: none;
}

.auth-chip .ac-k {
	flex: none;
	padding: 0 3px;
	color: var(--muted);
	border: 1px solid var(--line-hi);
	font-size: var(--fs-xs);
	letter-spacing: .06em;
}

.auth-chip .ac-v {
	display: inline-flex;
	gap: 5px;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

.auth-chip .ac-name,
.auth-chip .ac-acct {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

.auth-chip .ac-name {
	max-width: 9em;
	color: var(--fg);
}

.auth-chip .ac-ok {
	flex: none;
	color: var(--fg-hi);
}

.auth-chip .ac-acct {
	max-width: 14em;
	color: var(--fg);
}

.auth-chip .ac-go {
	flex: none;
	color: var(--fg);
	border-bottom: 1px dotted var(--line-hi);
}

.auth-chip .ac-go::before { content: "["; color: var(--muted); }
.auth-chip .ac-go::after { content: "]"; color: var(--muted); }

.auth-chip[data-state="verified"] .ac-k {
	color: var(--bg);
	background: var(--fg);
	border-color: var(--fg);
}

.auth-chip[data-state="loading"] {
	color: var(--muted);
}

.auth-chip:hover .ac-go,
.auth-chip:focus-visible .ac-go {
	color: var(--bg);
	background: var(--fg);
}

.auth-chip:focus-visible {
	outline: 1px dotted var(--fg);
	outline-offset: -2px;
}

/* 防壁構築・侵入構築(.kb-top の flex): operator 表示の右 */
.kb-top .boardlist.auth-host .auth-slot {
	margin-right: -4px;
}

@media (max-width: 559px) {
	.auth-chip .ac-acct { max-width: 11em; }
	.auth-chip .ac-name { max-width: 6em; }

	/* 構築画面の狭い幅: 音のスイッチと同じ行に収める(チップ全体がアカウントへのリンク) */
	.kb-top .auth-chip[data-state="verified"] .ac-go { display: none; }
}

/* ============================================================ ヘッダーの帯域(認証済みのみ。assets/js/auth/stamina.js) */

.st-host {
	position: relative;
	display: inline-flex;
	flex: none;
	align-items: center;
}

.st-host[hidden] { display: none; }

.st-chip {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	min-height: 44px;
	margin: 0;
	padding: 0 4px;
	color: var(--sub);
	background: none;
	border: 0;
	font: inherit;
	font-size: var(--fs-s);
	line-height: 1.3;
	white-space: nowrap;
	cursor: pointer;
}

.st-chip-k {
	padding: 0 3px;
	color: var(--muted);
	border: 1px solid var(--line-hi);
	font-size: var(--fs-xs);
}

/* 照会レベル(2026-11-16。帯域の札の左。下に細い照会値のバー。作戦記録の大きな「レベル」の欄の代わり) */
.st-chip-lv {
	display: inline-flex;
	flex-direction: column;
	align-items: stretch;
	gap: 1px;
	margin-right: 3px;
	color: var(--fg-hi);
}

.st-chip-lv[hidden] { display: none; }

.st-lv-bar {
	display: block;
	height: 2px;
	background: var(--bg-deep);
	box-shadow: 0 0 0 1px var(--line);
}

.st-lv-bar > i {
	display: block;
	height: 100%;
	background: var(--cyan);
}

.st-tip-lv {
	display: grid;
	gap: 3px;
	margin-bottom: 4px;
	padding-bottom: 5px;
	border-bottom: 1px solid var(--line);
}

.st-tip-lv[hidden] { display: none; }

.st-chip-v { color: var(--fg); }
.st-chip[data-full="1"] .st-chip-v { color: var(--fg-hi); }
.st-chip[data-low="1"] .st-chip-v { color: var(--warn); }

.st-chip:hover .st-chip-k,
.st-chip[aria-expanded="true"] .st-chip-k {
	color: var(--bg);
	background: var(--fg);
	border-color: var(--fg);
}

.st-chip:focus-visible {
	outline: 1px dotted var(--fg);
	outline-offset: -2px;
}

.st-tip {
	position: absolute;
	top: calc(100% - 4px);
	right: 0;
	z-index: 85;
	display: grid;
	gap: 3px;
	width: 15.5em;
	max-width: calc(100vw - 16px);
	padding: 8px 10px 9px;
	color: var(--fg);
	background: var(--bg-1);
	border: 1px solid var(--line-hi);
	box-shadow: 0 8px 22px rgba(0, 0, 0, .65);
	font-size: var(--fs-s);
	line-height: 1.45;
	text-align: left;
	white-space: normal;
}

.st-tip[hidden] { display: none; }
.st-tip.is-left { right: auto; left: 0; }

.st-tip-h {
	margin-bottom: 2px;
	color: var(--fg-hi);
	font-size: var(--fs-xs);
	letter-spacing: .06em;
}

.st-tip-row {
	display: flex;
	justify-content: space-between;
	gap: 10px;
}

.st-tip-row .k,
.st-tip-r,
.st-tip-n { color: var(--sub); }

.st-tip-n {
	margin-top: 2px;
	padding-top: 4px;
	border-top: 1px dotted var(--line);
	font-size: var(--fs-xs);
}

/* 配給所の一時強化(効果中だけ。帯域の横)と、吹き出しの通貨の行。docs/api.md §29 */
.st-chip-b {
	margin-left: 4px;
	padding: 0 3px;
	color: var(--bg);
	background: var(--cyan);
	font-size: var(--fs-xs);
}

.st-chip-b[hidden] { display: none; }

.st-tip-shop {
	display: grid;
	gap: 3px;
	margin-top: 4px;
	padding-top: 5px;
	border-top: 1px solid var(--line);
}

.st-tip-shop[hidden] { display: none; }

/* 配給所の行が入るので吹き出しを少し広く(狭い画面では画面の幅まで) */
.st-tip:has(.st-tip-shop:not([hidden])) { width: 19.5em; }
.st-tip-row.is-boost .num { color: var(--cyan); }

.auth-slot { gap: 2px; }

/* 帯域補給(配給所で買った道具。2026-11-19)。帯域の札の右に「[絵]×3 [使う]」。狭い幅は吹き出しの中の欄だけ */
/* 帯域補給は吹き出しの中だけ(札には直接出さない)。持っているときは帯域の札に小さい印 */
.st-chip[data-band="1"] .st-chip-v::after { content: "+"; margin-left: 2px; color: var(--cyan); }
.st-band-use {
	min-height: 28px;
	margin: 0;
	padding: 0 7px;
	color: var(--cyan);
	background: none;
	border: 1px solid var(--cyan);
	font: inherit;
	font-size: var(--fs-xs);
	cursor: pointer;
}
.st-band-use:hover:not(:disabled) { color: var(--bg); background: var(--cyan); }
.st-band-use:disabled { opacity: .45; cursor: default; }
.st-band-use:focus-visible { outline: 1px dotted var(--fg); outline-offset: 1px; }
.st-tip-band.is-zero { opacity: .55; }
.st-band-r { display: inline-flex; align-items: center; gap: 6px; }
.st-tip-band .st-band-use { min-height: 32px; }

/* 付けているジョブ(帯域の札の左。2026-11-19)。札は job-view.js の jobTag。吹き出しは帯域と同じ見た目 */
.st-job-host {
	position: relative;
	display: inline-flex;
	flex: none;
	align-items: center;
}
.st-job-host[hidden] { display: none; }
.st-job {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	margin: 0;
	padding: 0 2px;
	color: var(--sub);
	background: none;
	border: 0;
	font: inherit;
	cursor: pointer;
}
.st-job .job-tag { margin-left: 0; }
.st-job:hover .job-tag,
.st-job[aria-expanded="true"] .job-tag { border-color: var(--fg); }
.st-job:focus-visible { outline: 1px dotted var(--fg); outline-offset: -2px; }
.st-job-tip { width: 16em; }
.st-job-tip .st-tip-row .k { white-space: nowrap; }
.st-job-up { color: var(--warn); }
.st-job-go {
	margin-top: 2px;
	padding: 6px 0 2px;
	border-top: 1px dotted var(--line);
	color: var(--fg);
	text-align: right;
}
.st-job-go::after { content: " >"; color: var(--muted); }

@media (max-width: 559px) {
	/* 狭い幅: ジョブの札は絵と Lv だけ(名前・段階の印は吹き出しで)。行が溢れないように */
	.st-job .job-tag { padding: 0 3px 0 2px; }
	.st-job .job-tag-m,
	.st-job .job-tag-n { display: none; }
	.st-job .job-tag::after { content: attr(data-lv); }
	/* 狭い幅: 一時強化は効果だけ(残り時間は吹き出しで) */
	.st-chip-b { max-width: 4.6em; overflow: hidden; text-overflow: clip; }
	/* 狭い幅: 帯域を残すため、アカウントの名前を短く */
	.auth-slot:has(.st-host:not([hidden])) .auth-chip .ac-acct { max-width: 7em; }
	/* 狭い幅で一時強化のチップも出ているとき: ヘッダーの BGM のボタン(2026-11-15)の分、「[アカウント]」を省く
	   (チップ全体がアカウントへのリンク。構築画面の上の決まりと同じ)。「認証済」の文字を残す */
	.mainblock > .boardlist:has(.st-chip-b:not([hidden])) .auth-chip[data-state="verified"] .ac-go { display: none; }
	/* 照会レベル(2026-11-16)が出ているときも同じ(名前を残すため) */
	.mainblock > .boardlist:has(.st-chip-lv:not([hidden])) .auth-chip[data-state="verified"] .ac-go { display: none; }
}

@media (max-width: 380px) {
	.auth-slot:has(.st-host:not([hidden])) .auth-chip[data-state="verified"] .ac-acct { display: none; }
}

/* ============================================================ ページの骨組み(login / verify / operations) */

/* ゲーム画面扱い: 四隅まで読ませたいので周辺減光を掛けない */
body.page-auth::after {
	content: none;
}

.auth-main {
	max-width: 720px;
}

.auth-lead {
	margin: 4px 0 0;
	font-size: var(--fs-s);
}

.auth-mode {
	margin: 4px 0 0;
	color: var(--sub);
	font-size: var(--fs-xs);
}

.auth-mode .k {
	color: var(--muted);
}

.auth-app {
	margin-top: 18px;
}

.auth-app > * + * {
	margin-top: 18px;
}

.auth-box .box-body > * + * {
	margin-top: 10px;
}

.auth-box .box-body > :first-child {
	margin-top: 0;
}

.band.is-warn {
	background-color: var(--warn);
}

.auth-p,
.auth-sent-h {
	margin: 0;
}

.auth-sent-h {
	color: var(--fg-hi);
}

.auth-sent-h:focus {
	outline: none; /* 画面が切り替わったときに読み上げの起点としてフォーカスするだけ(操作する所ではない) */
}

.auth-sent-h .ok {
	color: var(--fg);
}

.auth-sent-h.is-bad {
	color: var(--alert-hi);
}

.auth-note {
	margin: 0;
	color: var(--sub);
	font-size: var(--fs-s);
}

.auth-note a,
.auth-p a {
	color: var(--fg);
	text-decoration: underline dotted;
	text-underline-offset: 3px;
}

.auth-carry {
	padding: 6px 8px;
	border-left: 2px solid var(--line-hi);
}

.auth-kv th {
	width: 1%;
}

.auth-mail {
	color: var(--fg-hi);
	overflow-wrap: anywhere;
}

.auth-mig {
	color: var(--fg-hi);
}

/* 01 → 02 → 03 */
.auth-flow {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 0;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--fs-s);
}

.auth-flow li {
	display: inline-flex;
	align-items: baseline;
	gap: 6px;
	color: var(--muted);
}

.auth-flow li + li::before {
	content: "\2192";
	margin: 0 8px;
	color: var(--line-hi);
}

.auth-flow .n {
	padding: 0 3px;
	border: 1px solid var(--line);
	font-size: var(--fs-xs);
}

.auth-flow li.is-done {
	color: var(--sub);
}

.auth-flow li.is-done .n {
	border-color: var(--line-hi);
}

.auth-flow li.is-now {
	color: var(--fg-hi);
}

.auth-flow li.is-now .n {
	color: var(--bg);
	background: var(--fg);
	border-color: var(--fg);
}

/* フォーム */
.auth-label {
	display: block;
	margin-bottom: 4px;
	color: var(--fg);
	font-size: var(--fs-s);
}

.auth-row {
	display: flex;
	gap: 8px;
	align-items: stretch;
}

.auth-row .field {
	flex: 1 1 auto;
	min-height: 40px;
	font-size: 16px; /* iOS の自動ズームを避ける */
}

.auth-row .btn {
	flex: none;
	min-width: 0;
	padding: 4px 12px;
}

.auth-form .form-err,
.auth-form .auth-note {
	margin-top: 6px;
}

.auth-wait {
	margin: 6px 0 0;
	color: var(--warn);
	font-size: var(--fs-s);
}

.auth-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
}

.auth-actions .btn {
	min-width: 0;
}

.btn.primary {
	color: var(--bg);
	background: var(--fg);
	border-color: var(--fg-hi);
}

a.btn.primary:link,
a.btn.primary:visited {
	color: var(--bg);
}

.btn.primary:hover,
.btn.primary:focus-visible,
a.btn.primary:hover,
a.btn.primary:focus-visible {
	color: var(--fg);
	background: var(--bg);
}

.btn.primary:disabled {
	color: var(--muted);
	background: var(--bg);
}

.auth-confirm {
	display: grid;
	gap: 10px;
}

.auth-confirm > * {
	margin: 0;
}

.auth-wd {
	display: grid;
	gap: 8px;
}

.auth-wd p {
	margin: 0;
}

/* 別のブラウザで開いたリンク: 匿名データを引き継ぐかの選択 */
.auth-merge {
	display: grid;
	gap: 6px;
	padding: 8px 10px;
	border: 1px dashed rgba(232, 193, 90, .5);
}

.auth-merge > * {
	margin: 0;
}

.auth-merge .toggle {
	align-items: flex-start;
	white-space: normal;
	line-height: 1.6;
}

.auth-merge .toggle .box-mark {
	flex: none;
}

.auth-name .field {
	max-width: 22em;
	font-size: 16px;
}

/* 作戦記録 */
.ops-lock .lock {
	color: var(--warn);
}

.ops-term {
	margin: 0;
	padding: 8px 10px;
	color: var(--fg);
	background: var(--bg-deep);
	border: 1px solid var(--line);
	font-family: var(--mono);
	font-size: var(--fs-s);
	line-height: 1.6;
	white-space: pre-wrap;
}

/* タイトル画面: 作戦記録の告知帯(モードボタンの下) */
.ops-strip {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: center;
	gap: 2px 10px;
	max-width: 560px;
	margin: 14px auto 0;
	padding: 6px 10px;
	color: var(--sub);
	border: 1px dashed var(--line-hi);
	font-size: var(--fs-s);
	text-align: center;
	text-decoration: none;
}

.ops-strip:link,
.ops-strip:visited {
	color: var(--sub);
	text-decoration: none;
}

.ops-strip .ops-k {
	color: var(--fg-hi);
	font-weight: bold;
}

.ops-strip .ops-k::before {
	content: "\25B6  ";
	color: var(--fg);
}

.ops-strip .ops-tag {
	/* 札の文字は auth/header.js が入れる(入るまでは場所だけ取る。文字の長さで帯の中身が左右に動かないよう幅をそろえる) */
	display: inline-block;
	min-width: 6.5em;
	text-align: center;
	padding: 0 4px;
	color: var(--bg);
	background: var(--warn);
	font-size: var(--fs-xs);
}

.ops-strip .ops-tag:empty {
	visibility: hidden;
}

.ops-strip[data-state="verified"] .ops-tag {
	background: var(--fg);
}

.ops-strip:hover,
.ops-strip:focus-visible {
	color: var(--fg);
	border-style: solid;
	border-color: var(--fg);
	outline: none;
}

@media (max-width: 560px) {
	.auth-row {
		flex-direction: column;
	}

	.auth-row .btn {
		min-height: 44px;
	}

	.auth-actions .btn {
		min-height: 44px;
	}

	.auth-flow {
		flex-direction: column;
	}

	.auth-flow li + li::before {
		content: none;
	}

	.ops-strip {
		min-height: 44px;
	}
}


/* 利用停止中(BAN。docs/api.md §26): ヘッダーのチップと、サイト内リンクの下の定型文の帯(header.js)・入口の箱(common.js banBox) */
.auth-chip[data-state="banned"] .ac-k {
	color: var(--bg);
	background: var(--alert);
	border-color: var(--alert);
}

.auth-chip .ac-ban {
	flex: none;
	color: var(--alert-hi);
}

.auth-ban-note {
	margin: 6px 0 10px;
	padding: 6px 10px;
	border: 1px solid var(--alert);
	background: var(--alert-bg);
	color: var(--alert-hi);
	overflow-wrap: anywhere;
}

.mainblock > .auth-ban-note,
.kb-top + .auth-ban-note {
	grid-column: 1 / -1;
}

.auth-ban-box .auth-ban-msg {
	color: var(--alert-hi);
	font-weight: bold;
	overflow-wrap: anywhere;
}

/* ============================================================ メンテナンス・お知らせ(全ページ。assets/js/maint.js・news.js。docs/api.md §27・§28) */

/* 予告・停止中の帯(サイト内リンクの直後)。高さは1行ぶん。文字は textContent */
.mt-note {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 4px 8px;
	margin: 4px 0 10px;
	padding: 5px 10px;
	border: 1px solid var(--warn);
	color: var(--warn);
	font-size: var(--fs-s);
	line-height: 1.5;
	overflow-wrap: anywhere;
}

.mt-note[data-state="soon"],
.mt-note[data-state="active"] {
	border-color: var(--alert);
	background: var(--alert-bg);
	color: var(--alert-hi);
}

.mt-note-k {
	flex: none;
	padding: 0 4px;
	border: 1px solid currentColor;
	font-family: var(--mono);
	font-size: var(--fs-xs);
	letter-spacing: .05em;
}

.mt-note-t { min-width: 0; }

.mt-note-a,
.mt-note-a:link,
.mt-note-a:visited {
	color: inherit;
	font-size: var(--fs-xs);
}

.mainblock > .mt-note,
.kb-top + .mt-note {
	grid-column: 1 / -1;
}

.kb-top + .mt-note {
	margin: 0;
	border-width: 0 0 1px;
}

/* 60分を切ったら画面上部のバナー(閉じられる) */
.mt-banner {
	position: sticky;
	top: 0;
	z-index: 1000;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 16px;
	border-bottom: 2px solid var(--alert);
	background: #1a0408;
	color: var(--alert-hi);
}

.mt-banner-b {
	flex: 1 1 auto;
	min-width: 0;
}

.mt-banner-t,
.mt-banner-m {
	margin: 0;
	overflow-wrap: anywhere;
	font-size: var(--fs-m);
	line-height: 1.5;
}

.mt-banner-t { font-weight: bold; }

.mt-banner-m {
	margin-top: 2px;
	color: var(--fg);
	font-size: var(--fs-s);
	white-space: pre-line;
}

.mt-banner-x {
	flex: none;
	min-width: 44px;
	min-height: 44px;
	padding: 0 10px;
	border: 1px solid var(--alert);
	background: transparent;
	color: var(--alert-hi);
	font: inherit;
	font-size: var(--fs-s);
	cursor: pointer;
}

.mt-banner-x:hover,
.mt-banner-x:focus-visible {
	background: var(--alert-bg);
	outline: 1px dotted var(--alert-hi);
	outline-offset: 2px;
}

/* メンテナンス中: ページの中身を隠して、メンテナンスの画面だけ */
html.mt-locked body > :not(#mt-screen) {
	display: none !important;
}

html.mt-locked body {
	overflow-x: hidden;
}

.mt-screen {
	position: relative;
	z-index: 10;
	max-width: 640px;
	margin: 0 auto;
	padding: 40px 16px 32px;
}

.mt-box .band { font-size: var(--fs-l); }

.mt-lead {
	margin: 0 0 10px;
	color: var(--fg-hi);
	font-size: var(--fs-l);
	font-weight: bold;
}

.mt-msg {
	margin: 0 0 12px;
	padding: 8px 10px;
	border-left: 3px solid var(--alert);
	white-space: pre-line;
	overflow-wrap: anywhere;
}

.mt-left { color: var(--sub); }

.mt-p {
	margin: 10px 0 0;
	font-size: var(--fs-s);
	line-height: 1.7;
}

.mt-actions { margin: 14px 0 0; }

.mt-links {
	margin: 14px 0 0;
	font-size: var(--fs-s);
}

/* お知らせの未読の印(サイト内リンクの「お知らせ」) */
.news-new {
	display: inline-block;
	margin-left: 3px;
	padding: 0 3px;
	background: var(--alert);
	color: var(--bg);
	font-family: var(--mono);
	font-size: 9px;
	font-weight: bold;
	line-height: 1.4;
	vertical-align: super;
	text-decoration: none;
}

@media (prefers-reduced-motion: no-preference) {
	.news-new { animation: blink 1.6s steps(1, end) infinite; }
}

/* お知らせ: 一覧(news.html)とトップの最新の数件 */
.news-list {
	display: grid;
	gap: 12px;
}

.news-item {
	scroll-margin-top: 64px;
	border: 1px solid var(--line);
	background: var(--bg-1);
}

.news-item.is-target {
	border-color: var(--fg);
	box-shadow: 0 0 0 1px var(--fg);
}

.news-item-h {
	margin: 0;
	padding: 8px 10px 4px;
	font-family: var(--sans);
	font-size: var(--fs-l);
	line-height: 1.4;
	overflow-wrap: anywhere;
}

.news-item-h a,
.news-item-h a:link,
.news-item-h a:visited {
	color: var(--fg-hi);
	text-decoration: none;
}

.news-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 10px;
	margin: 0;
	padding: 0 10px 6px;
	color: var(--sub);
	font-size: var(--fs-xs);
}

.news-kind {
	padding: 0 5px;
	border: 1px solid currentColor;
}

.news-kind[data-kind="update"] { color: var(--fg); }
.news-kind[data-kind="info"] { color: var(--cyan); }
.news-kind[data-kind="maint"] { color: var(--warn); }
.news-kind[data-kind="bug"] { color: var(--alert-hi); }
/* 週・月のボスの自動のお知らせ: 襲撃 = 赤(地を塗る)/ 浮上 = 琥珀(地を塗る)。メンテナンス(琥珀の枠)・不具合(赤の枠)と塗りで見分ける */
.news-kind[data-kind="raid"] { color: var(--bg); background: var(--alert); border-color: var(--alert); }
.news-kind[data-kind="surface"] { color: var(--bg); background: var(--warn); border-color: var(--warn); }
.news-kind[data-kind="salvage"] { color: var(--bg); background: var(--tier-t3); border-color: var(--tier-t3); }
.news-kind[data-kind="tide"] { color: #e6f2ff; background: #1d3a5a; border-color: var(--cyan); }
.news-salvage { margin: 6px 0 0; }

.news-pin { color: var(--fg-hi); }

.news-body {
	margin: 0;
	padding: 8px 10px 10px;
	border-top: 1px dotted var(--line);
	font-size: var(--fs-m);
	line-height: 1.75;
	white-space: pre-line;
	overflow-wrap: anywhere;
}

.news-body a { word-break: break-all; }

.news-empty {
	color: var(--sub);
}

.news-latest {
	margin: 0;
	padding: 0;
	list-style: none;
}

.news-latest li {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 2px 8px;
	padding: 6px 0;
	border-bottom: 1px dotted var(--line);
	font-size: var(--fs-s);
}

.news-latest li:last-child { border-bottom: 0; }

.news-latest a {
	min-width: 0;
	overflow-wrap: anywhere;
}

.news-latest .news-date {
	color: var(--sub);
	font-family: var(--mono);
	font-size: var(--fs-xs);
}

.news-more {
	margin: 8px 0 0;
	font-size: var(--fs-s);
	text-align: right;
}

/* ------------------------------------------------------------ お知らせの「ボスの一覧」(週4体・月2体。news.js の bossSlot。docs/ui-design.md §3.11)
   当直表(roster.css)の見た目に合わせる。news.html は roster.css・ops.css・raid.css・art.css を読まないので、使う分だけここに書く */
.nb {
	margin: 0 10px 10px;
	border: 1px solid var(--line);
	background: var(--bg);
}

.nb-h.is-surface { background-color: var(--warn); }

.nb-body {
	display: grid;
	gap: 8px;
	padding: 8px;
}

.nb-msg { margin: 0; font-size: var(--fs-s); }

.nb-period {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 2px 8px;
	margin: 0;
	font-size: var(--fs-s);
}

.nb-period-k {
	padding: 0 4px;
	color: var(--bg);
	background: var(--fg);
	font-size: var(--fs-xs);
	white-space: nowrap;
}

.nb-period.is-ended { color: var(--sub); }
.nb-period.is-ended .nb-period-k { color: var(--muted); background: var(--line); }
.nb-left { color: var(--fg-hi); }

.nb-list {
	display: grid;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.nb-boss {
	display: grid;
	gap: 8px;
	min-width: 0;
	padding: 8px;
	border: 1px solid var(--line);
	border-left: 3px solid var(--line-hi);
	background: var(--bg-1);
	font-size: var(--fs-s);
}

.nb-boss.is-slot-2,
.nb-boss.is-slot-3 { border-left-color: var(--alert); }
.nb-boss.is-big { border-left-color: var(--warn); }

/* 頭: [枠の呼び名] 名前・帯・一言 */
.nb-boss-h {
	display: grid;
	grid-template-columns: 64px minmax(0, 1fr);
	align-items: start;
	gap: 4px 10px;
}

/* 枠の呼び名の下にボスの姿(kb.css の .boss-thumb。当直表の .rs-tg-lead と同じ並び) */
.nb-boss-lead { display: grid; justify-items: stretch; gap: 4px; width: 64px; }

.nb-slot {
	padding: 2px 0 0;
	color: var(--bg);
	background: var(--alert);
	font-family: var(--display);
	font-size: var(--fs-s);
	line-height: 1.3;
	text-align: center;
	white-space: nowrap;
}

.nb-boss.is-big .nb-slot { background: var(--warn); }
.nb-slot rt { font-family: var(--sans); font-size: 9px; font-weight: normal; letter-spacing: .05em; }

.nb-boss-t {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
	overflow-wrap: anywhere;
}

.nb-name {
	color: var(--fg-hi);
	font-size: var(--fs-m);
	font-weight: bold;
}

.nb-boss-t > small { font-size: var(--fs-xs); }

.nb-boss-m {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 2px 6px;
	font-size: var(--fs-xs);
}

/* 帯(やさしめ / ふつう / 手強い / 大型 …) */
.nb-band {
	padding: 0 4px;
	border: 1px solid var(--line-hi);
	color: var(--fg-hi);
	white-space: nowrap;
}

.nb-boss.is-slot-2 .nb-band,
.nb-boss.is-slot-3 .nb-band { border-color: var(--alert); }
.nb-boss.is-big .nb-band { color: var(--warn); border-color: var(--warn); }
.nb-note { color: var(--sub); }

/* 中身: 強さ | 落ちるもの(狭い画面は縦に並べる) */
.nb-boss-b {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 8px 14px;
}

.nb-power,
.nb-drops {
	display: grid;
	align-content: start;
	gap: 6px;
	min-width: 0;
}

.nb-sub {
	margin: 0;
	padding-bottom: 2px;
	border-bottom: 1px dotted var(--line);
	color: var(--sub);
	font-family: var(--mono);
	font-size: var(--fs-xs);
	font-weight: normal;
	letter-spacing: .08em;
}

.nb-facts {
	display: flex;
	flex-wrap: wrap;
	gap: 2px 12px;
	margin: 0;
}

.nb-fact b {
	margin-left: 4px;
	color: var(--fg-hi);
	font-weight: normal;
}

.nb-stats {
	border-collapse: collapse;
	font-size: var(--fs-s);
}

.nb-stats th,
.nb-stats td {
	padding: 1px 10px 1px 0;
	text-align: left;
	white-space: nowrap;
}

.nb-stats thead th {
	color: var(--sub);
	font-size: var(--fs-xs);
	font-weight: normal;
}

.nb-stats tbody th {
	color: var(--sub);
	font-weight: normal;
}

.nb-stats td { color: var(--fg-hi); }
.nb-stats .nb-lk-v { color: var(--warn); }

/* 月の大型の補正(琥珀)・封鎖下の補正(琥珀の点線) */
.nb-mod {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 2px 6px;
	margin: 0;
	color: var(--warn);
	font-size: var(--fs-xs);
	overflow-wrap: anywhere;
}

.nb-mod-k {
	padding: 0 3px;
	border: 1px solid var(--warn);
	white-space: nowrap;
}

.nb-mod.is-lk { color: var(--sub); }
.nb-mod.is-lk .nb-mod-k { color: var(--warn); border-style: dotted; }

/* 傾向(raid/profile.js の profileView。raid.css の .tg-* と同じ形) */
.nb-prof { display: grid; gap: 4px; }
.nb-prof-k { margin: 0; font-size: var(--fs-xs); }
.nb-prof .tg-prof { display: grid; gap: 4px; min-width: 0; }
.nb-prof .tg-label { margin: 0; font-size: var(--fs-xs); }
.nb-prof .tg-label b { color: var(--fg); font-size: var(--fs-s); font-weight: normal; }
.nb-prof .tg-axes .axis { grid-template-columns: 3.2em minmax(0, 9em) 2em; font-size: var(--fs-xs); }
.nb-prof .tg-axes .axis .v { text-align: right; }
.nb-prof .tg-axes .meter { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; height: 7px; }
.nb-prof .tg-axes .meter i { background: var(--bg-2); box-shadow: inset 0 0 0 1px var(--line); }
.nb-prof .tg-axes .meter i.on { background: var(--fg); box-shadow: none; }
.nb-prof .tg-axes .lv-high .meter i.on { background: var(--fg-hi); }
.nb-prof .tg-tags { display: flex; flex-wrap: wrap; gap: 2px 10px; margin: 0; padding: 0; list-style: none; font-size: var(--fs-xs); }
.nb-prof .tg-tags .n { margin-right: 3px; color: var(--muted); }

/* 落ちる2種類 */
.nb-pair {
	display: grid;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.nb-card {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	padding: 4px 6px;
	border: 1px solid var(--line);
	background: var(--bg);
}

.nb-card-t {
	display: flex;
	flex-direction: column;
	gap: 1px;
	min-width: 0;
}

.nb-card-h {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 2px 6px;
}

.nb-card-h > b {
	color: var(--fg-hi);
	font-weight: normal;
	overflow-wrap: anywhere;
}

.nb-card-m {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 2px 6px;
	font-size: var(--fs-xs);
}

.nb-how {
	justify-self: start;
	margin: 0;
	padding: 0 4px;
	border: 1px dotted var(--line-hi);
	color: var(--sub);
	font-size: var(--fs-xs);
}

.nb-how.is-split {
	color: var(--cyan);
	border-color: currentColor;
}

.nb-tiers-h { margin: 2px 0 0; font-size: var(--fs-xs); }

.nb-tiers {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 3px 4px;
	margin: 0;
	font-size: var(--fs-xs);
}

.nb-tiers-k {
	min-width: 4.5em;
	color: var(--sub);
}

.nb-tiers.is-lk .nb-tiers-k { color: var(--warn); }

/* ティアの札(ops.css の .x-tier と同じ色) */
.nb-tier {
	display: inline-block;
	padding: 0 4px;
	border: 1px solid currentColor;
	line-height: 1.4;
	white-space: nowrap;
}

.nb-tier.x-t1 { color: var(--tier-t1, #8ea08a); }
.nb-tier.x-t2 { color: var(--tier-t2, #a6f08a); }
.nb-tier.x-t3 { color: var(--tier-t3, #6fd6e8); }
.nb-tier.x-t4 { color: var(--bg); background: var(--tier-t4, #c79bff); border-color: var(--tier-t4, #c79bff); }

/* カードの絵(art.js の cardArt。art.css を読まないページなので、小さい絵の分だけ) */
.nb-card .kb-art {
	--art: 32px;
	--art-c: var(--line-hi);
	position: relative;
	display: none;
	flex: 0 0 auto;
	width: var(--art);
	height: var(--art);
	overflow: hidden;
	background: var(--bg-deep);
	box-shadow: inset 0 0 0 1px var(--line);
	pointer-events: none;
}

.kb-arts .nb-card .kb-art { display: inline-block; }
.nb-card .kb-art-img { display: block; width: 100%; height: 100%; image-rendering: auto; }
.nb-card .kb-art-img.is-hold { visibility: hidden; }
.nb-card .kb-art[data-kind="frame"] { --art-c: var(--fg); }
.nb-card .kb-art[data-kind="core"] { --art-c: var(--alert); }
.nb-card .kb-art[data-kind="program"] { --art-c: var(--cyan); }
.nb-card .kb-art[data-kind="shell"] { --art-c: var(--warn); }
.nb-card .kb-art[data-kind="trait"] { --art-c: var(--sub); }
.nb-card .kb-art-ph { position: absolute; inset: 0; border: 1px solid var(--art-c); opacity: .55; }

/* 挑むボタン(期間中だけ)。封鎖照会は当直表の a.btn.rs-lk と同じ: 琥珀の文字と枠にうっすら警戒の縞 */
.nb-go {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-end;
	gap: 6px;
	padding-top: 6px;
	border-top: 1px dotted var(--line);
}

.nb-go .btn { text-decoration: none; }

a.btn.nb-lk:link,
a.btn.nb-lk:visited {
	color: var(--warn);
	border-color: var(--warn);
	background: repeating-linear-gradient(135deg, rgba(232, 193, 90, .14) 0 3px, transparent 3px 7px), var(--bg);
}

a.btn.nb-lk:hover,
a.btn.nb-lk:focus-visible {
	color: var(--bg);
	background: var(--warn);
}

.nb-ended { color: var(--muted); font-size: var(--fs-xs); }
/* 未解放の種類(週 = 第2章・月 = 第3章のクリアで解放)は挑むボタンを押せなくして条件を出す */
.nb-go .btn.is-locked:disabled { opacity: .45; cursor: not-allowed; }
.nb-locked { color: var(--warn); font-size: var(--fs-xs); }

.nb-note-all { margin: 0; font-size: var(--fs-xs); }

.nb-foot {
	margin: 0;
	padding: 0 8px 8px;
	text-align: right;
}

.nb-foot .btn { text-decoration: none; }

@media (max-width: 559px) {
	.nb { margin: 0 6px 8px; }
	.nb-body { padding: 6px; }
	.nb-boss { padding: 6px; }
	.nb-boss-b { grid-template-columns: minmax(0, 1fr); }
	.nb-go { justify-content: flex-start; }
	.nb-go .btn,
	.nb-foot .btn { min-height: 40px; }
	.nb-foot { text-align: left; }
}

/* 増配(期間限定の通貨の倍率。lib/Events.php)のお知らせ・ヘッダーの印 */
.news-kind[data-kind="event"] { color: var(--bg); background: var(--cyan); border-color: var(--cyan); }
/* 減免(帯域の使用量の割引)の札: 減免だけ = シアンの枠と文字(地は塗らない)・増配と両方 = 増配と同じ塗り。どちらも減免の印のアイコン(pi-band-cut)を前に。赤は使わない */
.news-kind[data-kind="band"] { color: var(--cyan); background: var(--bg); border-color: var(--cyan); }
.news-kind[data-kind="event_band"] { color: var(--bg); background: var(--cyan); border-color: var(--cyan); }
.news-kind[data-kind="band"], .news-kind[data-kind="event_band"] { white-space: nowrap; }
.news-kind > .pi-band-cut { margin-right: 2px; vertical-align: -3px; }
.st-tip-ev { margin-left: 6px; padding: 0 4px; color: var(--bg); background: var(--cyan); font-size: var(--fs-xs); white-space: nowrap; }
/* 配給所の通貨の行: 名前 | 所持(期間の獲得/上限) | 増配の札。札は行の末尾に折り返さず 1 行で。入りきらなければ次の行の右端へ */
.st-tip-shop .st-tip-row { flex-wrap: wrap; align-items: baseline; gap: 1px 6px; }
.st-tip-shop .st-tip-row .k { flex: 1 0 auto; white-space: nowrap; }
.st-tip-shop .st-tip-row .num { flex: 0 0 auto; white-space: nowrap; }
.st-tip-shop .st-tip-ev { flex: 0 0 auto; margin-left: auto; }
.st-job-eff > :last-child { text-align: right; }

/* プレイヤー番号の行(ヘッダーのアカウントボタンの行き先の表。融通所で相手を指す番号。docs/trade-design.md §4.5) */
.auth-pno-v { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.auth-pno { color: var(--fg-hi); font-size: var(--fs-l); font-weight: normal; letter-spacing: .04em; user-select: all; }
.auth-pno-copy { min-height: 32px; }
.auth-pno-trade { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-s); }
