/* 「METAR＆TAF」の帯（tafbar.js）。METAR／TAFの欄の原文の下（2026-10-26 クロノコ決定） */
:root { --tb-vmc: #22914c; --tb-imc: #d23b3b; --tb-unk: #7d8a99; --tb-sel: #f5b301; --tb-now: #1a62c2; }
@media (prefers-color-scheme: dark) { :root { --tb-sel: #ffcc33; --tb-now: #6aa8ff; } }
.tafbar { margin: 14px 0 12px; border: 1.5px solid var(--accent); border-radius: 10px; padding: 8px 12px 6px; background: var(--card); overflow-wrap: normal; }
.tafbar .tb-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin: 0 0 4px; }
.tafbar .tb-h span { font-size: .78rem; color: var(--muted); }
.tb-sc { overflow-x: auto; padding: 0 0 2px; }
.tb-in { position: relative; margin: 0 2px; padding-top: 20px; }
.tb-tops, .tb-bar, .tb-unders { position: relative; }
/* 「現在」：青い字と、時刻の行から帯の下までの青い線 */
.tb-nowlbl { position: absolute; top: 0; transform: translateX(-50%); color: var(--tb-now); font-weight: 800; font-size: .76rem; white-space: nowrap; z-index: 3; }
.tb-now { position: absolute; top: 18px; bottom: 40px; border-left: 2.5px solid var(--tb-now); z-index: 3; pointer-events: none; }
.tb-tops { height: 24px; }
.tb-t { position: absolute; top: 2px; transform: translateX(-50%); font-size: .76rem; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tb-t:first-child { transform: none; } .tb-t:last-child { transform: translateX(-100%); }
.tb-t b { margin-right: 2px; }
.tb-vl { position: absolute; top: 40px; bottom: 0; border-left: 1.5px dashed var(--muted); opacity: .55; pointer-events: none; z-index: 1; }
.tb-bar { height: 44px; }
.tb-seg { position: absolute; top: 0; bottom: 0; margin: 0; padding: 0 7px; border: 0; border-right: 2px solid var(--card); box-sizing: border-box; cursor: pointer; font: inherit; color: #fff; overflow: hidden; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; text-align: left; }
.tb-seg.VMC { background: var(--tb-vmc); } .tb-seg.IMC { background: var(--tb-imc); } .tb-seg.UNK { background: var(--tb-unk); }
.tb-seg.GAP { background: repeating-linear-gradient(135deg, #c9d2dc 0 6px, #dde3ea 6px 12px); color: #3d4b5c; }
.tb-seg:first-child { border-radius: 8px 0 0 8px; } .tb-seg:last-child { border-radius: 0 8px 8px 0; border-right: 0; }
.tb-seg.on::before { content: ""; position: absolute; inset: 0; border: 4px solid var(--tb-sel); border-radius: inherit; box-shadow: inset 0 0 0 1px rgb(0 0 0 / .35); }
.tb-seg:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tb-nm { font-weight: 800; font-size: .86rem; white-space: nowrap; line-height: 1.15; }
.tb-nm.sm { font-size: .76rem; }
.tb-nm em { font-style: normal; font-size: .68rem; letter-spacing: .04em; background: rgb(255 255 255 / .92); color: var(--tb-imc); border-radius: 3px; padding: 0 4px; vertical-align: 1px; }
.tb-seg.VMC .tb-nm em { color: var(--tb-vmc); } .tb-seg.UNK .tb-nm em { color: #3d4b5c; }
.tb-unders { height: 40px; }
.tb-under { position: absolute; top: 4px; padding-left: 6px; box-sizing: border-box; font-size: .7rem; line-height: 1.3; white-space: nowrap; overflow: hidden; color: var(--text); }
.tb-under.on { font-weight: 700; }
.tb-lg { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .78rem; color: var(--muted); margin: 6px 0 2px; }
.tb-lg i { display: inline-block; width: 16px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
.tb-lg i.VMC { background: var(--tb-vmc); } .tb-lg i.IMC { background: var(--tb-imc); }
.tb-lg b { font-size: .72rem; margin-right: 2px; }
/* 押した区間の電文と訳 */
.tb-det { margin-top: 8px; border: 3px solid var(--tb-sel); border-radius: 10px; overflow: hidden; }
.tb-dh { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 6px 12px; color: #fff; font-weight: 700; }
.tb-det.VMC .tb-dh { background: var(--tb-vmc); } .tb-det.IMC .tb-dh { background: var(--tb-imc); } .tb-det.UNK .tb-dh, .tb-det.GAP .tb-dh { background: var(--tb-unk); }
.tb-dh small { font-weight: 400; font-size: .82rem; opacity: .95; }
.tb-lines { padding: 6px 12px 10px; display: grid; gap: 8px; }
.tb-ln { border-left: 4px solid var(--tb-vmc); padding: 1px 0 1px 10px; }
.tb-ln.tm { border-left-color: var(--tb-imc); }
.tb-ln code { display: block; font: .8rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--code); border-radius: 4px; padding: 3px 7px; overflow-wrap: anywhere; }
.tb-ln p, .tb-none { margin: 4px 0 0 !important; font-size: .88rem; line-height: 1.55; }
.tb-basis { margin: 6px 0 2px !important; font-size: .76rem; color: var(--muted); }
/* 入力した飛行の日時（2026-10-27 クロノコ指示）：赤紫の線と「入力した時刻」の字。「現在」の字の下の行に書く */
:root { --tb-at: #b0177a; }
@media (prefers-color-scheme: dark) { :root { --tb-at: #ff6ec7; } }
.tb-in.has-at { padding-top: 40px; }
.tb-in.has-at .tb-now { top: 38px; }
.tb-in.has-at .tb-vl { top: 60px; }
.tb-atlbl { position: absolute; top: 19px; transform: translateX(-50%); padding: 0 6px; border-radius: 4px; background: var(--tb-at); color: #fff; font-weight: 800; font-size: .74rem; white-space: nowrap; z-index: 4; }
.tb-at { position: absolute; top: 36px; bottom: 34px; border-left: 4px solid var(--tb-at); z-index: 4; pointer-events: none; box-shadow: 0 0 0 1.5px var(--card); }
.tb-at::after { content: ""; position: absolute; top: -2px; left: -8px; border: 6px solid transparent; border-top: 8px solid var(--tb-at); }
.tb-atout { margin: 0 0 6px !important; padding: 4px 10px; border-left: 4px solid var(--tb-at); font-size: .84rem; font-weight: 700; color: var(--tb-at); }
/* TAFの原文のうち、入力した時刻にかかる変化群 */
mark.tb-hl { background: color-mix(in srgb, var(--tb-at) 22%, transparent); color: inherit; border-bottom: 2.5px solid var(--tb-at); padding: 0; }
.tb-hlnote { margin: -4px 0 6px !important; font-size: .76rem; color: var(--tb-at); font-weight: 700; }
.tb-hlnote::before { content: ""; display: inline-block; width: 18px; height: 10px; margin-right: 5px; vertical-align: -1px; background: color-mix(in srgb, var(--tb-at) 22%, transparent); border-bottom: 2.5px solid var(--tb-at); }
