/* Vome — business plan shared styles.
 * Used by both /business-plan (VomeHome) and /business-plan-hire
 * (Nyvyn + VomeHire).
 *
 * Theming variables (--bg-primary etc.) come from vomehome.css.
 */

		body { padding-top: 0; }

		.bp-top {
			position: sticky;
			top: 0;
			z-index: 50;
			background: rgba(18, 18, 18, 0.85);
			backdrop-filter: saturate(140%) blur(10px);
			border-bottom: 1px solid var(--border);
			padding: 0.85rem 1.25rem;
			display: flex;
			justify-content: space-between;
			align-items: center;
			font-size: 0.92rem;
		}
		.bp-top .brand {
			display: flex;
			align-items: center;
			gap: 0.5rem;
			color: var(--text-primary);
			font-weight: 700;
			text-decoration: none;
		}
		.bp-top .brand .gradient-text {
			background: linear-gradient(135deg, var(--primary), var(--accent));
			-webkit-background-clip: text;
			background-clip: text;
			color: transparent;
		}
		.bp-top .top-actions { display: flex; gap: 0.6rem; align-items: center; }
		.bp-top a.top-link, .bp-top button.top-link {
			color: var(--text-secondary);
			text-decoration: none;
			font-weight: 500;
			padding: 0.3rem 0.6rem;
			border-radius: var(--radius-sm);
			background: transparent;
			border: 0;
			cursor: pointer;
			font: inherit;
		}
		.bp-top a.top-link:hover, .bp-top button.top-link:hover {
			color: var(--primary);
			background: rgba(255, 152, 0, 0.08);
		}

		/* ── Top-level tab strip ──────────────────────────────── */
		.bp-tabs-wrapper {
			background: var(--bg-secondary);
			border-bottom: 1px solid var(--border);
			padding: 0.75rem 0;
		}
		.bp-tabs {
			max-width: 1200px;
			margin: 0 auto;
			padding: 0 1.5rem;
			display: flex;
			gap: 0.5rem;
			flex-wrap: wrap;
		}
		.bp-tabs button {
			background: var(--bg-primary);
			border: 1px solid var(--border);
			color: var(--text-secondary);
			padding: 0.7rem 1.1rem;
			border-radius: var(--radius);
			font-weight: 600;
			cursor: pointer;
			transition: var(--transition);
			text-align: left;
			min-width: 200px;
		}
		.bp-tabs button .tab-meta {
			display: block;
			font-size: 0.75rem;
			font-weight: 500;
			color: var(--text-muted);
			letter-spacing: 0.04em;
			margin-top: 0.15rem;
			text-transform: none;
		}
		.bp-tabs button:hover {
			border-color: var(--border-light);
			color: var(--text-primary);
		}
		.bp-tabs button[aria-selected="true"] {
			background: linear-gradient(135deg, rgba(255,152,0,0.15), rgba(16,185,129,0.10));
			border-color: var(--primary);
			color: var(--text-primary);
		}
		.bp-tabs button[aria-selected="true"] .tab-meta {
			color: var(--text-secondary);
		}

		/* ── Layout ───────────────────────────────────────────── */
		.bp-shell {
			display: grid;
			grid-template-columns: 240px 1fr;
			gap: 2.5rem;
			max-width: 1200px;
			margin: 0 auto;
			padding: 2.5rem 1.5rem 5rem;
		}
		@media (max-width: 900px) {
			.bp-shell { grid-template-columns: 1fr; gap: 1rem; padding-top: 1.5rem; }
		}

		.bp-toc {
			position: sticky;
			top: 8.5rem;
			align-self: start;
			max-height: calc(100vh - 9.5rem);
			overflow-y: auto;
			padding: 1.25rem 0.75rem;
			border-left: 1px solid var(--border);
			font-size: 0.93rem;
		}
		.bp-toc h4 {
			font-size: 0.78rem;
			text-transform: uppercase;
			letter-spacing: 0.1em;
			color: var(--text-muted);
			margin: 0 0 0.85rem 0;
		}
		.bp-toc ol {
			list-style: none;
			padding: 0;
			margin: 0;
			counter-reset: tocnum;
		}
		.bp-toc li { margin-bottom: 0.35rem; counter-increment: tocnum; }
		.bp-toc a {
			display: block;
			padding: 0.35rem 0.6rem;
			color: var(--text-secondary);
			text-decoration: none;
			border-radius: var(--radius-sm);
			border-left: 2px solid transparent;
		}
		.bp-toc a::before {
			content: counter(tocnum) ". ";
			color: var(--text-muted);
		}
		.bp-toc a:hover {
			color: var(--primary);
			background: rgba(255, 152, 0, 0.06);
		}
		.bp-toc a.active {
			color: var(--primary);
			border-left-color: var(--primary);
			background: rgba(255, 152, 0, 0.06);
		}
		@media (max-width: 900px) {
			.bp-toc {
				position: static;
				border-left: none;
				border-top: 1px solid var(--border);
				max-height: none;
			}
		}

		/* ── Document body ────────────────────────────────────── */
		.bp-doc { color: var(--text-secondary); line-height: 1.75; font-size: 1.02rem; }
		.bp-doc header.title-block {
			margin-bottom: 1.5rem;
			padding-bottom: 1.25rem;
			border-bottom: 1px solid var(--border);
		}
		.bp-doc header.title-block .eyebrow {
			color: var(--primary);
			font-weight: 600;
			text-transform: uppercase;
			letter-spacing: 0.12em;
			font-size: 0.82rem;
			margin-bottom: 0.6rem;
		}
		.bp-doc header.title-block h1 {
			font-size: 2.6rem;
			font-weight: 800;
			line-height: 1.15;
			color: var(--text-primary);
			margin: 0 0 0.5rem;
		}
		.bp-doc header.title-block .meta {
			color: var(--text-muted);
			font-size: 0.95rem;
		}

		.plan-banner {
			background: var(--bg-secondary);
			border: 1px solid var(--border);
			border-left: 3px solid var(--primary);
			border-radius: var(--radius-lg);
			padding: 1.1rem 1.4rem;
			margin: 1.5rem 0 2rem;
			display: grid;
			grid-template-columns: 1fr 1fr 1fr;
			gap: 1rem;
		}
		@media (max-width: 720px) { .plan-banner { grid-template-columns: 1fr 1fr; } }
		.plan-banner .pf-label {
			font-size: 0.72rem;
			text-transform: uppercase;
			letter-spacing: 0.08em;
			color: var(--text-muted);
			font-weight: 600;
			margin-bottom: 0.2rem;
			display: block;
		}
		.plan-banner .pf-value {
			color: var(--text-primary);
			font-weight: 700;
			font-size: 1.05rem;
		}

		.bp-doc h2 {
			font-size: 1.55rem;
			font-weight: 800;
			color: var(--text-primary);
			margin-top: 2.3rem;
			margin-bottom: 0.8rem;
			padding-top: 1rem;
			scroll-margin-top: 9rem;
		}
		.bp-doc h2 .num {
			display: inline-block;
			color: var(--primary);
			font-weight: 600;
			margin-right: 0.5rem;
		}
		.bp-doc h3 {
			font-size: 1.12rem;
			font-weight: 700;
			color: var(--text-primary);
			margin-top: 1.4rem;
			margin-bottom: 0.5rem;
		}
		.bp-doc p { margin-bottom: 1rem; }
		.bp-doc ul, .bp-doc ol { margin-bottom: 1rem; padding-left: 1.4rem; }
		.bp-doc li { margin-bottom: 0.35rem; }
		.bp-doc strong { color: var(--text-primary); }
		.bp-doc a { color: var(--primary); }
		.bp-doc a:hover { color: var(--accent); }
		.bp-doc .conv {
			color: var(--text-muted);
			font-weight: 400;
			font-size: 0.85em;
			margin-left: 0.15em;
		}

		.callout {
			background: var(--bg-secondary);
			border: 1px solid var(--border);
			border-left: 3px solid var(--primary);
			border-radius: var(--radius);
			padding: 1rem 1.25rem;
			margin: 1.25rem 0;
			color: var(--text-secondary);
		}
		.callout strong { color: var(--text-primary); }
		.callout.muted { border-left-color: var(--text-muted); }
		.callout.accent { border-left-color: var(--accent); }

		.bp-doc table {
			width: 100%;
			border-collapse: separate;
			border-spacing: 0;
			margin: 1rem 0 1.5rem;
			font-size: 0.95rem;
		}
		.bp-doc th, .bp-doc td {
			padding: 0.65rem 0.85rem;
			border-bottom: 1px solid var(--border);
			text-align: left;
		}
		.bp-doc th {
			color: var(--text-muted);
			font-weight: 600;
			text-transform: uppercase;
			letter-spacing: 0.05em;
			font-size: 0.78rem;
			border-bottom: 1px solid var(--border-light);
		}
		.bp-doc td:first-child { color: var(--text-primary); font-weight: 500; }
		.bp-doc tfoot td {
			border-top: 1px solid var(--border-light);
			color: var(--text-primary);
			font-weight: 600;
		}
		.bp-doc .num-cell { font-variant-numeric: tabular-nums; text-align: right; }

		.fund-bar {
			margin-bottom: 0.85rem;
		}
		.fund-bar .row1 {
			display: flex;
			justify-content: space-between;
			align-items: baseline;
			margin-bottom: 0.35rem;
			font-size: 0.95rem;
		}
		.fund-bar .label { color: var(--text-primary); font-weight: 600; }
		.fund-bar .pct { color: var(--text-muted); font-variant-numeric: tabular-nums; }
		.fund-bar .track {
			background: var(--bg-secondary);
			border: 1px solid var(--border);
			height: 12px;
			border-radius: 999px;
			overflow: hidden;
		}
		.fund-bar .fill {
			height: 100%;
			background: linear-gradient(90deg, var(--primary), var(--accent));
			border-radius: 999px;
		}
		.fund-bar .note {
			margin: 0.3rem 0 0;
			font-size: 0.92rem;
			color: var(--text-muted);
		}

		.risk-grid {
			display: grid;
			grid-template-columns: 1fr;
			gap: 0.75rem;
			margin: 1rem 0 1.5rem;
		}
		.risk {
			border: 1px solid var(--border);
			border-radius: var(--radius);
			padding: 1rem 1.1rem;
			background: var(--bg-secondary);
		}
		.risk h4 {
			font-size: 1rem;
			color: var(--text-primary);
			margin: 0 0 0.4rem;
			display: flex;
			align-items: center;
			gap: 0.45rem;
		}
		.risk-tag {
			font-size: 0.7rem;
			text-transform: uppercase;
			letter-spacing: 0.08em;
			padding: 0.15rem 0.5rem;
			border-radius: 999px;
			border: 1px solid var(--border-light);
			color: var(--text-muted);
			font-weight: 600;
		}
		.risk-tag.high {
			color: #fca5a5;
			border-color: rgba(239, 68, 68, 0.4);
			background: rgba(239, 68, 68, 0.08);
		}
		.risk-tag.med {
			color: #fde68a;
			border-color: rgba(245, 158, 11, 0.4);
			background: rgba(245, 158, 11, 0.08);
		}
		.risk-tag.low {
			color: #86efac;
			border-color: rgba(34, 197, 94, 0.4);
			background: rgba(34, 197, 94, 0.08);
		}
		.risk p { margin: 0.25rem 0 0; font-size: 0.95rem; }

		/* Plan content visibility — only the active panel is shown. */
		.plan-content { display: none; }
		.plan-content.is-active { display: block; }

		.bp-foot {
			margin-top: 3rem;
			padding-top: 1.5rem;
			border-top: 1px solid var(--border);
			color: var(--text-muted);
			font-size: 0.9rem;
		}

		@media print {
			body { background: white; color: black; padding-top: 0; }
			.bp-top, .bp-toc, .bp-tabs-wrapper { display: none; }
			.bp-shell {
				grid-template-columns: 1fr;
				max-width: none;
				padding: 1rem;
			}
			.bp-doc, .bp-doc h1, .bp-doc h2, .bp-doc h3, .bp-doc p,
			.bp-doc li, .bp-doc th, .bp-doc td, .callout, .risk h4,
			.plan-banner .pf-value {
				color: #111 !important;
			}
			.bp-doc h2 .num, .bp-doc a, .gradient-text {
				color: #b35a00 !important;
				-webkit-text-fill-color: #b35a00 !important;
			}
			.callout, .risk, .fund-bar .track, .plan-banner {
				background: #fafafa !important;
				border-color: #ddd !important;
			}
			.fund-bar .fill { background: #b35a00 !important; }
			.bp-doc h2 { page-break-after: avoid; break-after: avoid; }
			.bp-doc table { page-break-inside: avoid; break-inside: avoid; }

			/* In print, expand all paths so reviewer sees all three. */
			.plan-content { display: block !important; page-break-before: always; }
			.plan-content::before {
				content: attr(data-print-title);
				display: block;
				font-weight: 700;
				font-size: 1.4rem;
				margin: 0 0 0.6rem;
				color: #b35a00 !important;
			}
		}
