/**
 * Page Mentions légales — onglets accessibles
 */

.emotta-legal {
	--emotta-legal-border: rgba(148, 163, 184, 0.25);
	--emotta-legal-tab-bg: rgba(15, 23, 42, 0.6);
}

[data-emotta-theme="light"] .emotta-legal {
	--emotta-legal-border: rgba(15, 23, 42, 0.12);
	--emotta-legal-tab-bg: rgba(241, 245, 249, 0.9);
}

.emotta-legal__tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 1.5rem;
	border-bottom: 1px solid var(--emotta-legal-border);
	padding-bottom: 0.75rem;
}

.emotta-legal__tab {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.6rem 1rem;
	font-size: 0.875rem;
	font-weight: 600;
	color: #94a3b8;
	background: transparent;
	border: 1px solid transparent;
	border-radius: 0.5rem;
	cursor: pointer;
	transition: color 0.15s, background 0.15s, border-color 0.15s;
}

[data-emotta-theme="light"] .emotta-legal__tab {
	color: #64748b;
}

.emotta-legal__tab:hover {
	color: #e2e8f0;
	background: var(--emotta-legal-tab-bg);
}

[data-emotta-theme="light"] .emotta-legal__tab:hover {
	color: #0f172a;
}

.emotta-legal__tab[aria-selected="true"] {
	color: #fff;
	background: linear-gradient(135deg, rgba(139, 92, 246, 0.35), rgba(59, 130, 246, 0.35));
	border-color: rgba(139, 92, 246, 0.45);
}

[data-emotta-theme="light"] .emotta-legal__tab[aria-selected="true"] {
	color: #0f172a;
	background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(59, 130, 246, 0.2));
	border-color: rgba(139, 92, 246, 0.35);
}

.emotta-legal__tab:focus-visible {
	outline: 2px solid #8b5cf6;
	outline-offset: 2px;
}

.emotta-legal__panel {
	display: none;
	max-width: 48rem;
	margin: 0 auto;
}

.emotta-legal__panel.is-active {
	display: block;
}

.emotta-legal__panel-inner {
	color: #cbd5e1;
	font-size: 0.9375rem;
	line-height: 1.7;
}

[data-emotta-theme="light"] .emotta-legal__panel-inner {
	color: #334155;
}

.emotta-legal__panel-inner h2 {
	font-size: 1.125rem;
	font-weight: 700;
	color: #f1f5f9;
	margin: 2rem 0 0.75rem;
}

[data-emotta-theme="light"] .emotta-legal__panel-inner h2 {
	color: #0f172a;
}

.emotta-legal__panel-inner h2:first-child {
	margin-top: 0;
}

.emotta-legal__panel-inner p {
	margin: 0 0 1rem;
}

.emotta-legal__panel-inner ul {
	margin: 0 0 1rem 1.25rem;
	padding: 0;
	list-style: disc;
}

.emotta-legal__panel-inner li {
	margin-bottom: 0.35rem;
}

.emotta-legal__dl {
	margin: 0 0 1.25rem;
}

.emotta-legal__dl dt {
	font-weight: 600;
	color: #e2e8f0;
	margin-top: 0.75rem;
}

[data-emotta-theme="light"] .emotta-legal__dl dt {
	color: #1e293b;
}

.emotta-legal__dl dt:first-child {
	margin-top: 0;
}

.emotta-legal__dl dd {
	margin: 0.25rem 0 0;
	padding: 0;
	margin-inline-start: 0;
	text-align: left;
	white-space: normal;
	word-break: break-word;
}

/* Retours ligne pour siège / adresse hébergeur sans espaces parasites (évite le décalage type RCS) */
.emotta-legal__dl dd.emotta-legal__dd-multiline {
	white-space: pre-line;
}

.emotta-legal__dl dd.emotta-legal__dd-contact {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.35rem;
}

.emotta-legal__dl .emotta-legal__contact-line {
	display: block;
	width: 100%;
	text-align: left;
}

.emotta-legal__admin-note {
	margin-bottom: 1.5rem;
	padding: 0.75rem 1rem;
	font-size: 0.8125rem;
	border-radius: 0.5rem;
	background: rgba(251, 191, 36, 0.15);
	border: 1px solid rgba(251, 191, 36, 0.35);
	color: #fde68a;
}

[data-emotta-theme="light"] .emotta-legal__admin-note {
	color: #92400e;
	background: rgba(251, 191, 36, 0.2);
}
