/* "Two clocks" scrubbable timeline — Inside Michigan, Energy Files.
   Uses the site's tokens (--page, --paper, --paper-2, --ink, --ink-2, --muted, --line, --line-soft,
   --accent, --accent-text, --accent-soft, --lake, --flame). Track colours are the ones the page's
   list already uses: project = --lake, legal = --flame. Shape repeats the encoding: circle above
   the line for the project track, diamond below it for the legal track. */
[data-widget="two-clocks"] { max-width: 68rem; color: var(--ink); font-size: 1rem; line-height: 1.5; }
[data-widget="two-clocks"] *,
[data-widget="two-clocks"] *::before,
[data-widget="two-clocks"] *::after { box-sizing: border-box; }

.tc-ui { display: grid; gap: .8rem; margin: 1.2rem 0 1rem; }
.tc-view { display: grid; gap: .8rem; min-width: 0; }
.tc-status { max-width: 80ch; margin: 0; color: var(--ink); font-size: 1.0625rem; font-weight: 600; line-height: 1.45; }

/* ---- controls ---- */
.tc-controls { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; gap: .6rem; align-items: end; }
.tc-btn {
	min-width: 44px;
	min-height: 44px;
	padding: .3rem .9rem;
	border: 1px solid var(--line);
	border-radius: 0;
	background: var(--paper);
	color: var(--ink);
	font: inherit;
	font-size: .9375rem;
	font-weight: 700;
	white-space: nowrap;
	cursor: pointer;
}
.tc-btn:hover:not(:disabled) { border-color: var(--accent); }
.tc-btn:disabled { opacity: .45; cursor: default; }
.tc-play[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.tc-btn:focus-visible, .tc-range input:focus-visible, .tc-m:focus-visible, .tc-text summary:focus-visible, .tc-card a:focus-visible {
	outline: 3px solid var(--ink);
	outline-offset: 2px;
}
.tc-range { min-width: 0; }
.tc-range label { display: block; color: var(--muted); font-size: .8125rem; font-weight: 700; letter-spacing: .04em; }
.tc-pos { font-weight: 400; font-variant-numeric: tabular-nums; }
.tc-range input { display: block; width: 100%; height: 44px; margin: 0; accent-color: var(--accent); cursor: pointer; }
.tc-playnote { margin: 0; color: var(--muted); font-size: .8125rem; }

/* ---- stage ---- */
.tc-stage { position: relative; box-sizing: content-box !important; overflow: hidden; border: 1px solid var(--line); background: var(--paper); }
.tc-svg { position: absolute; top: 0; left: 0; display: block; }
.tc-zone { fill: var(--line-soft); }
.tc-band { fill: var(--page); stroke: var(--line); stroke-width: 1; }
.tc-ytick { stroke: var(--muted); stroke-width: 1.5; }
.tc-mtick { stroke: var(--line); stroke-width: 1; }
.tc-year { fill: var(--muted); font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
.tc-stem { stroke: var(--muted); stroke-width: 1; }
.tc-span.tc-project { fill: var(--lake); }
.tc-span.tc-legal { fill: var(--flame); }
.tc-tracklabel {
	position: absolute;
	padding: 0 .6rem;
	color: var(--muted);
	font-size: .8125rem;
	font-weight: 700;
	letter-spacing: .04em;
	line-height: 1.25;
}
.tc-vert .tc-tracklabel { padding: .7rem .2rem 0; }
.tc-todayline { position: absolute; border: 0 dashed var(--ink-2, var(--ink)); border-left-width: 2px; }
.tc-vert .tc-todayline { border-left-width: 0; border-top-width: 2px; }
.tc-playhead {
	position: absolute;
	border: 0 solid var(--accent-text, var(--accent));
	border-left-width: 3px;
	margin-left: -1.5px;
	transition: transform .45s cubic-bezier(.3, .8, .3, 1);
	pointer-events: none;
}
.tc-vert .tc-playhead { margin: -1.5px 0 0; border-left-width: 0; border-top-width: 3px; }
.tc-tag {
	position: absolute;
	top: 2px;
	left: 0;
	padding: .05rem .5rem;
	background: var(--accent-text, var(--accent));
	color: var(--page);
	font-size: .8125rem;
	font-weight: 700;
	line-height: 1.5;
	white-space: nowrap;
}
.tc-vert .tc-tag { display: none; }
.tc-still .tc-playhead, .tc-still .tc-m svg * { transition: none; }

/* ---- markers ---- */
.tc-markers { position: absolute; inset: 0; }
.tc-m {
	position: absolute;
	top: 0;
	left: 0;
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--lake);
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
}
.tc-m.tc-legal { color: var(--flame); }
.tc-m svg { display: block; overflow: visible; pointer-events: none; }
.tc-m svg * { fill: var(--paper); stroke: currentColor; stroke-width: 3; transition: fill .3s ease; }
.tc-m.tc-past svg * { fill: currentColor; }
.tc-m.tc-sched svg * { stroke-dasharray: 3.2 2.6; stroke-width: 2.5; }
.tc-m:hover svg { transform: scale(1.15); }
.tc-m.tc-cur { z-index: 2; background: var(--paper); box-shadow: inset 0 0 0 3px var(--accent-text, var(--accent)); }
.tc-m.tc-sched.tc-cur svg * { fill: var(--accent-soft); }
.tc-m:focus-visible { z-index: 3; }
.tc-todaybtn {
	display: block;
	width: auto;
	padding: 0 .75rem;
	border: 1px dashed var(--ink-2, var(--ink));
	border-radius: 0;
	background: var(--page);
	color: var(--ink);
	font: inherit;
	font-size: .8125rem;
	font-weight: 700;
	white-space: nowrap;
}
.tc-todaybtn.tc-cur { border: 1px solid var(--accent-text, var(--accent)); background: var(--page); box-shadow: inset 0 0 0 2px var(--accent-text, var(--accent)); }
.tc-tip {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 5;
	max-width: min(24rem, 100%);
	padding: .3rem .6rem;
	background: var(--ink);
	color: var(--page);
	font-size: .8125rem;
	font-weight: 600;
	line-height: 1.3;
	pointer-events: none;
}

/* ---- the entry at the playhead ---- */
.tc-card { padding: .9rem 1rem 1rem; border: 1px solid var(--line); border-top: 3px solid var(--accent-text, var(--accent)); background: var(--paper); }
.tc-card-meta { display: flex; flex-wrap: wrap; gap: .4rem .7rem; align-items: center; margin: 0 0 .35rem; color: var(--muted); font-size: .8125rem; }
.tc-date { color: var(--ink); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.tc-badge { padding: .05rem .45rem; border: 1px solid currentColor; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.tc-badge.tc-project { color: var(--lake); }
.tc-badge.tc-legal { color: var(--flame); }
.tc-b-sched { border-style: dashed; color: var(--ink); }
.tc-card-title { margin: 0 0 .3rem; color: var(--ink); font-size: 1.125rem; line-height: 1.3; }
.tc-card-body { max-width: 78ch; margin: 0; color: var(--ink-2, var(--ink)); font-size: .9375rem; }
.tc-card a { color: var(--accent-text); font-weight: 700; text-underline-offset: .18em; }
.tc-vert .tc-card { position: sticky; bottom: 0; z-index: 4; max-height: 40vh; overflow: auto; box-shadow: 0 -10px 24px -12px rgba(0, 0, 0, .55); }

/* ---- key, text version, notes ---- */
.tc-key { display: flex; flex-wrap: wrap; gap: .2rem 1.1rem; margin: 0; padding: 0; list-style: none; color: var(--ink-2, var(--ink)); font-size: .875rem; }
.tc-key li { display: flex; align-items: center; gap: .3rem; }
.tc-keymark { position: static; width: 24px; height: 24px; cursor: default; }
.tc-keymark:hover svg { transform: none; }
.tc-keymark svg { width: 20px; height: 20px; }
.tc-text { margin: 0 0 1rem; border: 1px solid var(--line); background: var(--paper); }
.tc-text summary { display: flex; align-items: center; min-height: 44px; padding: .4rem .9rem; font-size: .9375rem; font-weight: 700; cursor: pointer; }
.tc-text[open] summary { border-bottom: 1px solid var(--line); }
.tc-text .tl { margin: 1.2rem 1rem 0; }
.tc-text .tl-legend { margin: 0 1rem 1rem; }
/* the page's own list sets its dates, lane tags and legend below 13px; lift them inside the text version */
.tc-text .tl-date, .tc-text .tl-lane, .tc-text .tl-legend { font-size: .8125rem; }
.tc-read, .tc-src { max-width: 78ch; margin: .7rem 0 0; color: var(--muted); font-size: .8125rem; line-height: 1.55; }
.tc-read strong, .tc-src strong { color: var(--ink-2, var(--ink)); }

@media (max-width: 560px) {
	.tc-controls { grid-template-columns: 1fr 1fr 1fr; }
	.tc-range { grid-column: 1 / -1; grid-row: 1; }
}
@media (prefers-reduced-motion: reduce) {
	.tc-playhead, .tc-m svg * { transition: none; }
	.tc-m:hover svg { transform: none; }
}
@media (forced-colors: active) {
	.tc-m.tc-cur { outline: 3px solid Highlight; }
	.tc-tag { forced-color-adjust: none; }
}
