/* ==========================================================================
   Nossa História — template-nossa-historia.php
   (nome de classes hv2-nh-* para não colidir com o nossa-historia.css antigo, que é global)
   ========================================================================== */

.hv2-nh {
	--nh-purple: #692772;
	--nh-purple-2: #80217E;
	--nh-ink: #3D1446;
	--nh-muted: #6b5a73;
	--nh-soft: #F7F2FA;
	--nh-accent: #F2B705;
	--nh-line: rgba(105, 39, 114, .14);
	--nh-radius: 18px;
	background: #fff;
}

/* ---------- Topo ---------- */
.hv2-nh-hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	padding: clamp(2.5rem, 6vw, 4.5rem) 0;
	color: #fff;
	background:
		linear-gradient(120deg, rgba(46, 15, 53, .95) 0%, rgba(105, 39, 114, .9) 55%, rgba(128, 33, 126, .82) 100%),
		var(--hv2-nh-bg, none) center / cover no-repeat,
		var(--nh-purple);
}

.hv2-nh-hero::after {
	content: "";
	position: absolute;
	right: -6rem;
	bottom: -9rem;
	z-index: -1;
	width: 24rem;
	height: 24rem;
	border-radius: 50%;
	border: 3.5rem solid rgba(242, 183, 5, .1);
}

.hv2-nh-hero-inner {
	display: grid;
	grid-template-columns: minmax(0, 1.6fr) auto;
	gap: clamp(1.5rem, 4vw, 3rem);
	align-items: end;
}

.hv2-nh-eyebrow {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	padding: .35rem .9rem;
	border-radius: 999px;
	background: rgba(255, 255, 255, .12);
	color: var(--nh-accent);
	font-family: "montBold", sans-serif;
	font-size: .75rem;
	letter-spacing: .14em;
	text-transform: uppercase;
}

.hv2-nh-title {
	margin: .9rem 0 .6rem;
	max-width: 40rem;
	font-family: "montBold", "Montserrat", sans-serif !important;
	font-size: clamp(1.9rem, 4.2vw, 3rem);
	line-height: 1.12;
	color: #fff;
}

.hv2-nh-lead { margin: 0; max-width: 36rem; font-size: 1.05rem; line-height: 1.6; color: rgba(255, 255, 255, .85); }

.hv2-nh-stats { display: flex; gap: .75rem; margin: 0; padding: 0; list-style: none; }

.hv2-nh-stats li {
	display: flex;
	flex-direction: column;
	min-width: 8.5rem;
	padding: 1rem 1.15rem;
	border-radius: 14px;
	background: rgba(255, 255, 255, .1);
	border: 1px solid rgba(255, 255, 255, .18);
	backdrop-filter: blur(6px);
}

.hv2-nh-stats strong { font-family: "montBold", sans-serif; font-size: 2.2rem; line-height: 1; color: var(--nh-accent); }
.hv2-nh-stats span { margin-top: .35rem; font-size: .8rem; color: rgba(255, 255, 255, .8); }

/* ---------- Linha do tempo ---------- */
.hv2-nh-tl {
	padding: clamp(2.5rem, 6vw, 4.5rem) 0;
	background:
		radial-gradient(40rem 22rem at 100% 0%, rgba(242, 183, 5, .08), transparent 70%),
		var(--nh-soft);
}

.hv2-nh-tl-head {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: .5rem 1.5rem;
	margin-bottom: 1.75rem;
}

.hv2-nh-tl-title {
	margin: 0;
	font-family: "montBold", "Montserrat", sans-serif !important;
	font-size: clamp(1.6rem, 3vw, 2.25rem);
	color: var(--nh-purple);
}

.hv2-nh-tl-hint { margin: 0; display: inline-flex; align-items: center; gap: .4rem; font-size: .85rem; color: var(--nh-muted); }

/* Trilho dos anos */
.hv2-nh-rail {
	position: relative;
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(6.5rem, 1fr);
	gap: .5rem;
	margin-bottom: 1.75rem;
	padding: .25rem .25rem .5rem;
	overflow-x: auto;
	scrollbar-width: none;
}

