/* =========================================================
   VT Legislative Tracker - Public Styles
   Clean, readable, civic-feeling design
   ========================================================= */

:root {
	--vtleg-accent: #1a6b3c;
	--vtleg-accent-light: #e8f5ee;
	--vtleg-radius: 10px;
	--vtleg-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
	--vtleg-border: #e2e8e4;
	--vtleg-text: #1a1f1c;
	--vtleg-muted: #5a7067;
	--vtleg-font-size: 16px;
}

/* ── Sizing variants ───────────────────────────────────── */
.vtleg-size-small  { --vtleg-font-size: 14px; }
.vtleg-size-medium { --vtleg-font-size: 16px; }
.vtleg-size-large  { --vtleg-font-size: 18px; }

/* ── Wrapper ───────────────────────────────────────────── */
.vtleg-bills-wrapper {
	display: flex;
	flex-direction: column;
	gap: 20px;
	font-size: var(--vtleg-font-size);
	font-family: Georgia, "Times New Roman", serif;
	color: var(--vtleg-text);
	max-width: 860px;
}

/* ── Card style ────────────────────────────────────────── */
.vtleg-style-card .vtleg-bill-card {
	background: #ffffff;
	border: 1px solid var(--vtleg-border);
	border-radius: var(--vtleg-radius);
	padding: 24px 28px;
	box-shadow: var(--vtleg-shadow);
	border-left: 4px solid var(--vtleg-accent);
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.vtleg-style-card .vtleg-bill-card:hover {
	box-shadow: 0 6px 24px rgba(0, 0, 0, 0.12);
	transform: translateY(-2px);
}

/* ── List style ────────────────────────────────────────── */
.vtleg-style-list .vtleg-bill-card {
	background: #fff;
	border-bottom: 1px solid var(--vtleg-border);
	padding: 18px 0;
}

.vtleg-style-list .vtleg-bill-card:first-child {
	border-top: 1px solid var(--vtleg-border);
}

/* ── Minimal style ─────────────────────────────────────── */
.vtleg-style-minimal .vtleg-bill-card {
	padding: 16px 0;
	border-bottom: 1px dashed var(--vtleg-border);
}

/* ── Header row ────────────────────────────────────────── */
.vtleg-bill-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 12px;
	flex-wrap: wrap;
}

.vtleg-bill-number-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.vtleg-bill-number {
	display: inline-block;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.85em;
	font-weight: 700;
	letter-spacing: 0.05em;
	color: var(--vtleg-accent);
	background: var(--vtleg-accent-light);
	padding: 4px 12px;
	border-radius: 100px;
	text-decoration: none;
	transition: background 0.15s;
}

.vtleg-bill-number:hover {
	background: rgba(var(--vtleg-accent-rgb, 26,107,60), 0.18);
	color: var(--vtleg-accent);
	text-decoration: none;
}

/* ── Issue tags ────────────────────────────────────────── */
.vtleg-issue-tags {
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
}

.vtleg-issue-tag {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.72em;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--vtleg-muted);
	background: #f3f6f4;
	padding: 3px 9px;
	border-radius: 100px;
	border: 1px solid var(--vtleg-border);
}

/* ── Bill title ────────────────────────────────────────── */
.vtleg-bill-title {
	font-size: 1em;
	font-weight: 700;
	line-height: 1.45;
	margin: 0 0 14px 0;
	color: var(--vtleg-text);
}

/* ── Bill summary block ────────────────────────────────── */
.vtleg-summary {
	background: #f9fbfa;
	border-left: 3px solid #9dc4af;
	border-radius: 0 6px 6px 0;
	padding: 13px 16px;
	margin-bottom: 16px;
}

.vtleg-summary-label {
	display: flex;
	align-items: center;
	gap: 6px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.75em;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--vtleg-muted);
	margin-bottom: 7px;
}

.vtleg-summary-icon {
	width: 15px;
	height: 15px;
	flex-shrink: 0;
	color: var(--vtleg-muted);
}

.vtleg-summary-text {
	font-size: 0.95em;
	line-height: 1.65;
	color: var(--vtleg-text);
	margin: 0;
}

/* ── Commentary / Notes ────────────────────────────────── */
.vtleg-bill-meta {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-bottom: 16px;
	padding: 14px 16px;
	background: #f9fbfa;
	border-radius: 6px;
	border: 1px solid #eef1ef;
}

.vtleg-meta-item {
	display: grid;
	grid-template-columns: 110px 1fr;
	gap: 8px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.85em;
	line-height: 1.5;
}

.vtleg-meta-label {
	font-weight: 700;
	color: var(--vtleg-muted);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	font-size: 0.85em;
	padding-top: 1px;
}

.vtleg-meta-value {
	color: var(--vtleg-text);
}

.vtleg-committee-link {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: var(--vtleg-accent);
	text-decoration: none;
	font-weight: 600;
}

.vtleg-committee-link:hover {
	text-decoration: underline;
}

.vtleg-ext-icon {
	width: 12px;
	height: 12px;
	flex-shrink: 0;
}

/* ── Commentary / Notes ────────────────────────────────── */
.vtleg-commentary {
	background: linear-gradient(135deg, rgba(var(--vtleg-accent-rgb, 26,107,60), 0.06), rgba(var(--vtleg-accent-rgb, 26,107,60), 0.02));
	border-left: 3px solid var(--vtleg-accent);
	border-radius: 0 6px 6px 0;
	padding: 14px 18px;
	margin-bottom: 16px;
}

.vtleg-commentary-label {
	display: flex;
	align-items: center;
	gap: 6px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.78em;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--vtleg-accent);
	margin-bottom: 8px;
}

.vtleg-comment-icon {
	width: 16px;
	height: 16px;
	color: var(--vtleg-accent);
	flex-shrink: 0;
}

