/* Radar du Chineur — front-end app styles.
 * Everything is scoped under .rdc and reset defensively so the theme cannot leak in.
 * Layout adapts to the width of the content column (container queries), not the viewport.
 */

.rdc {
	--rdc-ink: #1c2a28;
	--rdc-muted: #5d6b68;
	--rdc-line: #e6dfd3;
	--rdc-line-strong: #d6cdbd;
	--rdc-bg: #f6f1e8;
	--rdc-surface: #ffffff;
	--rdc-brand: #0f6b62;
	--rdc-brand-600: #0b564f;
	--rdc-brand-50: #e4f2ee;
	--rdc-accent: #d9652e;
	--rdc-accent-50: #fbeadf;
	--rdc-accent-ink: #9a4211;
	--rdc-radius: 16px;
	--rdc-shadow: 0 1px 2px rgba(28, 42, 40, .06), 0 4px 14px rgba(28, 42, 40, .06);

	container: rdc / inline-size;
	position: relative;
	color: var(--rdc-ink);
	font-size: 16px;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
	margin: 0 0 2em;
}

.rdc *, .rdc *::before, .rdc *::after { box-sizing: border-box; }

/* Defensive resets against theme styles. */
.rdc button,
.rdc input,
.rdc select {
	font: inherit;
	color: inherit;
	letter-spacing: normal;
	text-transform: none;
	text-shadow: none;
	box-shadow: none;
	margin: 0;
	min-height: 0;
	width: auto;
	line-height: 1.2;
}
.rdc button {
	-webkit-appearance: none;
	appearance: none;
	background: none;
	border: 0;
	border-radius: 0;
	padding: 0;
	cursor: pointer;
	text-align: inherit;
}
.rdc h2, .rdc h3, .rdc p, .rdc dl, .rdc dd, .rdc ul {
	margin: 0;
	padding: 0;
	letter-spacing: normal;
	text-transform: none;
	border: 0;
	background: none;
}
.rdc h2, .rdc h3 { font-family: inherit; }
.rdc h2::before, .rdc h2::after, .rdc h3::before, .rdc h3::after { content: none; display: none; }
.rdc ul { list-style: none; }
.rdc a { color: var(--rdc-brand); text-decoration: none; box-shadow: none; border: 0; }
.rdc a:hover { text-decoration: underline; }
.rdc [hidden] { display: none !important; }
.rdc button:focus:not(:focus-visible), .rdc a:focus:not(:focus-visible) { outline: none; }
.rdc :focus-visible { outline: 2px solid var(--rdc-brand); outline-offset: 2px; border-radius: 8px; }
.rdc .rdc-ico { flex: none; display: block; }

/* ---------- Search panel ---------- */

.rdc-panel {
	position: relative;
	background:
		radial-gradient(circle at 100% 0, rgba(15, 107, 98, .10) 0, rgba(15, 107, 98, 0) 45%),
		radial-gradient(circle at 0 100%, rgba(217, 101, 46, .08) 0, rgba(217, 101, 46, 0) 40%),
		var(--rdc-bg);
	border-radius: 22px;
	padding: 20px 16px 16px;
	margin-bottom: 18px;
}

.rdc-form {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 10px;
}

.rdc-label {
	display: block;
	font-weight: 700;
	font-size: 20px;
	line-height: 1.25;
	letter-spacing: -.01em;
	margin: 0 0 2px;
}

.rdc-field {
	display: flex;
	align-items: center;
	background: var(--rdc-surface);
	border: 1.5px solid var(--rdc-line-strong);
	border-radius: 14px;
	height: 56px;
	padding: 0 6px 0 14px;
	transition: border-color .15s, box-shadow .15s;
}
.rdc-field:focus-within {
	border-color: var(--rdc-brand);
	box-shadow: 0 0 0 4px rgba(15, 107, 98, .14);
}
.rdc-field-ico { color: var(--rdc-muted); margin-right: 8px; }

