/**
 * Jardin AI Designer — Public CSS
 * Theme-aware, responsive, and performance-optimized.
 *
 * @package JardinAI
 */
:root {
	--jaid-primary: var(--color-primary, #1e7e34);
	--jaid-primary-hover: var(--color-link-hover, #155724);
	--jaid-primary-light: rgba(30, 126, 52, 0.12);
	--jaid-heading-font: var(--font-heading, "Playfair Display", serif);
	--jaid-body-font: var(--font-body, "Inter", sans-serif);
	--jaid-radius: 14px;
	--jaid-radius-sm: 8px;
	--jaid-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
	--jaid-shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.12);
	--jaid-border: #e2e8f0;
	--jaid-bg-card: #ffffff;
	--jaid-accent: #f59e0b;
	--jaid-transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

.jaid-page-wrapper {
	padding-bottom: 4rem;
}

.jaid-container {
	width: 100%;
	max-width: 1240px;
	margin: 0 auto;
	padding: 0 0;
	box-sizing: border-box;
}
.jaid-render-screen {
	max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 3rem;
}
.jaid-render-screen h2{
	font-size:1.6rem;
	margin:0 0 0.5rem;
}

.jaid-action-buttons {
	display:flex;
	justify-content:center;
	gap:1rem;
	flex-wrap:wrap;

}
/* The interactive editor needs room to make precise placements. */
.jaid-app-section .jaid-container {
	max-width: none;
}

/* Hero Section */
.jaid-hero-section {
	padding: 3.5rem 0 2rem;
	text-align: center;
}

.jaid-badge-highlight {
	display: inline-block;
	background: rgba(30, 126, 52, 0.1);
	color: var(--jaid-primary);
	font-weight: 600;
	font-size: 0.875rem;
	padding: 0.35rem 1rem;
	border-radius: 9999px;
	margin-bottom: 1rem;
}

.jaid-main-title {
	font-size: clamp(2rem, 4vw, 3.2rem);
	line-height: 1.2;
	color: var(--color-heading, #1a1a1a);
	margin: 0 auto;
	font-weight: 700;
}

.jaid-subtitle {
	font-size: 1.125rem;
	max-width: 780px;
	margin: 0 auto;
	color: #555;
	line-height: 1.6;
}

/* Step Bar */
.jaid-step-indicator {
	margin: 0 3rem auto;
	display: flex;
	justify-content: space-between;
	align-items: center;
	background: #ffffff;
	border: 1px solid var(--jaid-border);
	border-radius: 50px;
	padding: 0.5rem;
	margin-bottom: 2rem;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.jaid-reset-btn {
	background: rgba(254, 226, 226, 0.8);
	color: #991b1b;
	border: 1px solid #fca5a5;
	border-radius: 999px;
	padding: 0.45rem 1rem;
	font-size: 0.8rem;
	font-weight: 600;
	cursor: pointer;
	transition: all var(--jaid-transition);
	margin-left: 0.5rem;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	white-space: nowrap;
	flex-shrink: 0;
}

.jaid-reset-btn:hover {
	background: #fecaca;
	color: #7f1d1d;
	transform: translateY(-1px);
	box-shadow: 0 3px 10px rgba(239, 68, 68, 0.25);
}

.jaid-step {
	flex: 1;
	text-align: center;
	padding: 0.75rem 1rem;
	font-size: 0.9rem;
	font-weight: 600;
	color: #64748b;
	border-radius: 40px;
	transition: all 0.25s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
}

.jaid-step span {
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: #e2e8f0;
	color: #475569;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-size: 0.8rem;
}

.jaid-step.active {
	background: var(--jaid-primary);
	color: #ffffff;
}

.jaid-step.active span {
	background: rgba(255, 255, 255, 0.25);
	color: #ffffff;
}

.jaid-step.completed {
	color: var(--jaid-primary);
}

.jaid-step.completed span {
	background: var(--jaid-primary);
	color: #ffffff;
}

/* App Main Container */
.jaid-app-root {
	background: var(--jaid-bg-card);
	border-radius: var(--jaid-radius);
	border: 1px solid var(--jaid-border);
	box-shadow: var(--jaid-shadow);
	padding: clamp(1rem, 2vw, 2rem);
	min-height: 500px;
	position: relative;
}

@media (min-width: 1400px) {
	.jaid-app-root  {
		    margin: 2.5%;
	}
}

/* Upload Panel */
.jaid-upload-box {
	border: 2px dashed #cbd5e1;
	border-radius: var(--jaid-radius);
	padding: 4rem 2rem;
	text-align: center;
	background: #f8fafc;
	cursor: pointer;
	transition: all 0.3s ease;
}

.jaid-upload-box:hover,
.jaid-upload-box.dragover {
	border-color: var(--jaid-primary);
	background: rgba(30, 126, 52, 0.03);
}

.jaid-upload-icon {
	font-size: 3.5rem;
	margin-bottom: 1rem;
}

.jaid-btn {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.75rem 1.5rem;
	font-size: 0.95rem;
	font-weight: 600;
	line-height: 1;
	border-radius: 999px;
	cursor: pointer;
	border: none;
	text-decoration: none;
	transition: all var(--jaid-transition);
	text-align: center;
	white-space: nowrap;
	letter-spacing: 0.01em;
}

.jaid-btn-primary {
	background: linear-gradient(135deg, #22c55e 0%, #16a34a 50%, #15803d 100%);
	color: #ffffff;
	box-shadow: 0 4px 15px rgba(22, 163, 74, 0.4), 0 1px 3px rgba(0, 0, 0, 0.1);
}

.jaid-btn-primary:hover {
	background: linear-gradient(135deg, #16a34a 0%, #15803d 50%, #166534 100%);
	color: #ffffff;
	transform: translateY(-2px);
	box-shadow: 0 8px 25px rgba(22, 163, 74, 0.5), 0 2px 6px rgba(0, 0, 0, 0.1);
}

.jaid-btn-primary:active {
	transform: translateY(0);
	box-shadow: 0 2px 8px rgba(22, 163, 74, 0.35);
}

.jaid-btn-secondary {
	background: rgba(241, 245, 249, 1);
	color: #334155;
	border: 1px solid #e2e8f0;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.jaid-btn-secondary:hover {
	background: #e2e8f0;
	color: #1e293b;
	transform: translateY(-1px);
	box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08);
}

/* Bouton Sauvegarder spécial — taille CTA */
.jaid-btn-save {
	padding: 0.7rem 1.4rem;
	font-size: 0.9rem;
	border-radius: 999px;
	gap: 0.5rem;
	box-shadow: 0 4px 20px rgba(22, 163, 74, 0.45), 0 1px 4px rgba(0, 0, 0, 0.1);
	animation: jaid-pulse-green 3s ease-in-out infinite;
}

@keyframes jaid-pulse-green {

	0%,
	100% {
		box-shadow: 0 4px 20px rgba(22, 163, 74, 0.45), 0 1px 4px rgba(0, 0, 0, 0.1);
	}

	50% {
		box-shadow: 0 4px 28px rgba(22, 163, 74, 0.65), 0 2px 8px rgba(0, 0, 0, 0.12);
	}
}

.jaid-btn-save:hover {
	animation: none;
}

/* Workspace Layout (Canvas + Plant Library below) */
.jaid-workspace {
	display: block;
	width: 100%;
}

.jaid-workspace-heading {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 1rem;
	flex-wrap: wrap;
	margin-bottom: .8rem;
}

.jaid-workspace-heading h2 {
	margin: 0 0 .25rem;
	font-size: 1.4rem;
}

.jaid-workspace-heading p {
	margin: 0;
	color: #64748b;
	font-size: .9rem;
}

.jaid-workspace-actions {
	display: flex;
	gap: .5rem;
	flex-wrap: wrap;
}

.jaid-workspace-actions .jaid-btn,
.jaid-canvas-toolbar .jaid-btn {
	padding: .5rem .8rem;
	font-size: .82rem;
}

.jaid-canvas-help {
	margin: 0 0 .8rem;
	padding: .65rem .8rem;
	border: 1px solid #dbeafe;
	border-radius: 8px;
	background: #f8fbff;
	color: #475569;
	font-size: .8rem;
}

.jaid-canvas-help kbd {
	padding: .1rem .3rem;
	border: 1px solid #cbd5e1;
	border-radius: 3px;
	background: #fff;
	font-family: inherit;
}

@media (max-width: 960px) {
	.jaid-workspace {
		grid-template-columns: 1fr;
	}

	.jaid-step-indicator {
		flex-direction: column;
		border-radius: 12px;
	}
}

/* ============================================================
   ÉDITEUR VISUEL — Fabric.js, thème sombre isolé (type "app pro")
   ============================================================ */
.jaid-editor {
	--jed-bg: #161b22;
	--jed-panel: #1f2937;
	--jed-panel-alt: #273444;
	--jed-input: #111827;
	--jed-border: #374151;
	--jed-text: #e2e8f0;
	--jed-text-dim: #94a3b8;
	--jed-accent: #22c55e;
	--jed-accent-glow: rgba(34, 197, 94, 0.25);
	--jed-danger: #f87171;
	--jed-canvas-bg: #0d1117;
	background: var(--jed-bg);
	border-radius: var(--jaid-radius);
	overflow: hidden;
	color: var(--jed-text);
	font-size: 13px;
}

/* ---- TOPBAR (bouton CTA + infos) ---- */
.jaid-editor-topbar {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 0.75rem 1rem 0.75rem 0.75rem;
	background: linear-gradient(90deg, #1f2937 0%, #1a2433 100%);
	border-bottom: 1px solid var(--jed-border);
	position: relative;
	z-index: 2;
}

.jaid-editor-topbar::before {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 1px;
	background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.3), transparent);
}

.jaid-editor-topbar-info {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	flex-shrink: 0;
}

.jaid-editor-topbar-step {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	background: rgba(34, 197, 94, 0.15);
	color: #4ade80;
	border: 1px solid rgba(34, 197, 94, 0.3);
	border-radius: 999px;
	padding: 0.25rem 0.75rem;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.jaid-editor-topbar-title {
	color: var(--jed-text);
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: 0.01em;
}

.jaid-editor-topbar-hints {
	display: flex;
	align-items: center;
	gap: 1rem;
	margin-left: auto;
	color: var(--jed-text-dim);
	font-size: 0.75rem;
}

.jaid-editor-topbar-hints kbd {
	padding: 0.1rem 0.4rem;
	border: 1px solid #4b5563;
	border-radius: 4px;
	background: var(--jed-input);
	color: var(--jed-text);
	font-family: inherit;
	font-size: 0.7rem;
}

@media (max-width: 768px) {
	.jaid-editor-topbar-hints {
		display: none;
	}

	.jaid-editor-topbar-title {
		display: none;
	}
}

.jaid-editor-body {
	display: flex;
	height: clamp(480px, calc(100vh - 240px), 780px);
	overflow: hidden;
}

/* --- Boîte à outils (gauche) --- */
.jaid-toolbox {
	width: 48px;
	background: var(--jed-panel);
	border-right: 1px solid var(--jed-border);
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 10px 6px;
	gap: 3px;
	flex-shrink: 0;
	overflow-y: auto;
	scrollbar-width: none;
}

.jaid-toolbox::-webkit-scrollbar {
	display: none;
}

.jaid-tool-btn {
	width: 36px;
	height: 36px;
	border: none;
	background: none;
	border-radius: 8px;
	color: var(--jed-text-dim);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	font-size: 15px;
	line-height: 1;
	transition: all var(--jaid-transition);
	position: relative;
}

.jaid-tool-btn svg {
	width: 16px;
	height: 16px;
	stroke: currentColor;
	fill: none;
}

.jaid-tool-btn:hover {
	background: var(--jed-panel-alt);
	color: var(--jed-text);
	transform: scale(1.05);
}

.jaid-tool-btn.active {
	background: var(--jed-accent-glow);
	color: var(--jed-accent);
	border: 1px solid rgba(34, 197, 94, 0.4);
}

.jaid-tool-btn:disabled {
	opacity: .3;
	cursor: default;
}

.jaid-tool-btn:disabled:hover {
	background: none;
	color: var(--jed-text-dim);
	transform: none;
}

.jaid-tool-btn-danger:hover {
	background: rgba(248, 113, 113, .12);
	color: var(--jed-danger);
}

.jaid-zoom-reset-btn {
	font-size: 16px;
}

.jaid-tool-sep {
	width: 28px;
	height: 1px;
	background: var(--jed-border);
	margin: 6px 0;
	opacity: 0.6;
}

/* --- Colonne centrale : barre d'options / canevas / barre d'état --- */
.jaid-workspace-col {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.jaid-optionsbar {
	height: 34px;
	background: var(--jed-panel);
	border-bottom: 1px solid var(--jed-border);
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 0 14px;
	flex-shrink: 0;
	color: var(--jed-text-dim);
	font-size: 12px;
}

.jaid-optionsbar b {
	color: var(--jed-text);
	font-weight: 700;
	font-size: 12px;
}

.jaid-canvas-area {
	flex: 1;
	background: var(--jed-canvas-bg);
	background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.03) 1px, transparent 0);
	background-size: 24px 24px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
	touch-action: none;
	min-height: 0;
}

.jaid-canvas-area canvas {
	max-width: 100%;
	max-height: 100%;
}

.jaid-canvas-area.tool-hand {
	cursor: grab;
}

.jaid-canvas-area.tool-hand:active {
	cursor: grabbing;
}

.jaid-canvas-area.tool-zoom {
	cursor: zoom-in;
}

.jaid-canvas-area.tool-zoom.alt-held {
	cursor: zoom-out;
}

.jaid-statusbar {
	height: 38px;
	background: var(--jed-panel);
	border-top: 1px solid var(--jed-border);
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 0 10px;
	color: var(--jed-text-dim);
	font-size: 11px;
	flex-shrink: 0;
	overflow: hidden;
}

.jaid-statusbar .jaid-tool-btn {
	width: 28px;
	height: 28px;
	font-size: 15px;
	border-radius: 6px;
}

.jaid-statusbar input[type="range"] {
	width: 80px;
}

#jaid-status-layer {
	flex: 1;
	text-align: center;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

#jaid-zoom-label {
	font-size: 11px;
	min-width: 32px;
	text-align: center;
	white-space: nowrap;
}

/* --- Panneau latéral (droite) : Calques / Plantes / Propriétés --- */
.jaid-editor-sidepanel {
	width: 280px;
	min-width: 260px;
	max-width: 280px;
	background: var(--jed-panel);
	border-left: 1px solid var(--jed-border);
	display: flex;
	flex-direction: column;
	flex-shrink: 0;
	overflow: hidden;
}

.jaid-panel-block {
	border-bottom: 1px solid var(--jed-border);
	display: flex;
	flex-direction: column;
	min-height: 0;
	overflow: hidden;
}

.jaid-panel-layers {
	flex: 0 0 auto;
	max-height: 160px;
}

.jaid-panel-plants {
	flex: 1;
	min-height: 0;
}

.jaid-panel-props {
	flex: 0 0 auto;
	max-height: 220px;
	border-bottom: none;
}

.jaid-panel-header {
	height: 30px;
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0 12px;
	font-weight: 700;
	letter-spacing: .06em;
	color: var(--jed-text-dim);
	font-size: 10px;
	text-transform: uppercase;
	background: linear-gradient(90deg, var(--jed-panel-alt) 0%, var(--jed-panel) 100%);
	border-bottom: 1px solid var(--jed-border);
	flex-shrink: 0;
}

.jaid-panel-header svg {
	flex-shrink: 0;
	opacity: 0.7;
}

.jaid-panel-body {
	flex: 1;
	overflow-y: auto;
	overflow-x: hidden;
	scrollbar-width: thin;
	scrollbar-color: var(--jed-border) transparent;
}

.jaid-panel-body::-webkit-scrollbar {
	width: 4px;
}

.jaid-panel-body::-webkit-scrollbar-thumb {
	background: var(--jed-border);
	border-radius: 2px;
}

.jaid-panel-body::-webkit-scrollbar-track {
	background: transparent;
}

.jaid-empty-hint {
	padding: 16px 10px;
	color: var(--jed-text-dim);
	text-align: center;
	line-height: 1.5;
	font-size: 12px;
}

/* Calques */
.jaid-layer-row {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 5px 8px;
	border-bottom: 1px solid #303030;
	cursor: pointer;
}

.jaid-layer-row.selected {
	background: rgba(30, 126, 52, .22);
}

.jaid-layer-row:hover {
	background: rgba(255, 255, 255, .04);
}

.jaid-layer-row.hidden-layer {
	opacity: .45;
}

.jaid-layer-row.locked-layer .jaid-layer-name {
	color: var(--jed-text-dim);
}

.jaid-layer-row.dragging {
	opacity: .35;
}

.jaid-layer-row.drag-over-top {
	box-shadow: inset 0 2px 0 0 var(--jed-accent);
}

.jaid-layer-row.drag-over-bottom {
	box-shadow: inset 0 -2px 0 0 var(--jed-accent);
}

.jaid-layer-thumb {
	width: 26px;
	height: 26px;
	background: #111;
	border: 1px solid var(--jed-border);
	background-size: cover;
	background-position: center;
	border-radius: 2px;
	flex-shrink: 0;
}

.jaid-layer-eye,
.jaid-layer-lock {
	width: 16px;
	flex-shrink: 0;
	cursor: pointer;
	color: var(--jed-text-dim);
	text-align: center;
	font-size: 12px;
}

.jaid-layer-eye:hover,
.jaid-layer-lock:hover {
	color: var(--jed-text);
}

.jaid-layer-name {
	flex: 1;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: var(--jed-text);
	font-size: 12px;
}

.jaid-layer-name[contenteditable="true"] {
	outline: 1px solid var(--jed-accent);
	background: var(--jed-input);
	border-radius: 2px;
	padding: 0 3px;
	white-space: normal;
}

/* Propriétés */
.jaid-props-body {
	padding: 10px 12px;
	box-sizing: border-box;
	width: 100%;
	overflow: hidden;
}

.jaid-prop-row {
	margin-bottom: 10px;
	box-sizing: border-box;
	width: 100%;
	overflow: hidden;
}

.jaid-prop-label {
	display: flex;
	justify-content: space-between;
	align-items: center;
	color: var(--jed-text-dim);
	margin-bottom: 5px;
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	gap: 0.5rem;
}

.jaid-prop-label .val {
	color: var(--jed-accent);
	font-size: 11px;
	font-weight: 700;
	text-transform: none;
	letter-spacing: 0;
	flex-shrink: 0;
}

.jaid-filter-btns {
	display: flex;
	gap: 5px;
	flex-wrap: wrap;
	margin-top: 4px;
}

.jaid-filter-btns button {
	background: var(--jed-panel-alt);
	border: 1px solid var(--jed-border);
	color: var(--jed-text);
	padding: 3px 8px;
	border-radius: 6px;
	cursor: pointer;
	font-size: 10px;
	transition: all var(--jaid-transition);
}

.jaid-filter-btns button:hover {
	border-color: var(--jed-accent);
	color: var(--jed-accent);
}

.jaid-filter-btns button.active {
	background: var(--jed-accent-glow);
	border-color: var(--jed-accent);
	color: var(--jed-accent);
}

.jaid-prop-note {
	margin-top: 6px;
	padding: 0.4rem 0.6rem;
	background: rgba(34, 197, 94, 0.08);
	border: 1px solid rgba(34, 197, 94, 0.2);
	border-radius: 6px;
	font-size: 10px;
	color: #86efac;
	line-height: 1.5;
}

.jaid-editor input[type="range"] {
	-webkit-appearance: none;
	width: 100%;
	height: 3px;
	background: #374151;
	border-radius: 2px;
	outline: none;
	box-sizing: border-box;
}

.jaid-editor input[type="range"]::-webkit-slider-thumb {
	-webkit-appearance: none;
	width: 13px;
	height: 13px;
	background: var(--jed-accent);
	border-radius: 50%;
	cursor: pointer;
	box-shadow: 0 0 6px rgba(34, 197, 94, 0.5);
}

/* ====================================================
   Plantes — rhabillage dark theme + fix overflow
   ==================================================== */
.jaid-panel-plants .jaid-plant-sidebar {
	background: transparent;
	border: none;
	padding: 8px;
	gap: 0.6rem;
	max-height: none;
	box-sizing: border-box;
	width: 100%;
	overflow: hidden;
}

.jaid-panel-plants .jaid-plant-library-header h3 {
	color: var(--jed-text);
	font-size: 0.8rem;
}

.jaid-panel-plants #jaid-plant-count {
	background: rgba(34, 197, 94, 0.15);
	color: #4ade80;
	border: 1px solid rgba(34, 197, 94, 0.25);
}

.jaid-panel-plants .jaid-plant-search {
	gap: 0.5rem;
	width: 100%;
	box-sizing: border-box;
}

.jaid-panel-plants .jaid-plant-search input[type="search"] {
	background: var(--jed-input);
	border-color: var(--jed-border);
	color: var(--jed-text);
	min-width: 0;
	width: 100%;
	box-sizing: border-box;
}

.jaid-panel-plants .jaid-plant-search input[type="search"]::placeholder {
	color: var(--jed-text-dim);
}

.jaid-panel-plants .jaid-btn-secondary {
	background: var(--jed-panel-alt);
	color: var(--jed-text);
	flex-shrink: 0;
	padding: 0.45rem 0.7rem;
	font-size: 0.75rem;
	border-radius: 8px;
}

/* FIX CRITIQUE : Recherche avancée dans 280px — 1 colonne */
.jaid-panel-plants .jaid-advanced-search {
	background: var(--jed-panel-alt);
	border-color: var(--jed-border);
	box-shadow: none;
	grid-template-columns: 1fr;
	/* ← 1 colonne pour éviter l'overflow */
	gap: 0.5rem;
	padding: 0.6rem;
	width: 100%;
	box-sizing: border-box;
	overflow: hidden;
}

.jaid-panel-plants .jaid-advanced-search select,
.jaid-panel-plants .jaid-advanced-search input[type="number"] {
	background: var(--jed-input);
	border-color: var(--jed-border);
	color: var(--jed-text);
	width: 100%;
	box-sizing: border-box;
	max-width: 100%;
}

.jaid-panel-plants .jaid-plant-list {
	grid-template-columns: 1fr;
	max-height: none;
	padding-right: 0;
	width: 100%;
	box-sizing: border-box;
}

.jaid-panel-plants .jaid-plant-card {
	background: var(--jed-panel-alt);
	border-color: var(--jed-border);
	width: 100%;
	box-sizing: border-box;
}

.jaid-panel-plants .jaid-plant-card:hover {
	border-color: var(--jed-accent);
	box-shadow: 0 2px 12px rgba(34, 197, 94, 0.15);
}

.jaid-panel-plants .jaid-plant-card-info h4 {
	color: var(--jed-text);
	font-size: 0.8rem;
}

.jaid-panel-plants .jaid-plant-card-info p {
	color: var(--jed-text-dim);
	font-size: 0.7rem;
}

.jaid-panel-plants .jaid-plant-empty {
	background: var(--jed-panel-alt);
	border-color: var(--jed-border);
	color: var(--jed-text-dim);
}

@media (max-width: 960px) {
	.jaid-editor {
		display: flex;
		flex-direction: column;
	}

	.jaid-editor-topbar {
		flexwrap: wrap;
		gap: 0.5rem;
		padding: 0.6rem 0.75rem;
	}

	.jaid-editor-body {
		flex-direction: column;
		height: auto;
		max-height: none;
	}

	.jaid-toolbox {
		flex-direction: row;
		width: 100%;
		height: 48px;
		border-right: none;
		border-bottom: 1px solid var(--jed-border);
		overflow-x: auto;
		padding: 6px 8px;
	}

	.jaid-tool-sep {
		width: 1px;
		height: 24px;
		margin: 0 4px;
	}

	.jaid-editor-sidepanel {
		width: 100%;
		max-width: none;
		flex-direction: row;
		height: auto;
		max-height: 400px;
	}

	.jaid-panel-layers {
		flex: 0 0 33%;
	}

	.jaid-panel-plants {
		flex: 0 0 34%;
	}

	.jaid-panel-props {
		flex: 0 0 33%;
		border-bottom: none;
	}

	.jaid-canvas-area {
		min-height: 220px;
	}
}

.jaid-plant-sidebar {
	background: #f8fafc;
	border: 1px solid var(--jaid-border);
	border-radius: 8px;
	padding: 1.25rem;
	display: flex;
	flex-direction: column;
	gap: 1rem;
	max-height: none;
}

.jaid-plant-library-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.jaid-plant-library-header h3 {
	margin: 0;
	font-size: 1.15rem;
	color: #1e293b;
	font-weight: 700;
}

#jaid-plant-count {
	font-size: 0.85rem;
	color: var(--jaid-primary);
	font-weight: 600;
	background: rgba(30, 126, 52, 0.1);
	padding: 0.25rem 0.75rem;
	border-radius: 12px;
}

.jaid-plant-search {
	display: flex;
	gap: 0.75rem;
	align-items: center;
}

.jaid-plant-search input[type="search"] {
	flex: 1;
	padding: 0.65rem 0.9rem;
	border: 1px solid #cbd5e1;
	border-radius: 6px;
	font-size: 0.9rem;
	outline: none;
	background: #ffffff;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.jaid-plant-search input[type="search"]:focus {
	border-color: var(--jaid-primary);
	box-shadow: 0 0 0 3px rgba(30, 126, 52, 0.15);
}

.jaid-advanced-search {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 0.75rem;
	align-items: flex-end;
	background: #ffffff;
	padding: 1rem;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.jaid-advanced-search[hidden] {
	display: none;
}

.jaid-advanced-search label {
	display: flex;
	flex-direction: column;
	font-size: 0.8rem;
	font-weight: 600;
	color: #475569;
	gap: 0.35rem;
}

.jaid-advanced-search select,
.jaid-advanced-search input[type="number"] {
	padding: 0.5rem 0.65rem;
	border: 1px solid #cbd5e1;
	border-radius: 6px;
	font-size: 0.85rem;
	background: #ffffff;
	width: 100%;
	box-sizing: border-box;
}

.jaid-advanced-search select:focus,
.jaid-advanced-search input[type="number"]:focus {
	border-color: var(--jaid-primary);
	outline: none;
}

.jaid-plant-list {
	overflow-y: auto;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
	gap: 0.75rem;
	margin-top: 0.5rem;
	max-height: 380px;
	padding-right: 4px;
}

.jaid-plant-empty {
	grid-column: 1 / -1;
	text-align: center;
	padding: 2.5rem 1rem;
	color: #64748b;
	font-size: 0.9rem;
	background: #ffffff;
	border: 1px dashed #cbd5e1;
	border-radius: 8px;
}

.jaid-plant-card {
	background: #ffffff;
	border: 1px solid var(--jaid-border);
	border-radius: 6px;
	padding: 0.75rem;
	display: flex;
	align-items: center;
	gap: 0.75rem;
	cursor: pointer;
	transition: all 0.2s ease;
}

.jaid-plant-card:hover {
	border-color: var(--jaid-primary);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.jaid-plant-card img {
	width: 48px;
	height: 48px;
	border-radius: 6px;
	object-fit: cover;
}

.jaid-plant-card-info h4 {
	margin: 0;
	font-size: 0.9rem;
}

.jaid-plant-card-info p {
	margin: 2px 0 0;
	font-size: 0.75rem;
	color: #64748b;
}

.jaid-compat-badge {
	margin-left: auto;
	background: #dcfce7;
	color: #166534;
	font-size: 11px;
	font-weight: 700;
	padding: 2px 6px;
	border-radius: 4px;
}

.jaid-plant-suggested {
	margin-left: auto;
	color: #d97706;
	font-size: 1rem;
	line-height: 1;
}

/* Comparison / Before-After Slider */
.jaid-comparison-container {
	position: relative;
	width: 100%;
	max-width: 900px;
	margin: 0 auto;
	overflow: hidden;
	border-radius: var(--jaid-radius);
	user-select: none;
}

.jaid-comparison-container img {
	width: 100%;
	display: block;
	pointer-events: none;
}

.jaid-comparison-overlay {
	position: absolute;
	top: 0;
	left: 0;
	bottom: 0;
	overflow: hidden;
	width: 50%;
}

.jaid-comparison-slider {
	position: absolute;
	top: 0;
	bottom: 0;
	left: 50%;
	width: 4px;
	background: #ffffff;
	cursor: ew-resize;
	transform: translateX(-50%);
}

.jaid-comparison-handle {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 40px;
	height: 40px;
	background: #ffffff;
	border-radius: 50%;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	color: #333;
}

/* Loading & Spinners */
.jaid-spinner-wrapper {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 3rem;
	text-align: center;
}

.jaid-spinner {
	width: 48px;
	height: 48px;
	border: 4px solid #e2e8f0;
	border-top-color: var(--jaid-primary);
	border-radius: 50%;
	animation: jaid-spin 0.8s linear infinite;
	margin-bottom: 1rem;
}

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

/* SEO & Benefits Section */
.jaid-botanical-info-section {
	padding: 4rem 0 2rem;
}

.jaid-botanical-info-section h2 {
	text-align: center;
	margin-bottom: 2.5rem;
}

.jaid-benefits-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 2rem;
}

.jaid-benefit-card {
	background: #ffffff;
	border: 1px solid var(--jaid-border);
	border-radius: var(--jaid-radius);
	padding: 2rem;
	box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
}

.jaid-benefit-icon {
	font-size: 2.5rem;
	margin-bottom: 1rem;
}

.jaid-benefit-card h3 {
	margin: 0 0 0.5rem;
	font-size: 1.25rem;
}

.jaid-benefit-card p {
	color: #555;
	line-height: 1.6;
	margin: 0;
}

/* FAQ Section */
.jaid-faq-section {
	padding: 2rem 0;
}

.jaid-faq-section h2 {
	text-align: center;
	margin-bottom: 2rem;
}

.jaid-faq-list {
	max-width: 800px;
	margin: 0 auto;
}

.jaid-faq-item {
	background: #ffffff;
	border: 1px solid var(--jaid-border);
	border-radius: 8px;
	margin-bottom: 1rem;
	padding: 1rem 1.25rem;
}

.jaid-faq-item summary {
	font-weight: 600;
	font-size: 1.05rem;
	cursor: pointer;
}

.jaid-faq-item p {
	margin: 0.75rem 0 0;
	color: #555;
	line-height: 1.6;
}

/* Save project note and feedback */
#jaid-save-note {
	max-width: 600px;
	margin: 0 auto 2rem;
	padding: 1rem;
	border-radius: var(--jaid-radius-sm);
	font-size: 0.9rem;
	text-align: center;
	display: none;
}

#jaid-save-note.is-visible {
	display: block;
}

#jaid-save-note.is-success {
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	color: #166534;
}

#jaid-save-note.is-error {
	background: #fef2f2;
	border: 1px solid #fecaca;
	color: #991b1b;
}

#jaid-save-note #jaid-confirm-save {
	margin-left: 0.5rem;
}

#jaid-save-note #jaid-cancel-save {
	margin-left: 0.5rem;
}