.hv2-nh-rail::-webkit-scrollbar { display: none; }

.hv2-nh-rail-track {
	position: absolute;
	left: calc(100% / 12);
	right: calc(100% / 12);
	top: calc(.25rem + 1.6rem);
	height: 4px;
	border-radius: 4px;
	background: rgba(105, 39, 114, .15);
	pointer-events: none;
}

.hv2-nh-rail-fill {
	position: absolute;
	inset: 0;
	border-radius: 4px;
	background: linear-gradient(90deg, var(--nh-purple), var(--nh-purple-2) 70%, var(--nh-accent));
	transform: scaleX(0);
	transform-origin: left;
	transition: transform .5s cubic-bezier(.2, .8, .2, 1);
}

.hv2-nh-year {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: .55rem;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
}

.hv2-nh-dot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 3.2rem;
	height: 3.2rem;
	border-radius: 50%;
	background: #fff;
	border: 3px solid rgba(105, 39, 114, .25);
	color: var(--nh-purple);
	font-size: 1.2rem;
	transition: transform .3s ease, background-color .3s ease, border-color .3s ease, color .3s ease, box-shadow .3s ease;
}

.hv2-nh-year-label {
	font-family: "montBold", sans-serif;
	font-size: .95rem;
	color: var(--nh-muted);
	transition: color .3s ease;
}

.hv2-nh-year:hover .hv2-nh-dot { border-color: var(--nh-purple); transform: translateY(-2px); }
.hv2-nh-year.is-past .hv2-nh-dot { border-color: var(--nh-purple); background: #fff; }

.hv2-nh-year.is-active .hv2-nh-dot {
	background: linear-gradient(160deg, var(--nh-purple), var(--nh-purple-2));
	border-color: var(--nh-accent);
	color: var(--nh-accent);
	transform: scale(1.12);
	box-shadow: 0 0 0 6px rgba(242, 183, 5, .2), 0 10px 24px rgba(105, 39, 114, .3);
}

.hv2-nh-year.is-active .hv2-nh-year-label { color: var(--nh-purple); }
.hv2-nh-year:focus-visible { outline: none; }
.hv2-nh-year:focus-visible .hv2-nh-dot { box-shadow: 0 0 0 4px var(--nh-accent); }

/* Palco: painel do marco ativo */
.hv2-nh-stage {
	position: relative;
	overflow: hidden;
	border-radius: var(--nh-radius);
	background: #fff;
	border: 1px solid var(--nh-line);
	box-shadow: 0 2px 6px rgba(56, 18, 64, .06), 0 16px 40px rgba(56, 18, 64, .1);
}

.hv2-nh-panel {
	position: relative;
	isolation: isolate;
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: clamp(1.25rem, 3vw, 2.5rem);
	align-items: start;
	min-height: 17rem;
	padding: clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 4vw, 3.25rem) 1rem;
}

.hv2-nh-panel[hidden] { display: none; }

.hv2-nh-panel.from-right { animation: hv2-nh-in-right .45s cubic-bezier(.2, .8, .2, 1); }
.hv2-nh-panel.from-left { animation: hv2-nh-in-left .45s cubic-bezier(.2, .8, .2, 1); }

@keyframes hv2-nh-in-right { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@keyframes hv2-nh-in-left { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }

.hv2-nh-watermark {
	position: absolute;
	right: -.5rem;
	bottom: -2.2rem;
	z-index: -1;
	font-family: "montBold", sans-serif;
	font-size: clamp(6rem, 16vw, 12rem);
	line-height: 1;
	color: rgba(105, 39, 114, .05);
	pointer-events: none;
	user-select: none;
}

.hv2-nh-panel-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 4.5rem;
	height: 4.5rem;
	border-radius: 20px;
	background: linear-gradient(160deg, var(--nh-purple), var(--nh-purple-2));
	color: var(--nh-accent);
	font-size: 2rem;
	box-shadow: 0 12px 28px rgba(105, 39, 114, .3);
}

