/* ==========================================================================
   Apimo Sync — Styles front & admin
   Uses Kadence CSS variables with fallbacks
   ========================================================================== */

/* Variables (overridden by Kadence palette via PHP injection) */
:root {
	--apimo-primary:    var(--apimo-palette1, var(--global-palette1, #1e73be));
	--apimo-secondary:  var(--apimo-palette2, var(--global-palette2, #2c3e50));
	--apimo-accent:     var(--apimo-palette3, var(--global-palette3, #e74c3c));
	--apimo-light:      var(--apimo-palette8, var(--global-palette8, #f5f5f5));
	--apimo-dark:       var(--apimo-palette9, var(--global-palette9, #111111));
	--apimo-text:       var(--global-palette4, #333333);
	--apimo-muted:      var(--global-palette5, #777777);
	--apimo-border:     var(--global-palette6, #e0e0e0);
	--apimo-radius:     6px;
	--apimo-shadow:     0 2px 12px rgba(0,0,0,.08);
	--apimo-transition: 0.2s ease;
	--apimo-font:       var(--global-font-family, inherit);
}

/* ==========================================================================
   Grid / Listings
   ========================================================================== */

.apimo-listings {
	container-type: inline-size;
	font-family: var(--apimo-font);
}

.apimo-grid {
	display: grid;
	gap: 24px;
	grid-template-columns: repeat(1, 1fr);
}

.apimo-cols-2 .apimo-grid { grid-template-columns: repeat(2, 1fr); }
.apimo-cols-3 .apimo-grid { grid-template-columns: repeat(3, 1fr); }
.apimo-cols-4 .apimo-grid { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
	.apimo-cols-4 .apimo-grid { grid-template-columns: repeat(2, 1fr); }
	.apimo-cols-3 .apimo-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
	.apimo-cols-2 .apimo-grid,
	.apimo-cols-3 .apimo-grid,
	.apimo-cols-4 .apimo-grid {
		grid-template-columns: 1fr;
	}
}

/* ==========================================================================
   Card
   ========================================================================== */

.apimo-card {
	background: #fff;
	border-radius: var(--apimo-radius);
	box-shadow: var(--apimo-shadow);
	overflow: hidden;
	transition: transform var(--apimo-transition), box-shadow var(--apimo-transition);
	position: relative;
}

.apimo-card:hover {
	transform: translateY(-3px);
	box-shadow: 0 6px 24px rgba(0,0,0,.13);
}

.apimo-card-link {
	display: block;
	color: inherit;
	text-decoration: none;
}

/* Card image */
.apimo-card-image {
	position: relative;
	aspect-ratio: 16/10;
	overflow: hidden;
	background: var(--apimo-light);
}

.apimo-card-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.apimo-card:hover .apimo-card-image img {
	transform: scale(1.04);
}

.apimo-card-no-image {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: var(--apimo-muted);
}

.apimo-card-no-image .dashicons {
	font-size: 48px;
	width: 48px;
	height: 48px;
}

/* Badge */
.apimo-badge {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 4px 10px;
	border-radius: 3px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .4px;
	text-transform: uppercase;
	line-height: 1.4;
	z-index: 2;
}

.apimo-badge.statut-dispo   { background: #27ae60; color: #fff; }
.apimo-badge.statut-vendu   { background: var(--apimo-accent); color: #fff; }
.apimo-badge.statut-retire  { background: var(--apimo-muted);  color: #fff; }

/* Card body */
.apimo-card-body {
	padding: 16px 18px 20px;
}

.apimo-card-title {
	font-size: 1rem;
	font-weight: 600;
	margin: 0 0 6px;
	color: var(--apimo-secondary);
	line-height: 1.3;
}

.apimo-card-ville {
	display: flex;
	align-items: center;
	gap: 4px;
	font-size: .85rem;
	color: var(--apimo-muted);
	margin: 0 0 10px;
}

.apimo-card-ville .dashicons {
	font-size: 14px;
	width: 14px;
	height: 14px;
}

.apimo-card-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 10px;
}

.apimo-card-meta span {
	background: var(--apimo-light);
	padding: 3px 9px;
	border-radius: 3px;
	font-size: .82rem;
	color: var(--apimo-text);
	font-weight: 500;
}

.apimo-meta-prix {
	color: var(--apimo-primary) !important;
	font-weight: 700 !important;
	background: transparent !important;
	padding: 0 !important;
	font-size: 1.05rem !important;
}

.apimo-card-desc {
	font-size: .83rem;
	color: var(--apimo-muted);
	margin: 0;
	line-height: 1.5;
}

.apimo-no-results {
	text-align: center;
	padding: 40px;
	color: var(--apimo-muted);
	font-style: italic;
}

/* ==========================================================================
   Search bar
   ========================================================================== */

.apimo-search-bar {
	background: var(--apimo-light);
	padding: 20px 24px;
	border-radius: var(--apimo-radius);
	margin-bottom: 30px;
}

.apimo-search-form { display: block; }

.apimo-search-fields {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 12px;
	margin-bottom: 14px;
}

.apimo-field {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.apimo-field label {
	font-size: .78rem;
	font-weight: 600;
	color: var(--apimo-muted);
	text-transform: uppercase;
	letter-spacing: .5px;
}

.apimo-select,
.apimo-input {
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--apimo-border);
	border-radius: var(--apimo-radius);
	font-size: .9rem;
	color: var(--apimo-text);
	background: #fff;
	width: 100%;
	box-sizing: border-box;
	transition: border-color var(--apimo-transition);
}

.apimo-select:focus,
.apimo-input:focus {
	outline: none;
	border-color: var(--apimo-primary);
}

.apimo-search-btn {
	background: var(--apimo-primary);
	color: #fff;
	border: none;
	padding: 10px 24px;
	border-radius: var(--apimo-radius);
	cursor: pointer;
	font-size: .95rem;
	font-weight: 600;
	transition: background var(--apimo-transition);
}

.apimo-search-btn:hover {
	background: var(--apimo-secondary);
}

/* ==========================================================================
   Single property (detail page)
   ========================================================================== */

.apimo-single-wrap {
	max-width: 1100px;
	margin: 0 auto;
	padding: 0 20px;
}

.apimo-gallery {
	display: grid;
	grid-template-columns: 2fr 1fr;
	gap: 8px;
	margin-bottom: 32px;
}

.apimo-gallery-main {
	border-radius: var(--apimo-radius);
	overflow: hidden;
	aspect-ratio: 4/3;
}

.apimo-gallery-main img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.apimo-gallery-thumbs {
	display: grid;
	grid-template-rows: repeat(2, 1fr);
	gap: 8px;
}

.apimo-gallery-thumbs img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: var(--apimo-radius);
}

.apimo-info-bar {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	background: var(--apimo-light);
	padding: 20px 24px;
	border-radius: var(--apimo-radius);
	margin-bottom: 28px;
}

.apimo-info-item {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.apimo-info-label {
	font-size: .75rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .5px;
	color: var(--apimo-muted);
}

.apimo-info-value {
	font-size: 1.15rem;
	font-weight: 700;
	color: var(--apimo-secondary);
}

.apimo-info-item.prix .apimo-info-value {
	color: var(--apimo-primary);
	font-size: 1.5rem;
}

/* Progress bar (score) */
.apimo-score-wrap {
	margin: 24px 0;
}

.apimo-progress-bar-wrap {
	background: var(--apimo-border);
	border-radius: 999px;
	height: 10px;
	overflow: hidden;
	margin-top: 6px;
}

.apimo-progress-bar {
	height: 100%;
	background: linear-gradient(90deg, var(--apimo-primary), var(--apimo-accent));
	border-radius: 999px;
	transition: width 0.4s ease;
}

/* DPE */
.apimo-dpe {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 3px;
	font-weight: 700;
	font-size: .85rem;
}

.apimo-dpe-A { background: #1a9641; color: #fff; }
.apimo-dpe-B { background: #52b747; color: #fff; }
.apimo-dpe-C { background: #8fc33a; color: #fff; }
.apimo-dpe-D { background: #ffff00; color: #333; }
.apimo-dpe-E { background: #fec001; color: #333; }
.apimo-dpe-F { background: #f77f00; color: #fff; }
.apimo-dpe-G { background: #e0201d; color: #fff; }

/* ==========================================================================
   Admin — Navigation tabs
   ========================================================================== */

.apimo-admin-wrap { max-width: 1100px; }

.apimo-admin-tabs { margin-top: 0; }

/* Nav bar */
.apimo-nav-tabs {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 0;
	background: #fff;
	border-bottom: 2px solid #e5e5e5;
	padding: 0 4px;
	margin-bottom: 0;
}

.apimo-nav-tab {
	display: inline-block;
	padding: 14px 20px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.8px;
	text-transform: uppercase;
	color: #555;
	text-decoration: none;
	background: transparent;
	border: none;
	border-bottom: 3px solid transparent;
	margin-bottom: -2px;
	transition: color 0.15s, border-color 0.15s;
	white-space: nowrap;
}

.apimo-nav-tab:hover {
	color: #1d2327;
	text-decoration: none;
}

.apimo-nav-tab-active {
	color: #1d2327;
	border-bottom: 3px solid #1d2327;
	font-weight: 800;
}

/* Gear icon in nav */
.apimo-nav-gear {
	margin-left: auto;
	display: flex;
	align-items: center;
	padding: 10px 8px;
	color: #555;
	font-size: 20px;
	text-decoration: none;
	transition: color 0.15s, transform 0.3s;
}

.apimo-nav-gear:hover {
	color: #1d2327;
	transform: rotate(45deg);
	text-decoration: none;
}

.apimo-tab-content { padding: 28px 0; }

#apimo-test-result.success { color: #27ae60; font-weight: 600; }
#apimo-test-result.error   { color: #e74c3c; font-weight: 600; }

/* Admin progress bar */
.apimo-progress-bar-wrap {
	background: #e0e0e0;
	border-radius: 999px;
	height: 12px;
	overflow: hidden;
	max-width: 500px;
}

#apimo-progress-fill {
	width: 0%;
	height: 100%;
	background: var(--apimo-primary, #1e73be);
	transition: width 0.4s ease;
}

/* ==========================================================================
   Admin — Dashboard
   ========================================================================== */

.apimo-dashboard-hero {
	background: #ebebeb;
	border-radius: 18px;
	padding: 28px 32px 32px;
	margin-bottom: 24px;
}

.apimo-hero-date {
	font-size: 12px;
	font-weight: 600;
	color: #555;
	margin-bottom: 6px;
	letter-spacing: 0.3px;
}

.apimo-hero-title {
	font-size: 22px;
	font-weight: 700;
	margin: 0 0 24px;
	color: #1d2327;
	letter-spacing: 0;
	text-transform: none;
}

.apimo-hero-title span {
	color: #7c3aed;
}

.apimo-hero-subtitle { display: none; }

.apimo-stat-cards {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 14px;
}

@media (max-width: 900px) {
	.apimo-stat-cards { grid-template-columns: repeat(2, 1fr); }
}

.apimo-stat-card {
	background: #fff;
	border-radius: 12px;
	padding: 22px 20px 20px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
}

.apimo-stat-label {
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 1px;
	color: #1d2327;
	text-transform: uppercase;
	text-align: center;
}

.apimo-stat-value {
	font-size: 36px;
	font-weight: 800;
	color: #7c3aed;
	line-height: 1;
}

.apimo-stat-purple,
.apimo-stat-red,
.apimo-stat-green { color: #7c3aed; }

/* ==========================================================================
   Admin — Sections
   ========================================================================== */

.apimo-settings-section {
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	padding: 28px 32px;
	margin-bottom: 20px;
}

.apimo-section-title {
	font-size: 16px;
	font-weight: 600;
	color: #2271b1;
	margin: 0 0 20px;
	padding-bottom: 12px;
	border-bottom: 1px solid #dcdcde;
}

.apimo-section-header {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 20px;
	padding-bottom: 12px;
	border-bottom: 1px solid #dcdcde;
}

.apimo-section-header h2 {
	font-size: 15px;
	font-weight: 600;
	margin: 0;
}

.apimo-section-number {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	background: #27ae60;
	color: #fff;
	border-radius: 50%;
	font-size: 13px;
	font-weight: 700;
	flex-shrink: 0;
}

/* ==========================================================================
   Admin — Paramètres généraux grid
   ========================================================================== */

.apimo-settings-grid-3 {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 24px;
}

@media (max-width: 1000px) {
	.apimo-settings-grid-3 { grid-template-columns: 1fr; }
}

.apimo-settings-block {
	padding: 20px;
	background: #f9f9f9;
	border: 1px solid #dcdcde;
	border-radius: 4px;
}

.apimo-settings-block h3 {
	font-size: 13px;
	font-weight: 700;
	color: #1d2327;
	margin: 0 0 8px;
}

.apimo-block-desc {
	font-size: 12px;
	color: #646970;
	margin: 0 0 14px;
	line-height: 1.5;
}

.apimo-field-row {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.apimo-field-group {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.apimo-field-group label {
	font-size: 12px;
	color: #646970;
}

.apimo-color-row {
	display: flex;
	gap: 24px;
}

.apimo-color-group {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.apimo-color-group strong {
	font-size: 13px;
}

.apimo-color-group label {
	font-size: 12px;
	color: #646970;
	font-style: italic;
}

.apimo-color-group input[type="color"] {
	width: 48px;
	height: 32px;
	border: 1px solid #dcdcde;
	border-radius: 3px;
	cursor: pointer;
	padding: 2px;
}

.apimo-container-row {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 8px;
}

.apimo-unit-label {
	font-size: 13px;
	color: #646970;
	background: #f0f0f1;
	padding: 4px 10px;
	border: 1px solid #dcdcde;
	border-radius: 3px;
}

/* ==========================================================================
   Admin — Disposition (card layout)
   ========================================================================== */

.apimo-layout-choice {
	display: flex;
	gap: 24px;
	flex-wrap: wrap;
}

.apimo-layout-option {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	cursor: pointer;
}

.apimo-layout-option input[type="radio"] {
	display: none;
}

.apimo-layout-option span {
	font-size: 13px;
	font-weight: 600;
	color: #50575e;
}

.apimo-layout-preview {
	border: 2px solid #dcdcde;
	border-radius: 4px;
	background: #f0f0f1;
	padding: 10px;
	transition: border-color 0.15s;
}

.apimo-layout-active .apimo-layout-preview {
	border-color: #27ae60;
}

/* Paysage preview */
.apimo-layout-landscape {
	display: flex;
	align-items: center;
	gap: 10px;
	width: 140px;
	height: 80px;
}

.apimo-layout-landscape .apimo-lp-img {
	width: 60px;
	height: 100%;
	background: #c8c8c8;
	border-radius: 3px;
	flex-shrink: 0;
}

.apimo-layout-landscape .apimo-lp-lines {
	display: flex;
	flex-direction: column;
	gap: 6px;
	flex: 1;
}

/* Portrait preview */
.apimo-layout-portrait {
	display: flex;
	flex-direction: column;
	gap: 8px;
	width: 90px;
	height: 100px;
	padding: 8px;
}

.apimo-layout-portrait .apimo-lp-img {
	width: 100%;
	height: 50px;
	background: #c8c8c8;
	border-radius: 3px;
}

.apimo-layout-portrait .apimo-lp-lines {
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.apimo-lp-lines span {
	display: block;
	height: 6px;
	background: #c8c8c8;
	border-radius: 2px;
}

.apimo-lp-lines span:nth-child(2) { width: 70%; }
.apimo-lp-lines span:nth-child(3) { width: 50%; }

/* Columns grid */
.apimo-cols-grid {
	display: flex;
	gap: 40px;
	flex-wrap: wrap;
}

.apimo-cols-block {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.apimo-cols-block strong {
	font-size: 14px;
	font-weight: 700;
}

.apimo-cols-block label {
	font-size: 12px;
	color: #646970;
	font-style: italic;
}

/* ==========================================================================
   Admin — Filtres
   ========================================================================== */

.apimo-filters-grid {
	display: grid;
	grid-template-columns: 1fr 1fr 1fr;
	gap: 28px;
}

@media (max-width: 900px) {
	.apimo-filters-grid { grid-template-columns: 1fr; }
}

.apimo-filter-col {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.apimo-filter-col > strong {
	font-size: 13px;
	font-weight: 700;
	margin-bottom: 4px;
}

.apimo-checkbox-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	color: #1d2327;
	cursor: pointer;
}

.apimo-checkbox-label input[type="checkbox"] {
	width: 16px;
	height: 16px;
	accent-color: #2271b1;
	flex-shrink: 0;
}

/* Toggle switch */
.apimo-toggle-row {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.apimo-toggle-label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1px;
	color: #50575e;
	text-transform: uppercase;
}

.apimo-toggle {
	position: relative;
	display: inline-block;
	width: 52px;
	height: 28px;
}

.apimo-toggle input { display: none; }

.apimo-toggle-slider {
	position: absolute;
	inset: 0;
	background: #ccc;
	border-radius: 28px;
	cursor: pointer;
	transition: background 0.2s;
}

.apimo-toggle-slider::before {
	content: '';
	position: absolute;
	width: 22px;
	height: 22px;
	left: 3px;
	top: 3px;
	background: #fff;
	border-radius: 50%;
	transition: transform 0.2s;
	box-shadow: 0 1px 3px rgba(0,0,0,.3);
}

.apimo-toggle input:checked + .apimo-toggle-slider {
	background: #2271b1;
}

.apimo-toggle input:checked + .apimo-toggle-slider::before {
	transform: translateX(24px);
}

/* ==========================================================================
   Admin — Options d'affichage
   ========================================================================== */

.apimo-display-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 24px;
}

@media (max-width: 800px) {
	.apimo-display-grid { grid-template-columns: 1fr; }
}

.apimo-display-block {
	padding: 18px 20px;
	background: #f9f9f9;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.apimo-display-block > strong {
	font-size: 13px;
	font-weight: 700;
}

.apimo-meta-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 4px;
}

.apimo-tag-label {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 5px 12px;
	border: 2px solid #dcdcde;
	border-radius: 20px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .5px;
	color: #50575e;
	cursor: pointer;
	transition: border-color 0.15s, color 0.15s;
	background: #fff;
}

.apimo-tag-label input[type="checkbox"] { display: none; }

.apimo-tag-label.apimo-tag-active,
.apimo-tag-label:has(input:checked) {
	border-color: #2271b1;
	color: #2271b1;
	background: #f0f6fc;
}

.apimo-radio-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	color: #1d2327;
	cursor: pointer;
}

.apimo-radio-label input {
	accent-color: #2271b1;
}

/* ==========================================================================
   Admin — Detail style preview
   ========================================================================== */

.apimo-detail-style1 {
	width: 160px;
	height: 110px;
	padding: 12px;
	background: #f0f0f1;
	display: flex;
	align-items: center;
	justify-content: center;
}

.apimo-ds1-top {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	width: 100%;
}

.apimo-ds1-img {
	width: 64px;
	height: 64px;
	background: #c8c8c8;
	border-radius: 3px;
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.apimo-ds1-img::after {
	content: '';
	position: absolute;
	width: 22px;
	height: 18px;
	border: 2px solid #999;
	border-radius: 2px;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
}

.apimo-ds1-lines {
	display: flex;
	flex-direction: column;
	gap: 5px;
	flex: 1;
	padding-top: 4px;
}

.apimo-ds1-lines span {
	display: block;
	height: 6px;
	background: #c8c8c8;
	border-radius: 2px;
	width: 100%;
}

.apimo-ds1-lines .apimo-ds1-long { width: 80%; }

/* ==========================================================================
   Admin — Form Configuration
   ========================================================================== */

.apimo-form-field-card {
	border: 1px solid #dcdcde;
	border-radius: 6px;
	padding: 20px 24px;
	margin-bottom: 16px;
	background: #fff;
	transition: border-color 0.15s, box-shadow 0.15s;
}

.apimo-form-field-card:last-of-type {
	margin-bottom: 0;
}

.apimo-form-field-card:focus-within {
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
}

.apimo-form-field-title {
	font-size: 14px;
	font-weight: 700;
	color: #2271b1;
	margin: 0 0 12px;
	text-transform: capitalize;
	font-variant: small-caps;
	letter-spacing: 0.3px;
}

.apimo-form-field-sep {
	border: none;
	border-top: 1px solid #dcdcde;
	margin: 0 0 16px;
}

.apimo-form-field-body {
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-width: 320px;
}

.apimo-form-field-group {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.apimo-form-field-group label {
	font-size: 12px;
	font-weight: 600;
	color: #1d2327;
}

.apimo-form-input {
	padding: 7px 10px;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	font-size: 13px;
	color: #1d2327;
	background: #fff;
	width: 100%;
	box-sizing: border-box;
	transition: border-color 0.15s;
}

.apimo-form-input:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
}

.apimo-required-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
	cursor: pointer;
	margin-top: 2px;
}

.apimo-required-label input[type="checkbox"] {
	width: 16px;
	height: 16px;
	accent-color: #2271b1;
}

/* ==========================================================================
   Admin — Shortcode entry card
   ========================================================================== */

.apimo-sc-entry-card {
	border: 1px solid #dcdcde;
	border-radius: 4px;
	background: #fff;
	overflow: hidden;
}

.apimo-sc-entry-header {
	padding: 18px 24px;
	border-bottom: 1px solid #dcdcde;
}

.apimo-sc-entry-body {
	padding: 16px 24px;
	border-bottom: 1px solid #dcdcde;
}

.apimo-sc-entry-body p {
	margin: 0;
	font-size: 13px;
	color: #50575e;
}

.apimo-sc-entry-footer {
	padding: 14px 24px;
	background: #f6f7f7;
	display: flex;
	justify-content: flex-end;
}

.apimo-sc-btn-open {
	background: #3b5998 !important;
	border-color: #3b5998 !important;
	color: #fff !important;
}

.apimo-sc-btn-open:hover {
	background: #2d4a80 !important;
	border-color: #2d4a80 !important;
}

/* ==========================================================================
   Admin — Shortcode wizard
   ========================================================================== */

.apimo-sc-wizard {
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	padding: 28px 32px 24px;
}

.apimo-sc-wizard-title {
	font-size: 18px;
	font-weight: 600;
	text-align: center;
	margin: 0 0 16px;
	color: #1d2327;
}

.apimo-sc-wizard-sep {
	border: none;
	border-top: 1px solid #dcdcde;
	margin: 0 0 28px;
}

/* Stepper */
.apimo-stepper {
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 32px;
}

.apimo-stepper-item {
	display: flex;
	align-items: center;
}

.apimo-stepper-dot {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 2px solid #dcdcde;
	background: #f6f7f7;
	color: #646970;
	font-size: 13px;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.apimo-stepper-active .apimo-stepper-dot {
	background: #7cb53e;
	border-color: #7cb53e;
	color: #fff;
}

.apimo-stepper-done .apimo-stepper-dot {
	background: #e8f5e9;
	border-color: #7cb53e;
	color: #7cb53e;
}

.apimo-stepper-line {
	width: 60px;
	height: 2px;
	background: #dcdcde;
	margin: 0 2px;
}

/* Step container */
.apimo-sc-step {
	min-height: 240px;
}

.apimo-sc-step h3 {
	font-size: 16px;
	font-weight: 700;
	text-align: center;
	margin: 0 0 8px;
}

/* Step 1 — property choice */
.apimo-sc-property-choice {
	display: flex;
	gap: 32px;
	justify-content: center;
	margin-top: 20px;
}

.apimo-sc-property-option {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	cursor: pointer;
}

.apimo-sc-property-option input { display: none; }

.apimo-sc-property-option span {
	font-size: 13px;
	color: #50575e;
}

.apimo-sc-prop-icon {
	width: 110px;
	height: 110px;
	border: 2px solid #dcdcde;
	border-radius: 6px;
	background: #f6f7f7;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 14px;
	box-sizing: border-box;
	transition: border-color 0.15s;
}

.apimo-sc-prop-icon svg {
	width: 100%;
	height: 100%;
}

.apimo-sc-prop-active .apimo-sc-prop-icon {
	border-color: #7cb53e;
}

/* Step 2 — toggles */
.apimo-sc-toggles {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
	margin-top: 16px;
}

.apimo-sc-toggle-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
}

.apimo-sc-toggle-name {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1px;
	color: #50575e;
	text-transform: uppercase;
	display: flex;
	align-items: center;
	gap: 6px;
}

.apimo-sc-info {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	background: #2271b1;
	color: #fff;
	border-radius: 3px;
	font-size: 10px;
	font-weight: 700;
	cursor: help;
	font-style: normal;
}

.apimo-sc-limit-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 13px;
}

/* Step 3 — filter method */
.apimo-sc-method-choice {
	display: flex;
	gap: 12px;
	justify-content: center;
	margin-bottom: 20px;
	flex-wrap: wrap;
}

.apimo-sc-method-btn {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
	padding: 10px 20px;
	border: 2px solid #dcdcde;
	border-radius: 4px;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1px;
	color: #50575e;
	cursor: pointer;
	transition: border-color 0.15s, color 0.15s;
	background: #fff;
}

.apimo-sc-method-btn input { display: none; }

.apimo-sc-method-active {
	border-color: #7cb53e;
	color: #7cb53e;
}

/* Filter list */
.apimo-sc-filter-list {
	max-height: 300px;
	overflow-y: auto;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	max-width: 560px;
	margin: 0 auto;
}

.apimo-sc-filter-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 20px;
	background: #f6f7f7;
	border-bottom: 1px solid #dcdcde;
}

.apimo-sc-filter-row:last-child { border-bottom: none; }

.apimo-sc-filter-row span {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 1px;
	color: #50575e;
	text-transform: uppercase;
}

/* Step 4 — display options */
.apimo-sc-display-opts {
	display: flex;
	gap: 40px;
	flex-wrap: wrap;
	margin-bottom: 20px;
}

/* Step 5 — result */
.apimo-sc-result-wrap {
	display: flex;
	align-items: center;
	gap: 12px;
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-radius: 4px;
	padding: 16px 20px;
	margin-top: 16px;
}

.apimo-sc-output {
	flex: 1;
	font-family: monospace;
	font-size: 13px;
	color: #1d2327;
	word-break: break-all;
	background: transparent;
}

.apimo-sc-copy-notice {
	color: #27ae60;
	font-weight: 600;
	font-size: 13px;
	margin-top: 8px;
}

/* ==========================================================================
   Admin — SC Step 1: Type de code court
   ========================================================================== */

.apimo-sc-type-opt {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	text-align: center;
}

.apimo-sc-type-opt input { display: none; }

.apimo-sc-type-opt > span:last-child {
	font-size: 13px;
	color: #50575e;
}

.apimo-sc-type-icon {
	width: 120px;
	height: 100px;
	border: 2px solid #dcdcde;
	border-radius: 6px;
	background: #f6f7f7;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 12px;
	box-sizing: border-box;
	transition: border-color 0.15s;
}

.apimo-sc-type-icon svg { width: 100%; height: 100%; }

.apimo-sc-type-opt.apimo-sc-prop-active .apimo-sc-type-icon {
	border-color: #7cb53e;
}

/* ==========================================================================
   Admin — SC Step 3: PAR BALISES panel
   ========================================================================== */

.apimo-sc-tags-panel { margin-top: 12px; }

.apimo-sc-tags-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 20px;
	max-width: 680px;
	margin: 0 auto;
}

.apimo-sc-tags-label {
	display: block;
	font-size: 12px;
	font-weight: 600;
	color: #1d2327;
	margin-bottom: 6px;
	padding: 8px 12px;
	background: #f6f7f7;
	border: 1px solid #dcdcde;
	border-bottom: none;
	border-radius: 4px 4px 0 0;
}

.apimo-sc-select {
	width: 100%;
	min-height: 180px;
	border: 1px solid #dcdcde;
	border-radius: 0 0 4px 4px;
	font-size: 13px;
	color: #1d2327;
	padding: 4px;
}

.apimo-sc-select option:checked {
	background: #2271b1;
	color: #fff;
}

.apimo-sc-manual-panel {
	margin-top: 12px;
	text-align: center;
}

/* ==========================================================================
   Admin — SC Step 4: Modèle
   ========================================================================== */

.apimo-sc-template-choice {
	display: flex;
	gap: 32px;
	justify-content: center;
	flex-wrap: wrap;
	margin-top: 16px;
}

.apimo-sc-tpl-opt {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	cursor: pointer;
}

.apimo-sc-tpl-opt input { display: none; }

.apimo-sc-tpl-opt > span:last-child {
	font-size: 13px;
	color: #50575e;
}

.apimo-sc-tpl-preview {
	border: 2px solid #dcdcde;
	border-radius: 4px;
	background: #f6f7f7;
	padding: 10px;
	transition: border-color 0.15s;
}

.apimo-sc-tpl-opt.apimo-sc-tpl-active .apimo-sc-tpl-preview {
	border-color: #7cb53e;
}

/* Horizontal template preview */
.apimo-sc-tpl-h {
	display: flex;
	align-items: center;
	gap: 10px;
	width: 160px;
	height: 90px;
}

.apimo-sc-tpl-h .apimo-sc-tpl-img {
	width: 70px;
	height: 70px;
	background: #c8c8c8;
	border-radius: 3px;
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.apimo-sc-tpl-h .apimo-sc-tpl-img::after {
	content: '';
	position: absolute;
	width: 26px;
	height: 20px;
	border: 2px solid #999;
	border-radius: 2px;
}

.apimo-sc-tpl-h .apimo-sc-tpl-lines {
	display: flex;
	flex-direction: column;
	gap: 6px;
	flex: 1;
}

/* Vertical template preview */
.apimo-sc-tpl-v {
	display: flex;
	flex-direction: column;
	gap: 8px;
	width: 110px;
	height: 110px;
	padding: 10px;
}

.apimo-sc-tpl-v .apimo-sc-tpl-img {
	width: 100%;
	height: 55px;
	background: #c8c8c8;
	border-radius: 3px;
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.apimo-sc-tpl-v .apimo-sc-tpl-img::after {
	content: '';
	position: absolute;
	width: 26px;
	height: 20px;
	border: 2px solid #999;
	border-radius: 2px;
}

.apimo-sc-tpl-v .apimo-sc-tpl-lines {
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.apimo-sc-tpl-lines span {
	display: block;
	height: 6px;
	background: #c8c8c8;
	border-radius: 2px;
	width: 100%;
}

.apimo-sc-tpl-lines span:nth-child(2) { width: 75%; }
.apimo-sc-tpl-lines span:nth-child(3) { width: 55%; }

/* ==========================================================================
   Admin — SC Step 5: Vue (Grid / Carousel)
   ========================================================================== */

.apimo-sc-view-choice {
	display: flex;
	gap: 48px;
	justify-content: center;
	flex-wrap: wrap;
	align-items: flex-start;
}

.apimo-sc-view-block {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 16px;
}

.apimo-sc-view-opt {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	cursor: pointer;
}

.apimo-sc-view-opt input { display: none; }

.apimo-sc-view-opt > span:last-child {
	font-size: 13px;
	color: #50575e;
}

.apimo-sc-view-icon {
	width: 120px;
	height: 100px;
	border: 2px solid #dcdcde;
	border-radius: 6px;
	background: #f6f7f7;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 10px;
	box-sizing: border-box;
	transition: border-color 0.15s;
}

.apimo-sc-view-icon svg { width: 100%; height: 100%; }

.apimo-sc-view-opt.apimo-sc-view-active .apimo-sc-view-icon {
	border-color: #7cb53e;
}

.apimo-sc-view-cols {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.apimo-sc-view-cols strong {
	font-size: 13px;
	display: flex;
	align-items: center;
	gap: 6px;
}

.apimo-sc-cols-inline {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.apimo-sc-cols-inline > div {
	display: flex;
	align-items: center;
	gap: 10px;
}

.apimo-sc-cols-inline label {
	font-size: 13px;
	color: #50575e;
	min-width: 60px;
}

/* Navigation */
.apimo-sc-nav {
	display: flex;
	justify-content: center;
	gap: 12px;
	margin-top: 32px;
	padding-top: 20px;
	border-top: 1px solid #dcdcde;
}

.apimo-sc-nav .button-primary {
	background: #3b5998 !important;
	border-color: #3b5998 !important;
	padding: 6px 28px !important;
	height: auto !important;
	font-size: 14px !important;
}

.apimo-sc-nav .button {
	padding: 6px 24px !important;
	height: auto !important;
	font-size: 14px !important;
}

/* Save shortcode wrap (step 6) */
.apimo-sc-save-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 20px;
	flex-wrap: wrap;
}

.apimo-sc-save-wrap .regular-text {
	flex: 1;
	min-width: 200px;
}

/* Shortcode history table */
.apimo-sc-history {
	margin-top: 32px;
	padding-top: 24px;
	border-top: 2px solid #e5e5e5;
}

.apimo-sc-history .apimo-section-title {
	font-size: 16px;
	margin-bottom: 14px;
}

.apimo-sc-history-empty {
	color: #646970;
	font-style: italic;
}

.apimo-sc-history-table {
	margin-top: 12px;
}

.apimo-sc-history-table th {
	font-weight: 700;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.4px;
	color: #50575e;
}

.apimo-sc-hist-code {
	background: #f6f7f7;
	padding: 3px 8px;
	border-radius: 4px;
	font-size: 12px;
	word-break: break-all;
	margin-right: 6px;
}

.apimo-sc-hist-copy {
	vertical-align: middle;
}

.apimo-sc-hist-actions {
	white-space: nowrap;
}

.apimo-sc-hist-actions .button {
	margin-right: 4px;
}

.apimo-sc-hist-name-input {
	width: 100%;
}