.rdc .rdc-input {
	flex: 1;
	min-width: 0;
	height: 100%;
	border: 0;
	outline: 0;
	background: transparent;
	padding: 0;
	font-size: 16px; /* ≥16px avoids iOS zoom on focus */
}
.rdc .rdc-input::placeholder { color: #8a9693; opacity: 1; }

.rdc .rdc-go {
	flex: none;
	height: 44px;
	padding: 0 18px;
	border-radius: 10px;
	background: var(--rdc-brand);
	color: #fff;
	font-weight: 600;
	transition: background .15s;
}
.rdc .rdc-go:hover { background: var(--rdc-brand-600); }

.rdc .rdc-geo {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 48px;
	padding: 0 16px;
	border-radius: 12px;
	border: 1.5px solid var(--rdc-brand);
	color: var(--rdc-brand);
	background: var(--rdc-surface);
	font-weight: 600;
	white-space: nowrap;
	transition: background .15s, color .15s;
}
.rdc .rdc-geo:hover { background: var(--rdc-brand-50); }
.rdc .rdc-geo.is-busy .rdc-ico { animation: rdc-spin 1s linear infinite; }

@keyframes rdc-spin { to { transform: rotate(360deg); } }

/* Suggestions */
.rdc .rdc-suggest {
	position: absolute;
	z-index: 30;
	left: 0;
	right: 0;
	top: calc(100% - 52px);
	background: var(--rdc-surface);
	border: 1px solid var(--rdc-line);
	border-radius: 14px;
	box-shadow: 0 12px 32px rgba(28, 42, 40, .16);
	padding: 6px;
	max-height: 320px;
	overflow: auto;
}
.rdc .rdc-opt {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 12px;
	border-radius: 10px;
	cursor: pointer;
	margin: 0;
}
.rdc .rdc-opt small { color: var(--rdc-muted); font-size: 13px; white-space: nowrap; }
.rdc .rdc-opt b { color: var(--rdc-brand); margin-right: 4px; }
.rdc .rdc-opt:hover, .rdc .rdc-opt[aria-selected="true"] { background: var(--rdc-brand-50); }
.rdc .rdc-opt.is-info { cursor: default; color: var(--rdc-muted); font-size: 14px; }
.rdc .rdc-opt.is-info:hover { background: none; }

/* Department chips */
.rdc-chips {
	display: flex;
	gap: 8px;
	margin: 14px -16px 0;
	padding: 2px 16px 4px;
	overflow-x: auto;
	scroll-snap-type: x proximity;
	scrollbar-width: none;
}
.rdc-chips::-webkit-scrollbar { display: none; }
.rdc .rdc-chip {
	flex: none;
	scroll-snap-align: start;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	height: 36px;
	padding: 0 12px;
	border-radius: 999px;
	background: var(--rdc-surface);
	border: 1px solid var(--rdc-line);
	color: var(--rdc-ink);
	font-size: 14px;
	white-space: nowrap;
	transition: border-color .15s, background .15s;
}
.rdc .rdc-chip b { color: var(--rdc-brand); font-weight: 700; }
.rdc .rdc-chip:hover { border-color: var(--rdc-brand); text-decoration: none; }
.rdc .rdc-chip.is-active { background: var(--rdc-brand); border-color: var(--rdc-brand); color: #fff; }
.rdc .rdc-chip.is-active b { color: #fff; }

/* Filters */
.rdc-filters {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-top: 12px;
}
.rdc-seg {
	display: inline-flex;
	background: rgba(28, 42, 40, .06);
	border-radius: 12px;
	padding: 3px;
	max-width: 100%;
	overflow-x: auto;
	scrollbar-width: none;
}
.rdc-seg::-webkit-scrollbar { display: none; }
.rdc .rdc-seg button {
	flex: none;
	padding: 8px 12px;
	border-radius: 9px;
	font-size: 14px;
	font-weight: 500;
	color: var(--rdc-muted);
	white-space: nowrap;
	transition: background .15s, color .15s;
}
.rdc .rdc-seg button:hover { color: var(--rdc-ink); }
.rdc .rdc-seg button[aria-pressed="true"] {
	background: var(--rdc-surface);
	color: var(--rdc-ink);
	font-weight: 600;
	box-shadow: 0 1px 3px rgba(28, 42, 40, .14);
}
.rdc-radius {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	color: var(--rdc-muted);
}
.rdc .rdc-radius select {
	height: 38px;
	padding: 0 30px 0 12px;
	border-radius: 10px;
	border: 1px solid var(--rdc-line-strong);
	background: var(--rdc-surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235d6b68' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
	-webkit-appearance: none;
	appearance: none;
	color: var(--rdc-ink);
	font-size: 14px;
}

/* ---------- Results bar ---------- */

.rdc-bar {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	margin: 0 0 14px;
}
.rdc .rdc-summary { font-size: 15px; color: var(--rdc-muted); }
.rdc .rdc-summary strong { color: var(--rdc-ink); font-weight: 700; }
.rdc-bar::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -8px;
	height: 3px;
	border-radius: 3px;
	background: linear-gradient(90deg, transparent, var(--rdc-brand), transparent);
	background-size: 40% 100%;
	background-repeat: no-repeat;
	opacity: 0;
}
.rdc.is-loading .rdc-bar::after { opacity: 1; animation: rdc-scan 1s ease-in-out infinite; }
@keyframes rdc-scan { from { background-position: -40% 0; } to { background-position: 140% 0; } }

.rdc-views {
	display: inline-flex;
	background: rgba(28, 42, 40, .06);
	border-radius: 12px;
	padding: 3px;
}
.rdc .rdc-views button {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 7px 12px;
	border-radius: 9px;
	font-size: 14px;
	font-weight: 500;
	color: var(--rdc-muted);
}
.rdc .rdc-views button .rdc-ico { width: 16px; height: 16px; }
.rdc .rdc-views button[aria-selected="true"] { background: var(--rdc-surface); color: var(--rdc-ink); font-weight: 600; box-shadow: 0 1px 3px rgba(28, 42, 40, .14); }

/* ---------- List ---------- */

.rdc-body { display: block; }
.rdc-body.has-map[data-view="list"] .rdc-mapwrap { display: none; }
.rdc-body.has-map[data-view="map"] .rdc-list { display: none; }
.rdc-list { transition: opacity .2s; }
.rdc.is-loading .rdc-list { opacity: .45; }

.rdc-day + .rdc-day { margin-top: 22px; }
.rdc .rdc-day-title {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.3;
	margin: 0 0 10px;
	color: var(--rdc-ink);
}
.rdc-day-count {
	display: inline-grid;
	place-items: center;
	min-width: 24px;
	height: 24px;
	padding: 0 7px;
	border-radius: 999px;
	background: var(--rdc-brand-50);
	color: var(--rdc-brand);
	font-size: 13px;
	font-weight: 700;
}

.rdc-card {
	display: grid;
	grid-template-columns: 58px 1fr;
	gap: 14px;
	padding: 14px;
	background: var(--rdc-surface);
	border: 1px solid var(--rdc-line);
	border-radius: var(--rdc-radius);
	box-shadow: var(--rdc-shadow);
	transition: border-color .15s, box-shadow .15s, transform .15s;
	scroll-margin: 90px;
}
.rdc-card + .rdc-card { margin-top: 10px; }
.rdc-card:hover { border-color: var(--rdc-line-strong); }
.rdc-card.is-open { border-color: var(--rdc-brand); }
.rdc-card.is-flash { box-shadow: 0 0 0 4px rgba(217, 101, 46, .3); }

.rdc-card-date {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	align-self: start;
	height: 64px;
	border-radius: 12px;
	background: var(--rdc-bg);
	line-height: 1;
}
.rdc-card-dow { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--rdc-muted); }
.rdc-card-d { font-size: 24px; font-weight: 800; margin: 3px 0 2px; color: var(--rdc-ink); }
.rdc-card-m { font-size: 12px; color: var(--rdc-muted); }

.rdc-card-main { min-width: 0; }
.rdc-card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 13px; color: var(--rdc-muted); }
.rdc-meta-item { white-space: nowrap; }
.rdc-meta-item + .rdc-meta-item { padding-left: 10px !important; border-left: 1px solid var(--rdc-line-strong); line-height: 1.1; }
.rdc-dist { color: var(--rdc-brand); font-weight: 600; }

.rdc-pill {
	display: inline-block;
	padding: 3px 9px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .01em;
}
.rdc-pill--vide-grenier { background: var(--rdc-brand-50); color: var(--rdc-brand-600); }
.rdc-pill--brocante { background: var(--rdc-accent-50); color: var(--rdc-accent-ink); }

.rdc .rdc-card-title { font-size: 17px; font-weight: 700; line-height: 1.3; margin: 6px 0 4px; }
.rdc .rdc-toggle {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 10px;
	width: 100%;
	color: var(--rdc-ink);
	line-height: 1.3;
	overflow-wrap: anywhere;
}
.rdc .rdc-toggle:hover { color: var(--rdc-brand); }
.rdc .rdc-toggle::after {
	content: "";
	display: inline-block;
	width: 7px;
	height: 7px;
	margin-left: 8px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	flex: none;
	transform: translateY(-3px) rotate(45deg);
	opacity: .45;
	transition: transform .2s;
}
.rdc .rdc-toggle[aria-expanded="true"]::after { transform: translateY(0) rotate(225deg); }

.rdc .rdc-card-place { display: flex; align-items: center; gap: 5px; font-size: 14px; color: var(--rdc-muted); }
.rdc .rdc-card-place .rdc-ico { width: 15px; height: 15px; color: var(--rdc-accent); }

.rdc-card-details { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--rdc-line); font-size: 15px; }
.rdc .rdc-desc { margin-bottom: 12px; white-space: pre-line; }
.rdc .rdc-facts { display: grid; gap: 6px; margin-bottom: 14px; }
.rdc .rdc-facts > div { display: grid; grid-template-columns: 90px 1fr; gap: 8px; }
.rdc .rdc-facts dt { color: var(--rdc-muted); font-size: 13px; padding-top: 2px; font-weight: 400; }
.rdc .rdc-facts dd { margin: 0; overflow-wrap: anywhere; }
.rdc-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.rdc .rdc-btn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	height: 40px;
	padding: 0 14px;
	border-radius: 10px;
	border: 1px solid var(--rdc-line-strong);
	background: var(--rdc-surface);
	color: var(--rdc-ink);
	font-size: 14px;
	font-weight: 600;
	white-space: nowrap;
	transition: background .15s, border-color .15s;
}
.rdc .rdc-btn:hover { background: var(--rdc-bg); text-decoration: none; }
.rdc .rdc-btn .rdc-ico { width: 16px; height: 16px; }
.rdc .rdc-btn--primary { background: var(--rdc-brand); border-color: var(--rdc-brand); color: #fff; }
.rdc .rdc-btn--primary:hover { background: var(--rdc-brand-600); color: #fff; }
.rdc .rdc-source { margin-top: 12px; font-size: 12.5px; color: var(--rdc-muted); }

.rdc-empty {
	text-align: center;
	padding: 36px 20px;
	border: 1.5px dashed var(--rdc-line-strong);
	border-radius: var(--rdc-radius);
	color: var(--rdc-muted);
}
.rdc .rdc-empty-title { font-size: 18px; font-weight: 700; color: var(--rdc-ink); margin-bottom: 6px; }
.rdc-empty .rdc-btn { margin-top: 14px; }

/* ---------- Map ---------- */

.rdc-mapwrap { position: relative; }
.rdc-map {
	height: 70vh;
	min-height: 360px;
	max-height: 640px;
	border-radius: var(--rdc-radius);
	border: 1px solid var(--rdc-line);
	overflow: hidden;
	background: #eef0ec;
	z-index: 0;
}
.rdc .leaflet-container { font: inherit; font-size: 13px; }
.rdc .leaflet-container a { color: var(--rdc-brand); }
.rdc .leaflet-popup-content { margin: 12px 14px; line-height: 1.4; }
.rdc .leaflet-popup-content hr { border: 0; border-top: 1px solid var(--rdc-line); margin: 8px 0; }
.rdc .rdc-pop span { color: var(--rdc-muted); }
.rdc .rdc-pop-btn { margin-top: 6px; color: var(--rdc-brand); font-weight: 700; font-size: 13px; }

.rdc-marker { background: none; border: 0; }
.rdc-marker span {
	display: grid;
	place-items: center;
	width: 30px;
	height: 30px;
	border-radius: 50% 50% 50% 0;
	transform: rotate(-45deg);
	background: var(--rdc-brand);
	border: 2.5px solid #fff;
	box-shadow: 0 2px 6px rgba(0, 0, 0, .3);
	color: #fff;
	font-size: 12px;
	font-weight: 800;
}
.rdc-marker--brocante span { background: var(--rdc-accent); }
.rdc-marker span:empty::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #fff; }
.rdc-marker span:not(:empty) { font-feature-settings: "tnum"; }
.rdc-marker span > * , .rdc-marker span { line-height: 1; }

/* ---------- Footer, toast ---------- */

.rdc .rdc-credit { margin-top: 18px; font-size: 12.5px; color: var(--rdc-muted); }

.rdc-toast {
	position: fixed;
	z-index: 99999;
	left: 50%;
	bottom: 24px;
	transform: translate(-50%, 20px);
	max-width: min(92vw, 460px);
	padding: 12px 16px;
	border-radius: 12px;
	background: var(--rdc-ink);
	color: #fff;
	font-size: 14px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
	opacity: 0;
	pointer-events: none;
	transition: opacity .2s, transform .2s;
}
.rdc-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Wider containers ---------- */

@container rdc (min-width: 560px) {
	.rdc-panel { padding: 24px 22px 18px; }
	.rdc-chips { flex-wrap: wrap; overflow: visible; margin: 16px 0 0; padding: 0; }
}

@container rdc (min-width: 680px) {
	.rdc-form { grid-template-columns: minmax(0, 1fr) auto; align-items: end; column-gap: 10px; }
	.rdc-label { grid-column: 1 / -1; font-size: 22px; }
	.rdc .rdc-geo { height: 56px; }
	.rdc .rdc-suggest { top: calc(100% + 6px); right: auto; width: calc(100% - 170px); min-width: 320px; }
}

@container rdc (max-width: 679px) {
	.rdc .rdc-suggest { top: 96px; }
	.rdc .rdc-geo { width: 100%; }
}

@container rdc (max-width: 559px) {
	.rdc .rdc-go { padding: 0 14px; }
	.rdc-filters { flex-direction: column; align-items: stretch; }
	.rdc-seg { display: flex; }
	.rdc .rdc-seg button { flex: 1 1 auto; text-align: center; padding: 8px 6px; font-size: 13.5px; }
	.rdc-actions { display: grid; grid-template-columns: 1fr 1fr; }
	.rdc-actions .rdc-btn { justify-content: center; }
	.rdc-actions .rdc-btn--primary { grid-column: 1 / -1; }
	.rdc .rdc-long { display: none; }
	.rdc-card { grid-template-columns: 50px 1fr; gap: 12px; padding: 12px; }
	.rdc-card-date { height: 58px; }
	.rdc-card-d { font-size: 21px; }
	.rdc .rdc-facts > div { grid-template-columns: 1fr; gap: 0; }
}

@container rdc (min-width: 900px) {
	.rdc-views { display: none; }
	.rdc-body.has-map { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .85fr); gap: 20px; align-items: start; }
	.rdc-body.has-map[data-view] .rdc-list,
	.rdc-body.has-map[data-view] .rdc-mapwrap { display: block; }
	.rdc-mapwrap { position: sticky; top: 16px; }
	.rdc-map { height: calc(100vh - 32px); }
}

@media (prefers-reduced-motion: reduce) {
	.rdc *, .rdc *::before, .rdc *::after { animation: none !important; transition: none !important; }
}

.rdc .rdc-short { display: none; }
@container rdc (max-width: 559px) { .rdc .rdc-short { display: inline; } }

/* ---------- Theme-proofing ----------
 * Some themes (Pixwell included) add margins/padding to p, h2, h3, article inside post content
 * with selectors stronger than ours. These spacings are part of the design, so they are locked. */
.rdc p, .rdc h2, .rdc h3, .rdc dl, .rdc dd, .rdc dt, .rdc ul, .rdc li, .rdc article { padding: 0 !important; }
.rdc .rdc-summary, .rdc .rdc-card-place, .rdc .rdc-card-meta, .rdc dd, .rdc .rdc-empty p, .rdc .rdc-opt, .rdc .rdc-suggest { margin: 0 !important; }
.rdc .rdc-card { margin: 0 !important; padding: 14px !important; }
.rdc .rdc-card + .rdc-card { margin-top: 10px !important; }
.rdc .rdc-day { margin: 0 !important; }
.rdc .rdc-day + .rdc-day { margin-top: 22px !important; }
.rdc .rdc-day-title { margin: 0 0 10px !important; }
.rdc .rdc-card-title { margin: 6px 0 4px !important; }
.rdc .rdc-desc { margin: 0 0 12px !important; }
.rdc .rdc-facts { margin: 0 0 14px !important; }
.rdc .rdc-source { margin: 12px 0 0 !important; }
.rdc .rdc-empty-title { margin: 0 0 6px !important; }
.rdc .rdc-credit { margin: 18px 0 0 !important; }
.rdc .rdc-card-details { margin: 12px 0 0 !important; }
@container rdc (max-width: 559px) {
	.rdc .rdc-card { padding: 12px !important; }
}
.rdc .rdc-opt { padding: 10px 12px !important; }
.rdc .rdc-card-details { padding-top: 12px !important; }