.hv2-nh-panel-year {
	margin: 0;
	font-family: "montBold", sans-serif;
	font-size: .85rem;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--nh-purple-2);
}

.hv2-nh-panel-title {
	margin: .35rem 0 .9rem;
	font-family: "montBold", "Montserrat", sans-serif !important;
	font-size: clamp(1.35rem, 2.6vw, 1.9rem);
	line-height: 1.25;
	color: var(--nh-ink);
}

.hv2-nh-panel-body p:not(.hv2-nh-panel-year) {
	max-width: 46rem;
	margin: 0 0 .8rem;
	font-size: 1.02rem;
	line-height: 1.7;
	color: #4b3a53;
}

.hv2-nh-nav {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: .75rem;
	padding: 0 clamp(1.5rem, 4vw, 3.25rem) clamp(1.25rem, 3vw, 2rem);
}

.hv2-nh-arrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.6rem;
	height: 2.6rem;
	border-radius: 50%;
	border: 1px solid var(--nh-line);
	background: #fff;
	color: var(--nh-purple);
	cursor: pointer;
	transition: background-color .2s ease, color .2s ease;
}

.hv2-nh-arrow:hover,
.hv2-nh-arrow:focus-visible { background: var(--nh-purple); color: #fff; outline: none; }

.hv2-nh-count { font-family: "montSemiBold", sans-serif; font-size: .85rem; color: var(--nh-muted); }

/* ---------- Convite ---------- */
.hv2-nh-cta { padding: clamp(2.5rem, 6vw, 4rem) 0; }

.hv2-nh-cta-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1.25rem 2rem;
	padding: clamp(1.5rem, 3.5vw, 2.5rem);
	border-radius: var(--nh-radius);
	background:
		radial-gradient(22rem 14rem at 100% 0%, rgba(242, 183, 5, .3), transparent 70%),
		linear-gradient(130deg, #3D1446, var(--nh-purple) 60%, var(--nh-purple-2));
	color: #fff;
}

.hv2-nh-cta-title {
	margin: 0 0 .35rem;
	font-family: "montBold", "Montserrat", sans-serif !important;
	font-size: clamp(1.4rem, 2.6vw, 1.9rem);
	color: #fff;
}

.hv2-nh-cta-inner p { margin: 0; color: rgba(255, 255, 255, .85); }
.hv2-nh-cta-links { display: flex; flex-wrap: wrap; gap: .6rem; }

.hv2-nh-btn {
	display: inline-flex;
	align-items: center;
	gap: .45rem;
	padding: .7rem 1.3rem;
	border-radius: 999px;
	border: 1.5px solid rgba(255, 255, 255, .45);
	color: #fff !important;
	font-family: "montBold", sans-serif;
	font-size: .82rem;
	letter-spacing: .04em;
	text-transform: uppercase;
	text-decoration: none;
	transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.hv2-nh-btn:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }
.hv2-nh-btn--solid { background: var(--nh-accent); border-color: var(--nh-accent); color: var(--nh-ink) !important; }
.hv2-nh-btn--solid:hover { background: #fff; border-color: #fff; }

/* ---------- Responsivo ---------- */
@media (max-width: 767.98px) {
	.hv2-nh-hero-inner { grid-template-columns: 1fr; align-items: start; }
	.hv2-nh-stats li { min-width: 0; flex: 1; }
	.hv2-nh-rail { grid-auto-columns: 5.5rem; }
	.hv2-nh-rail-track { left: 2.75rem; right: auto; width: calc(5.5rem * 5 + .5rem * 5); }
	.hv2-nh-panel { grid-template-columns: 1fr; }
	.hv2-nh-panel-icon { width: 3.5rem; height: 3.5rem; font-size: 1.5rem; border-radius: 16px; }
	.hv2-nh-nav { justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce) {
	.hv2-nh-panel.from-right, .hv2-nh-panel.from-left { animation: none; }
	.hv2-nh-rail-fill, .hv2-nh-dot { transition: none; }
}
