.wp-studio-hero {
  background: linear-gradient(135deg, #1c2130 0%, #2a3142 45%, #d62828 100%);
  border-radius: 16px;
  padding: 24px 28px;
  margin-bottom: 24px;
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}
.wp-studio-hero h2 { margin: 0 0 6px; font-size: 1.5em; }
.wp-studio-hero p { margin: 0; opacity: 0.88; max-width: 520px; }
.wp-studio-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.88em;
  font-weight: 600;
  background: rgba(255,255,255,0.12);
}
.wp-studio-status.ok { background: rgba(34,197,94,0.25); color: #86efac; }
.wp-studio-status.local { background: rgba(234,179,8,0.2); color: #fde047; }
.wp-studio-status.err { background: rgba(239,68,68,0.25); color: #fca5a5; }
.wp-studio-status .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

.wp-studio-subtabs { display: flex; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.wp-studio-subtabs--sticky {
  position: sticky;
  top: 0;
  z-index: 40;
  padding: 10px 0 12px;
  margin-bottom: 12px;
  background: linear-gradient(180deg, #0f1117 70%, rgba(15,17,23,0.92));
  border-bottom: 1px solid rgba(42,49,66,0.8);
}
.wp-studio-subtabs button {
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  cursor: pointer;
  font-size: 0.95em;
  transition: transform 0.15s, border-color 0.15s;
}
.wp-studio-subtabs button:hover { transform: translateY(-1px); }
.wp-studio-subtabs button.active {
  background: linear-gradient(135deg, rgba(214,40,40,0.2), rgba(214,40,40,0.08));
  border-color: var(--red);
  color: var(--red);
  font-weight: 700;
}

/* Feedback + statut qui suivent le scroll */
.wp-studio-feedback-host {
  position: sticky;
  top: 58px;
  z-index: 39;
  min-height: 0;
}
.wp-studio-feedback-host:empty { display: none; }
.wp-studio-feedback-host .wp-studio-feedback {
  margin-bottom: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}

/* Éditeur article : rail gauche sticky (liste + sync) */
.wp-editor-shell {
  display: grid;
  grid-template-columns: minmax(220px, 260px) 1fr;
  gap: 16px;
  align-items: start;
}
.wp-editor-shell--wide {
  grid-template-columns: 1fr;
}
@media (max-width: 960px) {
  .wp-editor-shell { grid-template-columns: 1fr; }
}
.wp-editor-rail {
  position: sticky;
  top: 120px;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: calc(100vh - 140px);
  overflow: auto;
  padding-right: 4px;
}
.wp-editor-rail-card {
  background: var(--bg-elevated, #151922);
  border: 1px solid var(--border, #2a3142);
  border-radius: 12px;
  padding: 12px;
}
.wp-editor-rail-card h4 {
  margin: 0 0 10px;
  font-size: 0.88em;
  color: #9aa3b2;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.wp-editor-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.wp-editor-nav-list button {
  width: 100%;
  text-align: left;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text, #e8eaef);
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
  font: inherit;
  font-size: 0.86em;
  line-height: 1.35;
}
.wp-editor-nav-list button:hover {
  background: rgba(168, 85, 247, 0.1);
  border-color: rgba(168, 85, 247, 0.25);
}
.wp-editor-nav-list button.is-active {
  background: rgba(214, 40, 40, 0.12);
  border-color: rgba(214, 40, 40, 0.4);
  color: #fecaca;
  font-weight: 600;
}
.wp-editor-nav-list .wp-nav-meta {
  display: block;
  font-size: 0.78em;
  color: #9aa3b2;
  margin-top: 2px;
}
.wp-editor-main-col { min-width: 0; }
.wp-editor-sync-panel--sticky {
  position: sticky;
  top: 120px;
  z-index: 15;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}
.wp-editor-status-bar--sticky {
  position: sticky;
  top: 120px;
  z-index: 16;
  background: rgba(15, 17, 23, 0.95);
  backdrop-filter: blur(8px);
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border, #2a3142);
  margin-bottom: 12px;
}
.wp-editor-actions--sticky {
  position: sticky;
  bottom: 8px;
  z-index: 18;
  background: rgba(15, 17, 23, 0.94);
  border: 1px solid var(--border, #2a3142);
  border-radius: 12px;
  padding: 10px 12px;
  margin-top: 12px;
  box-shadow: 0 -6px 24px rgba(0,0,0,0.35);
  flex-wrap: wrap;
}

/* Médiathèque : toolbar sticky */
.wp-media-sticky-bar {
  position: sticky;
  top: 120px;
  z-index: 25;
  background: rgba(15, 17, 23, 0.96);
  border: 1px solid var(--border, #2a3142);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 14px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.28);
}
.wp-media-sticky-bar .wp-media-toolbar { margin-bottom: 10px; }
.wp-media-sticky-bar .wp-media-filters { margin: 0; }
.wp-media-sticky-bar .wp-media-alert { margin: 10px 0 0; }

/* Instagram / Photos composer */
.wp-ig-layout {
  display: grid;
  grid-template-columns: minmax(240px, 300px) 1fr;
  gap: 18px;
  align-items: start;
}
@media (max-width: 900px) {
  .wp-ig-layout { grid-template-columns: 1fr; }
}
.wp-ig-rail {
  position: sticky;
  top: 120px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.wp-ig-card {
  background: var(--bg-elevated, #151922);
  border: 1px solid var(--border, #2a3142);
  border-radius: 12px;
  padding: 14px 16px;
}
.wp-ig-card h3 { margin: 0 0 10px; font-size: 1.05em; }
.wp-ig-preview-wrap {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #0c0e14;
  border: 1px solid var(--border, #2a3142);
  min-height: 320px;
  max-width: 420px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.wp-ig-preview-wrap img,
.wp-ig-preview-wrap canvas {
  max-width: 100%;
  max-height: 480px;
  display: block;
}
.wp-ig-history-card {
  margin-top: 14px;
  background: var(--bg-elevated, #151922);
  border: 1px solid var(--border, #2a3142);
  border-radius: 12px;
  padding: 12px 14px;
}
.wp-ig-history-card > summary {
  cursor: pointer;
  font-weight: 700;
  color: #e9d5ff;
}
.wp-ig-history-toolbar {
  margin: 10px 0 8px;
}
.wp-ig-last-pub {
  margin: 12px 0;
  padding: 10px;
  border-radius: 10px;
  background: #12151c;
  border: 1px solid #2a3142;
}
.wp-ig-last-pub img {
  display: block;
  width: 100%;
  max-width: 420px;
  max-height: 520px;
  height: auto;
  object-fit: contain;
  background: #0c0e14;
  border-radius: 8px;
  margin: 8px auto;
}
.wp-ig-last-pub p { margin: 0; color: #9aa3b2; font-size: 0.86em; }
.wp-ig-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 480px;
  overflow: auto;
}
.wp-ig-history-item {
  width: 100%;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  text-align: left;
  padding: 8px;
  border-radius: 10px;
  border: 1px solid #2a3142;
  background: #0c0e14;
  color: inherit;
  cursor: pointer;
}
.wp-ig-history-item:hover { border-color: #a855f7; }
.wp-ig-history-item img {
  display: block;
  width: 108px;
  height: 136px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
  background: #0c0e14;
}
.wp-ig-history-ph {
  width: 108px;
  height: 136px;
  border-radius: 8px;
  flex-shrink: 0;
  background: #1c2130;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.wp-ig-history-item img.is-broken { display: none; }
.wp-ig-history-item strong { display: block; font-size: 0.88em; }
.wp-ig-history-item em { display: block; font-size: 0.76em; color: #9aa3b2; font-style: normal; }
.wp-editor-fold {
  margin-top: 12px;
  border: 1px solid #2a3142;
  border-radius: 10px;
  padding: 10px 12px;
  background: #12151c;
}
.wp-editor-fold > summary {
  cursor: pointer;
  color: #c4b5fd;
  font-weight: 700;
}
.wp-ig-overlay-box {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.82));
  border-radius: 10px;
  padding: 28px 14px 14px;
  pointer-events: none;
}
.wp-ig-overlay-line {
  display: block;
  color: #fff;
  font-weight: 700;
  font-size: 0.95em;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  margin-bottom: 4px;
}
.wp-ig-overlay-line--price { color: #fecaca; font-size: 1.15em; }
.wp-ig-logo-badge {
  position: absolute;
  top: 16px;
  /* décalé vers la gauche pour ne pas monter sur le cadre */
  right: 28px;
  width: min(32%, 220px);
  height: auto;
  z-index: 3;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.62);
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  pointer-events: none;
  object-fit: contain;
}
.wp-ig-frame-preview .wp-ig-logo-badge {
  top: 22px;
  right: 36px;
}
.wp-ig-frame-preview {
  position: relative;
  box-sizing: border-box;
  padding: 14px 14px 0;
  background: var(--ig-frame, #d62828);
  border-radius: 4px;
  max-width: 100%;
}
.wp-ig-frame-preview--off {
  padding: 0;
  background: transparent;
}
.wp-ig-frame-preview--off .wp-ig-frame-label { display: none; }
.wp-ig-preview-video {
  width: 100%;
  max-height: 480px;
  display: block;
  background: #0a0a0c;
}
.wp-ig-frame-preview img#ig-preview-img {
  width: 100%;
  max-height: 480px;
  object-fit: contain;
  display: block;
  background: #0a0a0c;
}
.wp-ig-frame-label {
  text-align: center;
  padding: 10px 8px;
  background: var(--ig-accent, #1c2130);
  color: #fff;
  font-size: 0.78em;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.wp-rail-cat-label {
  display: block;
  font-size: 0.75em;
  color: #9aa3b2;
  margin-bottom: 4px;
}
.wp-rail-cat-select {
  width: 100%;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--border, #2a3142);
  background: #0c0e14;
  color: var(--text, #e8eaef);
  font-size: 0.88em;
}
.wp-rail-filters {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
}
.wp-rail-filter-col {
  min-width: 0;
}
.wp-ig-platforms label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  cursor: pointer;
  font-size: 0.92em;
}
.wp-ig-hint {
  color: #9aa3b2;
  font-size: 0.88em;
  line-height: 1.5;
  margin: 0 0 12px;
}
.wp-ig-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.wp-ig-presets button {
  font-size: 0.82em;
}

.wp-content-alerts { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.wp-content-alerts--muted { flex-direction: row; align-items: center; gap: 12px; flex-wrap: wrap; }
.wp-content-alerts-actions { display: flex; gap: 8px; margin-top: 4px; }
.wp-content-alert {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: 10px;
  background: rgba(234, 179, 8, 0.12);
  border: 1px solid rgba(234, 179, 8, 0.35);
  color: #fde047;
  font-size: 0.92em;
}
.wp-content-alert--urgent {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.4);
  color: #fca5a5;
}
.wp-article-filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; align-items: center; }
.wp-filter-sep {
  width: 1px;
  height: 24px;
  background: var(--border);
  margin: 0 4px;
}
.wp-net-filter-btn:not(.btn-outline) {
  background: rgba(59, 130, 246, 0.25) !important;
  border-color: rgba(59, 130, 246, 0.55) !important;
  color: #93c5fd !important;
}
.wp-article-type-badge {
  display: inline-block;
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 6px;
}
.wp-toolbar-images { margin-top: 6px; }
.wp-toolbar-images button { font-size: 0.82em; }

.wp-articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
}
.wp-article-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.wp-article-card:hover {
  transform: translateY(-4px);
  border-color: var(--red);
  box-shadow: 0 12px 28px rgba(0,0,0,0.25);
}
.wp-articles-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}
.wp-article-search {
  flex: 1;
  min-width: 200px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 0.92em;
}
.wp-article-sort {
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 0.88em;
}

.wp-articles-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-elevated);
}
.wp-articles-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88em;
}
.wp-articles-table th {
  text-align: left;
  padding: 12px 14px;
  color: #9aa3b2;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.wp-articles-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.wp-articles-row {
  cursor: pointer;
  transition: background 0.15s;
}
.wp-articles-row:hover { background: rgba(214, 40, 40, 0.06); }
.wp-articles-row--action { background: rgba(234, 179, 8, 0.06); }
.wp-articles-row-date { color: #9aa3b2; white-space: nowrap; }
.wp-articles-row-actions { white-space: nowrap; display: flex; gap: 6px; }

.wp-cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.72em;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.wp-cat-icon-svg {
  flex-shrink: 0;
  opacity: 0.95;
}
.wp-cat-group-row td {
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
}
.wp-cat-group-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px 8px;
  margin-top: 8px;
  border-top: 1px solid #2e3648;
}
.wp-cat-group-header--parent {
  background: rgba(214, 40, 40, 0.06);
  border-radius: 8px;
  margin-top: 12px;
}
.wp-cat-group-header--sub {
  padding-left: 28px;
}
.wp-cat-group-row:first-child .wp-cat-group-header {
  margin-top: 0;
  border-top: none;
}
.wp-cat-group-count {
  font-size: 0.78em;
  color: #9aa3b2;
  font-weight: 600;
}
.wp-social-link-hint {
  font-size: 0.82em;
  color: #9aa3b2;
  margin: 0 0 8px;
  word-break: break-all;
}
.wp-social-link-hint a { color: #5b8def; }
.wp-social-link-hint--warn { color: #fde047; }
.wp-studio-actions--publish {
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.wp-studio-actions--publish button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
#wp-publish-wordpress {
  background: linear-gradient(135deg, #1c2130, #2563eb);
  border-color: rgba(37, 99, 235, 0.55);
  color: #fff;
  font-weight: 700;
}
#wp-publish-social:not(:disabled) {
  border-color: rgba(34, 197, 94, 0.55);
  color: #86efac;
}
.wp-article-card-cover .wp-cat-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.wp-sync-badge {
  display: inline-block;
  margin-top: 8px;
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 0.78em;
  font-weight: 600;
}
.wp-sync-badge--ok { background: rgba(34, 197, 94, 0.15); color: #86efac; }
.wp-sync-badge--draft { background: rgba(239, 68, 68, 0.12); color: #fca5a5; }
.wp-sync-badge--action { background: rgba(234, 179, 8, 0.15); color: #fde047; }

.wp-net-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.wp-net-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  font-size: 0.85em;
  border: 1px solid transparent;
}
.wp-net-chip--ok { background: rgba(34, 197, 94, 0.2); border-color: rgba(34, 197, 94, 0.45); }
.wp-net-chip--pending { background: rgba(59, 130, 246, 0.2); border-color: rgba(59, 130, 246, 0.45); }
.wp-net-chip--warn { background: rgba(234, 179, 8, 0.2); border-color: rgba(234, 179, 8, 0.45); }
.wp-net-chip--muted { background: rgba(107, 114, 128, 0.15); color: #9aa3b2; font-size: 0.7em; width: auto; padding: 0 8px; }

.wp-article-card--action { border-color: rgba(234, 179, 8, 0.45) !important; }

.wp-editor-sync-panel {
  margin-bottom: 16px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  font-size: 0.88em;
}
.wp-editor-sync-panel strong { display: block; margin-bottom: 6px; }
.wp-editor-sync-action { color: #fde047; margin: 0 0 10px; font-weight: 600; }
.wp-sync-line { display: block; margin-bottom: 4px; color: #9aa3b2; }
.wp-sync-line--ok { color: #86efac; }
.wp-sync-line--pending { color: #93c5fd; }
.wp-sync-line--warn { color: #fde047; }
.wp-sync-line--draft { color: #fca5a5; }
.wp-sync-line--muted { color: #6b7280; }

.wp-social-check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.wp-social-sync {
  margin-left: auto;
  font-size: 0.78em;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
}
.wp-social-sync--ok { background: rgba(34, 197, 94, 0.15); color: #86efac; }
.wp-social-sync--pending { background: rgba(59, 130, 246, 0.15); color: #93c5fd; }
.wp-social-sync--warn { background: rgba(234, 179, 8, 0.15); color: #fde047; }

.wp-article-card-cover {
  height: 140px;
  background: linear-gradient(135deg, #1c2130, #d62828);
  position: relative;
  overflow: hidden;
}
.wp-article-card-cover img { width: 100%; height: 100%; object-fit: cover; }
.wp-article-card-cover .placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5em;
  opacity: 0.5;
}
.wp-article-card-body { padding: 16px; }
.wp-article-card-body h4 { margin: 0 0 8px; font-size: 1.05em; line-height: 1.3; }
.wp-article-card-body p { margin: 0; color: #9aa3b2; font-size: 0.85em; line-height: 1.45; }
.wp-article-delete { margin-top: 10px; color: #ef4444 !important; border-color: rgba(239, 68, 68, 0.5) !important; }
.wp-article-meta { margin-top: 10px; font-size: 0.78em; color: #6b7280; }
.wp-article-meta a { color: #86efac; text-decoration: none; }
.wp-article-meta a:hover { text-decoration: underline; }

.wp-article-status {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.7em;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  z-index: 2;
  line-height: 1;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.28);
}
.wp-article-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
}
.wp-article-status--published {
  background: linear-gradient(135deg, #16a34a, #22c55e);
  color: #fff;
}
.wp-article-status--draft {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: #fff;
}
.wp-article-card--published { border-color: rgba(34, 197, 94, 0.35); }
.wp-article-card--draft { border-color: rgba(239, 68, 68, 0.22); }

.wp-studio-guide {
  margin-bottom: 16px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(59, 130, 246, 0.08);
  border: 1px solid rgba(59, 130, 246, 0.28);
  font-size: 0.9em;
  color: #cbd5e1;
}
.wp-studio-guide summary {
  cursor: pointer;
  font-weight: 700;
  color: #93c5fd;
}
.wp-studio-guide ol {
  margin: 12px 0 0 18px;
  padding: 0;
  line-height: 1.65;
}
.wp-studio-guide li { margin-bottom: 6px; }

.wp-studio-feedback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 0.92em;
  font-weight: 600;
  animation: wp-feedback-in 0.25s ease;
}
@keyframes wp-feedback-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
.wp-studio-feedback--ok {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.45);
  color: #86efac;
}
.wp-studio-feedback--err {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.45);
  color: #fca5a5;
}
.wp-studio-feedback--info {
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.45);
  color: #93c5fd;
}
.wp-studio-feedback-close {
  border: none;
  background: transparent;
  color: inherit;
  font-size: 1.25em;
  line-height: 1;
  cursor: pointer;
  opacity: 0.75;
  padding: 0 4px;
}
.wp-studio-feedback-close:hover { opacity: 1; }

.wp-editor-status-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
}
.wp-editor-status-bar .wp-article-status {
  position: static;
  box-shadow: none;
}
.wp-editor-status-note {
  font-size: 0.88em;
  color: #9aa3b2;
  line-height: 1.45;
}
.wp-editor-status-note a { color: #86efac; }

.wp-editor-layout {
  display: grid;
  grid-template-columns: minmax(420px, 1.2fr) minmax(340px, 1fr);
  gap: 16px;
  align-items: start;
}
.wp-ed-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 700px) {
  .wp-ed-grid-2 { grid-template-columns: 1fr; }
}
.wp-ed-cover-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.wp-ed-cover-row input { flex: 1; min-width: 180px; }
.wp-ed-cover-thumb {
  max-width: 160px;
  margin-top: 8px;
  border-radius: 8px;
  display: block;
}
@media (max-width: 1100px) {
  .wp-editor-layout { grid-template-columns: 1fr; }
}
.wp-editor-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
}
.wp-editor-panel h3 { margin: 0 0 16px; font-size: 1.1em; }
.wp-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.wp-preview-head h3 { margin: 0; }
.wp-preview-zoom { display: flex; gap: 6px; }
.wp-preview-zoom button {
  padding: 5px 10px;
  border-radius: 8px;
  border: 1px solid var(--border, #2a3142);
  background: #12151c;
  color: #cbd5e1;
  cursor: pointer;
  font-size: 0.78em;
}
.wp-preview-zoom button.is-on {
  background: rgba(168, 85, 247, 0.2);
  border-color: #a855f7;
  color: #e9d5ff;
}
.wp-editor-panel--preview {
  position: sticky;
  top: 88px;
  height: auto;
  max-height: none;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: visible;
  z-index: 12;
}
.wp-preview-frame {
  --preview-zoom: 1;
  --preview-base: 360px;
  border: 1px solid #c5cdd8;
  border-radius: 14px;
  background: #d1d5db;
  padding: 16px 12px 20px;
  height: calc(var(--preview-base) * 3 + 12cm);
  min-height: calc(var(--preview-base) * 3 + 12cm);
  max-height: calc(var(--preview-base) * 3 + 12cm);
  overflow-x: hidden;
  overflow-y: auto;
}
.wp-preview-page {
  width: min(100%, 640px);
  min-height: 0;
  margin: 0 auto;
  background: #fff;
  color: #1c2130;
  border-radius: 10px;
  box-shadow: 0 10px 32px rgba(15, 23, 42, 0.12);
  padding: 20px 22px 28px;
  zoom: var(--preview-zoom, 1);
  line-height: 1.55;
}
.wp-gbp-done {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 0.72em;
  font-weight: 700;
  background: rgba(34,197,94,0.18);
  color: #86efac;
}
.wp-gbp-done--no {
  background: rgba(234,179,8,0.15);
  color: #fde047;
}
.wp-gbp-dialog {
  max-width: 560px;
  width: min(560px, 94vw);
  background: #151922;
  border: 1px solid #2a3142;
  border-radius: 14px;
  padding: 18px 18px 16px;
  color: #e8eaef;
}
.wp-gbp-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.82em;
  font-weight: 700;
  margin: 0 0 12px;
}
.wp-gbp-status--ok { background: rgba(34,197,94,0.18); color: #86efac; }
.wp-gbp-status--no { background: rgba(234,179,8,0.16); color: #fde047; }
.wp-gbp-card { margin-top: 0; }
.wp-gbp-card--off { opacity: 0.85; }
.wp-gbp-card strong { display: block; margin-bottom: 6px; color: #e9d5ff; }
.wp-gbp-hint { color: #9aa3b2; font-size: 0.84em; line-height: 1.45; margin: 0 0 10px; }
.wp-gbp-photo {
  display: block;
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  border-radius: 8px;
  margin: 0 0 10px;
}
.wp-gbp-card textarea,
.wp-gbp-card input[type="text"] {
  width: 100%;
  margin: 4px 0 10px;
  background: #0c0e14;
  color: #e8eaef;
  border: 1px solid #2a3142;
  border-radius: 8px;
  padding: 8px 10px;
}
.wp-gbp-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.wp-preview-page img { max-width: 100%; height: auto; border-radius: 8px; }
.wp-preview-empty { color: #6b7280; text-align: center; margin: 40px 12px; }

.wp-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}
.wp-toolbar button {
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  font-size: 0.88em;
}
.wp-toolbar button:hover { border-color: var(--red); color: var(--red); }

.wp-color-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.wp-color-field label { display: block; font-size: 0.82em; color: #9aa3b2; margin-bottom: 6px; }
.wp-color-field input[type="color"] {
  width: 100%;
  height: 42px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  padding: 0;
}

.wp-media-version {
  font-size: 0.82em;
  color: #86efac;
  margin: 0 0 10px;
  padding: 8px 12px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.35);
  border-radius: 8px;
}
.wp-media-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}
.wp-media-import-cat {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88em;
  color: #9aa3b2;
}
.wp-media-import-cat select {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
}
.wp-media-alert {
  display: none;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 0.9em;
  font-weight: 600;
  animation: wp-feedback-in 0.25s ease;
}
.wp-media-alert-text { flex: 1; line-height: 1.45; word-break: break-word; }
.wp-media-alert--ok {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.45);
  color: #86efac;
}
.wp-media-alert--err {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.45);
  color: #fca5a5;
}
.wp-media-alert--info {
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.45);
  color: #93c5fd;
}
.wp-media-alert-close {
  border: none;
  background: transparent;
  color: inherit;
  font-size: 1.2em;
  cursor: pointer;
  opacity: 0.8;
  padding: 0 4px;
}
.wp-media-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.wp-media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 10px;
  max-height: 320px;
  overflow-y: auto;
  padding: 4px;
}
.wp-media-grid--library {
  max-height: none;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}
.wp-media-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: rgba(0,0,0,0.15);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px;
}
.wp-media-card--picker {
  padding: 6px;
  background: transparent;
  border: none;
}
.wp-media-card--in-use {
  border-color: rgba(234, 179, 8, 0.45);
  box-shadow: 0 0 0 1px rgba(234, 179, 8, 0.15);
}
.wp-media-used-badge {
  position: absolute;
  left: 6px;
  top: 6px;
  z-index: 2;
  font-size: 0.65em;
  font-weight: 700;
  background: rgba(234, 179, 8, 0.92);
  color: #1c1917;
  padding: 3px 7px;
  border-radius: 999px;
  max-width: calc(100% - 40px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wp-media-thumb-wrap {
  position: relative;
}
.wp-media-thumb {
  display: block;
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  position: relative;
  background: var(--bg);
  padding: 0;
  width: 100%;
  text-decoration: none;
}
.wp-media-thumb:hover, .wp-media-thumb.selected { border-color: var(--red); }
.wp-media-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; background: #0f1419; }
.wp-media-thumb img.wp-media-broken {
  object-fit: contain;
  opacity: 0.55;
  background: repeating-linear-gradient(
    -45deg,
    rgba(239, 68, 68, 0.12),
    rgba(239, 68, 68, 0.12) 8px,
    transparent 8px,
    transparent 16px
  );
}
.wp-media-thumb img.wp-media-broken::after { content: '404'; }
.wp-media-delete {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 999px;
  background: rgba(0,0,0,0.72);
  color: #fff;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.85;
}
.wp-media-delete:hover { background: #ef4444; opacity: 1; }
.wp-media-card-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.wp-media-card-name {
  font-size: 0.78em;
  color: #9aa3b2;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
.wp-media-label-input {
  width: 100%;
  font-size: 0.78em;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 8px;
}
.wp-media-path {
  display: block;
  font-size: 0.68em;
  color: #64748b;
  background: rgba(0,0,0,0.2);
  padding: 4px 6px;
  border-radius: 6px;
  word-break: break-all;
  user-select: all;
}
.wp-media-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.wp-media-card-actions .btn { flex: 1; min-width: 0; font-size: 0.72em; padding: 5px 8px; }
.wp-media-card-cat {
  font-size: 0.68em;
  color: #64748b;
}
.wp-media-cat-select {
  width: 100%;
  font-size: 0.72em;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 6px;
}

.wp-media-cat-manager {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}
.wp-media-cat-manager input {
  flex: 1;
  min-width: 200px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
}
.wp-media-cat-del {
  margin-left: 4px;
  opacity: 0.65;
  cursor: pointer;
  font-weight: 700;
}
.wp-media-cat-del:hover { opacity: 1; color: #ef4444; }

.wp-media-usage-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}
.wp-media-usage-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.68em;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  line-height: 1.35;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.wp-media-usage-tag--article { background: rgba(59, 130, 246, 0.18); color: #93c5fd; border: 1px solid rgba(59, 130, 246, 0.35); }
.wp-media-usage-tag--site { background: rgba(34, 197, 94, 0.15); color: #86efac; border: 1px solid rgba(34, 197, 94, 0.35); }
.wp-media-usage-tag--realisation { background: rgba(234, 179, 8, 0.15); color: #fde047; border: 1px solid rgba(234, 179, 8, 0.35); }
.wp-media-usage-tag--page { background: rgba(168, 85, 247, 0.15); color: #d8b4fe; border: 1px solid rgba(168, 85, 247, 0.35); }
.wp-media-usage-none {
  display: block;
  font-size: 0.68em;
  color: #64748b;
  margin-top: 6px;
  font-style: italic;
}

.wp-media-picker-overlay,
.commercial-modal-bg.wp-media-picker-overlay {
  display: none;
  position: fixed !important;
  inset: 0 !important;
  z-index: 12000 !important;
  background: rgba(0, 0, 0, 0.72);
  align-items: center !important;
  justify-content: center !important;
  padding: 16px !important;
  overflow-y: auto;
}
.wp-media-picker-overlay[style*="flex"] {
  display: flex !important;
}
.wp-media-picker-dialog,
.commercial-modal.wp-media-picker-dialog {
  background: #151922;
  border: 1px solid #2a3142;
  border-radius: 14px;
  padding: 18px 20px 16px;
  max-width: 900px;
  width: min(900px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
  color: #f0f2f5;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}
.wp-media-card--picker { cursor: pointer; }
.wp-media-card--picker .wp-media-thumb { pointer-events: none; }

.wp-preset-cards { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.wp-preset-card {
  flex: 1;
  min-width: 140px;
  padding: 16px;
  border-radius: 12px;
  border: 2px solid var(--border);
  cursor: pointer;
  text-align: center;
  transition: border-color 0.15s, transform 0.15s;
}
.wp-preset-card:hover { transform: scale(1.02); }
.wp-preset-card.active { border-color: var(--red); background: rgba(214,40,40,0.08); }
.wp-preset-swatch {
  height: 48px;
  border-radius: 8px;
  margin-bottom: 8px;
}

.wp-links-editor .wp-link-row {
  display: grid;
  grid-template-columns: 1fr 2fr auto;
  gap: 8px;
  margin-bottom: 8px;
  align-items: center;
}

.wp-connect-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  max-width: 560px;
}
.wp-connect-card h3 { margin: 0 0 8px; }
.wp-connect-steps {
  margin: 16px 0 20px;
  padding: 14px 16px;
  background: rgba(214,40,40,0.06);
  border-radius: 10px;
  font-size: 0.88em;
  color: #9aa3b2;
  line-height: 1.6;
}
.wp-connect-steps ol { margin: 8px 0 0 18px; padding: 0; }
.wp-connect-saved {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 8px;
  background: rgba(34,197,94,0.12);
  color: #86efac;
  font-size: 0.85em;
  margin-top: 12px;
}

.wp-studio-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.wp-back-link { color: #9aa3b2; font-size: 0.9em; cursor: pointer; margin-bottom: 16px; display: inline-block; }
.wp-back-link:hover { color: var(--red); }

.wp-fb-permanent-box {
  margin: 14px 0;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.35);
  font-size: 0.88em;
  color: #cbd5e1;
  line-height: 1.55;
}
.wp-fb-permanent-box strong { color: #86efac; display: block; margin-bottom: 6px; }
.wp-fb-permanent-box ol { margin: 10px 0 12px 18px; padding: 0; }
.wp-fb-permanent-box code { font-size: 0.92em; }
.wp-fb-permanent-box a { color: #93c5fd; }

.wp-tab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  margin-left: 6px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 0.72em;
  font-weight: 800;
  line-height: 1;
  animation: wp-badge-pulse 2s ease infinite;
}
.wp-tab-badge--social { background: #3b82f6; }
@keyframes wp-badge-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

.wp-network-backlog-wrap {
  margin-bottom: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(234, 179, 8, 0.1);
  border: 1px solid rgba(234, 179, 8, 0.45);
}
.wp-network-backlog-title {
  font-weight: 800;
  color: #fde047;
  margin-bottom: 12px;
  font-size: 0.95em;
}
.wp-network-backlog-alert {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 8px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.45);
  border: 1px solid rgba(234, 179, 8, 0.35);
}
.wp-network-backlog-alert:last-child { margin-bottom: 0; }
.wp-network-backlog-alert--new {
  border-color: rgba(59, 130, 246, 0.55);
  background: rgba(59, 130, 246, 0.08);
  animation: wp-backlog-glow 2.5s ease infinite;
}
@keyframes wp-backlog-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0); }
  50% { box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25); }
}
.wp-network-backlog-icon { font-size: 1.5em; }
.wp-network-backlog-text { flex: 1; min-width: 200px; font-size: 0.9em; color: #e2e8f0; line-height: 1.45; }
.wp-network-backlog-text strong { color: #fde047; }
.wp-network-backlog-hint { display: block; margin-top: 4px; font-size: 0.82em; color: #9aa3b2; }

.wp-pending-net-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.wp-pending-net-tag {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.72em;
  font-weight: 700;
  white-space: nowrap;
}
.wp-pending-net-tag--new {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border: 1px solid rgba(59, 130, 246, 0.45);
}
.wp-pending-net-tag--mod {
  background: rgba(234, 179, 8, 0.2);
  color: #fde047;
  border: 1px solid rgba(234, 179, 8, 0.45);
}

.wp-platform-backlog-note {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.88em;
  line-height: 1.5;
}
.wp-platform-backlog-note--alert {
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.4);
  color: #93c5fd;
}
.wp-platform-backlog-note--ok {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #86efac;
}
.wp-platform-backlog-note .btn { margin-left: 8px; margin-top: 6px; }

/* Liens & adresses — copie pour articles WordPress */
.wp-links-hero {
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-elevated);
}
.wp-links-hero h3 { margin: 0 0 8px; font-size: 1.1em; }
.wp-links-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}
.wp-links-search {
  flex: 1 1 240px;
  min-width: 200px;
  max-width: 480px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg-card);
  color: var(--text);
  font: inherit;
}
.wp-links-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.wp-links-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-elevated);
}
.wp-links-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9em;
}
.wp-links-table th,
.wp-links-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.wp-links-table th {
  font-size: 0.78em;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}
.wp-links-table tr:last-child td { border-bottom: none; }
.wp-links-title { display: block; margin-top: 4px; }
.wp-links-slug { font-size: 0.82em; margin-top: 2px; }
.wp-links-kind {
  display: inline-block;
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 2px 7px;
  border-radius: 4px;
}
.wp-links-kind--article { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.wp-links-kind--page { background: rgba(34, 197, 94, 0.12); color: #4ade80; }
.wp-links-url-input {
  width: 100%;
  min-width: 220px;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg-card);
  color: #93c5fd;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.82em;
  cursor: pointer;
}
.wp-links-actions { white-space: nowrap; }
.wp-links-actions .btn { margin: 2px 4px 2px 0; }
.wp-links-hint { margin-top: 12px; font-size: 0.85em; }