/* Éditeurs uniquement : aucune dépendance au chargement de Tailwind. */
.feature-editor-modal {
  box-sizing: border-box;
  width: 100%;
  padding: 0 !important;
  max-height: 88vh;
  max-height: 88dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #fff;
  border-radius: 24px 24px 0 0;
  box-shadow: 0 24px 80px #0d173040;
}
.feature-editor {
  --feature-accent: #315b92;
  --feature-soft: #edf4fc;
  width: 100%;
  min-width: 0;
  color: #162443;
  font-family: Inter, system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  background: #f6f8fc;
}
.feature-editor--gift { --feature-accent: #8053a1; --feature-soft: #f5effb; }
.feature-editor--poll { --feature-accent: #18786e; --feature-soft: #eaf7f3; }
.feature-editor--announcement { --feature-accent: #8a641b; --feature-soft: #fdf6e5; }
.feature-editor *, .feature-editor *::before, .feature-editor *::after { box-sizing: border-box; }
.feature-editor [hidden] { display: none !important; }
.feature-editor-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 28px;
  border-bottom: 1px solid #e2e7f0;
  background: linear-gradient(125deg, var(--feature-soft), #fff 85%);
}
.feature-editor-header > div { min-width: 0; }
.feature-editor-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  font-size: 27px;
  border: 1px solid #ffffff;
  border-radius: 18px;
  background: #ffffffc9;
  box-shadow: 0 4px 16px #16244308;
}
.feature-editor h2 { margin: 4px 0 7px; font-size: 24px; line-height: 1.25; font-weight: 800; letter-spacing: -.6px; }
.feature-eyebrow { margin: 0; color: var(--feature-accent); font-size: 11px; font-weight: 800; letter-spacing: 1.3px; text-transform: uppercase; overflow-wrap: anywhere; }
.feature-editor .feature-help { display: block; margin: 5px 0 0; font-size: 12px; font-weight: 400; line-height: 1.6; color: #59677c; overflow-wrap: anywhere; }
.feature-section { margin: 20px 24px; padding: 22px; border: 1px solid #e2e7f0; border-radius: 18px; background: #fff; box-shadow: 0 2px 6px #16244303; }
.feature-section h3 { display: flex; align-items: center; gap: 10px; margin: 0 0 8px; font-size: 16px; font-weight: 750; }
.feature-step { display: grid; place-items: center; width: 26px; height: 26px; flex-shrink: 0; border-radius: 9px; color: var(--feature-accent); background: var(--feature-soft); font-size: 12px; }
.feature-field { display: block; margin-top: 16px; font-size: 13px; font-weight: 650; }
.feature-required, .feature-optional { margin-left: 5px; color: #657286; font-size: 10px; font-weight: 500; }
.feature-editor input:not([type="checkbox"]):not([type="file"]), .feature-editor textarea, .feature-editor select {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  margin-top: 7px;
  padding: 11px 13px;
  border: 1px solid #dce2eb;
  border-radius: 11px;
  color: #162443;
  background: #fbfcfe;
  font: inherit;
  font-weight: 400;
  transition: border-color .15s, box-shadow .15s;
}
.feature-editor textarea { resize: vertical; }
.feature-editor input::placeholder, .feature-editor textarea::placeholder { color: #7c8899; }
.feature-editor input:focus, .feature-editor textarea:focus, .feature-editor select:focus { border-color: var(--feature-accent); outline: 2px solid var(--feature-accent); outline-offset: 2px; background: #fff; }
.feature-editor button:focus-visible, .feature-editor summary:focus-visible { outline: 3px solid var(--feature-accent); outline-offset: 3px; }
.feature-editor button {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: 11px;
  background: #162443;
  color: #fff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
  touch-action: manipulation;
  transition: background .15s;
}
.feature-editor button:hover:not(:disabled) { background: #29416a; }
.feature-editor button:disabled, .feature-editor select:disabled { opacity: .55; cursor: not-allowed; }
.feature-shop-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.feature-photo { min-width: 0; margin-top: 16px; }
.feature-photo-preview:empty { display: none; }
.feature-photo-preview img { display: block; width: 100%; max-height: 180px; margin: 0 0 12px; object-fit: contain; border: 1px solid #e2e7f0; border-radius: 12px; background: #f7f9fc; }
.feature-upload { display: block; padding: 16px; border: 1px dashed #afbdd0; border-radius: 13px; background: #f8fafd; cursor: pointer; }
.feature-upload:hover, .feature-upload:focus-within { border-color: var(--feature-accent); background: var(--feature-soft); }
.feature-upload-icon { display: inline-grid; place-items: center; width: 30px; height: 30px; margin-right: 6px; border-radius: 9px; background: #fff; color: var(--feature-accent); font-size: 22px; }
.feature-upload-title { font-size: 12px; font-weight: 650; }
.feature-upload input[type="file"] { display: block; width: 100%; min-height: 44px; margin-top: 12px; color: #59677c; font-size: 12px !important; cursor: pointer; }
.feature-upload input::file-selector-button { min-height: 44px; margin-right: 8px; padding: 9px 12px; border: 1px solid #dce2eb; border-radius: 9px; background: #fff; color: #162443; font-weight: 600; cursor: pointer; }
.feature-editor [data-photo-status][data-error="1"] { color: #b42336; font-weight: 600; }
.feature-check { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 11px 0; font-size: 12px; cursor: pointer; overflow-wrap: anywhere; }
.feature-editor input[type="checkbox"] { width: 18px; height: 18px; flex-shrink: 0; margin: 2px 0 0; accent-color: var(--feature-accent); }
.feature-mode-panel { margin-top: 16px; padding: 0 16px 16px; border-radius: 12px; background: var(--feature-soft); border: 1px solid #16244308; }
.feature-list-heading { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: center; margin: 24px 0 12px; }
.feature-editor h4 { margin: 0; font-size: 13px; font-weight: 750; }
.feature-option-list { display: grid; gap: 12px; margin-bottom: 12px; }
.feature-option { min-width: 0; padding: 16px; border: 1px solid #dfe5ed; border-radius: 13px; background: #fff; }
.feature-option-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.feature-option-number { color: var(--feature-accent); font-size: 11px; font-weight: 750; }
.feature-editor button[data-action="feature-remove-option"], .feature-editor button[data-action="feature-remove-combo"] { padding: 8px 10px; color: #8b4653; background: #fff5f5; font-size: 11px; }
.feature-editor button[data-action="feature-remove-option"]:hover:not(:disabled), .feature-editor button[data-action="feature-remove-combo"]:hover:not(:disabled) { background: #fce7e9; }
.feature-editor button[data-action="feature-add-option"], .feature-editor button[data-action="feature-add-combo"] { border: 1px dashed #afbdd0; background: var(--feature-soft); color: var(--feature-accent); }
.feature-editor button[data-action="feature-add-option"]:hover:not(:disabled), .feature-editor button[data-action="feature-add-combo"]:hover:not(:disabled) { background: #e6edf5; }
.feature-details { margin-top: 10px; }
.feature-details summary { min-height: 44px; padding: 12px 0; color: #59677c; font-size: 12px; cursor: pointer; }
.feature-details-body { padding-top: 1px; border-top: 1px solid #edf0f5; }
.feature-option--poll .feature-field { margin-top: 6px; }
.feature-combo-section { margin-top: 24px; padding-top: 20px; border-top: 1px solid #e2e7f0; }
.feature-combo-section > .feature-help { margin-bottom: 12px; }
.feature-combo fieldset { min-width: 0; margin: 16px 0; padding: 0; border: 0; }
.feature-combo .feature-check { padding: 12px; margin-top: 6px; border: 1px solid #e2e7f0; border-radius: 9px; background: #f8fafd; }
.feature-switch { position: relative; display: flex; gap: 14px; align-items: center; min-height: 64px; margin-top: 16px; cursor: pointer; }
.feature-switch input[type="checkbox"] { position: absolute; left: 0; width: 44px; height: 26px; opacity: 0; }
.feature-switch-track { position: relative; width: 44px; height: 26px; flex-shrink: 0; border-radius: 99px; background: #a6b2c3; transition: background .15s; }
.feature-switch-track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px #0002; transition: transform .15s; }
.feature-switch input:checked + .feature-switch-track { background: var(--feature-accent); }
.feature-switch input:checked + .feature-switch-track::after { transform: translateX(18px); }
.feature-switch input:focus-visible + .feature-switch-track { outline: 3px solid var(--feature-accent); outline-offset: 3px; }
.feature-closed { margin-top: 16px; padding-top: 16px; border-top: 1px solid #edf0f5; }
.feature-lock-note { margin: 16px 24px; padding: 14px; border: 1px solid #ead49d; border-radius: 12px; background: #fff9eb; color: #78561b; font-size: 12px; }
.feature-section .feature-lock-note { margin: 16px 0; }
.feature-editor-footer { position: sticky; bottom: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px calc(16px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid #e2e7f0; background: #fff; box-shadow: 0 -5px 20px #16244308; }
.feature-editor-footer > .feature-help { max-width: 260px; margin: 0; }
.feature-editor-footer > div { display: flex; gap: 8px; flex-shrink: 0; }
.feature-editor button.feature-cancel { border-color: #dce2eb; background: #fff; color: #59677c; }
.feature-editor button.feature-cancel:hover:not(:disabled) { background: #f0f3f8; }
@media (min-width: 640px) {
  .feature-editor-modal { max-width: 48rem; border-radius: 24px; }
}
@media (max-width: 639px) {
  .feature-editor-header { gap: 12px; padding: 22px 16px; }
  .feature-editor-icon { width: 44px; height: 44px; border-radius: 14px; font-size: 23px; }
  .feature-editor h2 { font-size: 21px; }
  .feature-section { margin: 14px 12px; padding: 16px; }
  .feature-shop-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .feature-option { padding: 12px; }
  .feature-editor-footer { flex-wrap: wrap; gap: 10px; padding-left: 16px; padding-right: 16px; }
  .feature-editor-footer > .feature-help { max-width: none; font-size: 11px; }
  .feature-editor-footer > div { width: 100%; }
  .feature-editor-footer button { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .feature-editor *, .feature-editor *::after { transition: none !important; }
}