.vtleg-commentary-text {
	font-size: 0.95em;
	line-height: 1.7;
	color: var(--vtleg-text);
	margin: 0;
}

/* ── Footer ────────────────────────────────────────────── */
.vtleg-bill-footer {
	padding-top: 4px;
}

.vtleg-read-more {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.82em;
	font-weight: 600;
	color: var(--vtleg-accent);
	text-decoration: none;
	letter-spacing: 0.01em;
}

.vtleg-read-more:hover {
	text-decoration: underline;
	color: var(--vtleg-accent);
}

.vtleg-read-more svg {
	width: 14px;
	height: 14px;
	transition: transform 0.15s;
}

.vtleg-read-more:hover svg {
	transform: translateX(3px);
}

/* ── Timeline ──────────────────────────────────────────── */
.vtleg-timeline {
	margin: 18px 0 20px;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	padding-bottom: 4px;
}

.vtleg-timeline-track {
	display: flex;
	align-items: flex-start;
	min-width: max-content;
	padding: 8px 0 4px;
}

/* Each stage */
.vtleg-stage {
	display: flex;
	flex-direction: column;
	align-items: center;
	position: relative;
	flex-shrink: 0;
}

/* Node + connector wrapper (horizontal row) */
.vtleg-stage-node {
	position: relative;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	transition: transform 0.2s ease;
}

.vtleg-stage-node:hover {
	transform: scale(1.1);
}

/* Stage states */
.vtleg-stage-done .vtleg-stage-node {
	background: var(--vtleg-accent);
	box-shadow: 0 2px 8px rgba(var(--vtleg-accent-rgb, 26,107,60), 0.35);
}

.vtleg-stage-active .vtleg-stage-node {
	background: var(--vtleg-accent);
	box-shadow: 0 2px 12px rgba(var(--vtleg-accent-rgb, 26,107,60), 0.45);
}

.vtleg-stage-pending .vtleg-stage-node {
	background: #f3f4f6;
	border: 2px solid #d1d5db;
}

.vtleg-stage-law .vtleg-stage-node {
	background: var(--vtleg-accent);
	box-shadow: 0 2px 14px rgba(var(--vtleg-accent-rgb, 26,107,60), 0.5);
}

.vtleg-stage-vetoed .vtleg-stage-node {
	background: #dc2626;
	box-shadow: 0 2px 8px rgba(220, 38, 38, 0.35);
}

/* Icons inside nodes */
.vtleg-stage-icon {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
}

.vtleg-stage-done .vtleg-stage-icon,
.vtleg-stage-active .vtleg-stage-icon,
.vtleg-stage-law .vtleg-stage-icon {
	color: #ffffff;
}

.vtleg-stage-pending .vtleg-stage-icon {
	color: #9ca3af;
}

.vtleg-stage-vetoed .vtleg-stage-icon {
	color: #ffffff;
}

/* Pulse ring on active stage */
.vtleg-stage-pulse {
	position: absolute;
	inset: -5px;
	border-radius: 50%;
	border: 2px solid var(--vtleg-accent);
	animation: vtleg-pulse 2s ease-in-out infinite;
	pointer-events: none;
}

@keyframes vtleg-pulse {
	0%, 100% { opacity: 0.6; transform: scale(1); }
	50%       { opacity: 0;   transform: scale(1.3); }
}

/* Connector between stages */
.vtleg-stage-connector {
	display: flex;
	align-items: center;
	height: 38px;
	padding: 0 2px;
	flex-shrink: 0;
}

.vtleg-connector-line {
	height: 2px;
	width: 36px;
	border-radius: 2px;
	transition: background 0.3s ease;
}

.vtleg-connector-done {
	background: var(--vtleg-accent);
}

.vtleg-connector-pending {
	background: #d1d5db;
	background-image: repeating-linear-gradient(
		90deg,
		#d1d5db 0,
		#d1d5db 4px,
		transparent 4px,
		transparent 8px
	);
}

/* Stage label */
.vtleg-stage-label {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 2px;
	padding: 6px 2px 0;
	width: 82px;
	text-align: center;
}

.vtleg-stage-name {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.68em;
	font-weight: 600;
	line-height: 1.3;
	color: var(--vtleg-muted);
}

.vtleg-stage-done .vtleg-stage-name,
.vtleg-stage-active .vtleg-stage-name,
.vtleg-stage-law .vtleg-stage-name {
	color: var(--vtleg-accent);
}

.vtleg-stage-vetoed .vtleg-stage-name {
	color: #dc2626;
}

.vtleg-stage-date {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 0.62em;
	color: #9ca3af;
	font-weight: 500;
}

.vtleg-stage-active .vtleg-stage-date,
.vtleg-stage-law .vtleg-stage-date {
	color: var(--vtleg-accent);
	font-weight: 600;
}

/* Scroll hint on small screens */
@media (max-width: 700px) {
	.vtleg-timeline::after {
		content: '';
		display: block;
		height: 2px;
		background: linear-gradient(90deg, var(--vtleg-accent) 0%, transparent 100%);
		border-radius: 2px;
		opacity: 0.3;
		margin-top: 4px;
	}
}

/* ── No bills ──────────────────────────────────────────── */
.vtleg-no-bills {
	color: var(--vtleg-muted);
	font-style: italic;
}

/* ── Responsive ────────────────────────────────────────── */
@media (max-width: 600px) {
	.vtleg-bill-header {
		flex-direction: column;
		align-items: flex-start;
	}

	.vtleg-meta-item {
		grid-template-columns: 1fr;
		gap: 2px;
	}

	.vtleg-style-card .vtleg-bill-card {
		padding: 18px 16px;
	}
}
