/* warap-ads-regie.min.css — chargee uniquement par : publicite.html
 * Extraite de la feuille globale : la servir a tout le monde
 * revenait a faire payer a chaque visiteur du style qu'il ne
 * verra jamais. */

/* === _ads-regie.css === */
/* Regie publicitaire — chargee UNIQUEMENT par publicite.html.
 *
 * Extrait de _ads.css le 16/08/2026. Mesure : 72 %% du module, impose a
 * 82 pages sur 83 qui n en affichent jamais une seule regle. Les pages de
 * contenu gardent les emplacements (ad-slot, ad-card) dans la feuille
 * globale ; seule la console de l annonceur vit ici.
 */


/* ------------------------------------------------------------
   ADVERTISING DASHBOARD (pour advertiser editor)
   ------------------------------------------------------------ */
.advdash {
  width: 100%;
  max-width: 100%;
  padding: 12px;
  box-sizing: border-box;
}



.advdash-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid #e5e5e5;
  margin-bottom: 16px;
  -webkit-overflow-scrolling: touch;
}


.advdash-tab {
  flex-shrink: 0;
  padding: 10px 14px;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  font-size: 14px;
  font-weight: 500;
  color: #666;
  cursor: pointer;
  white-space: nowrap;
  min-height: 44px;
  transition: color .15s, border-color .15s;
}


.advdash-tab.active { color: #1976d2; border-bottom-color: #1976d2; }


.advdash-tab:focus-visible { outline: 2px solid #1976d2; outline-offset: 2px; }


.advdash-kpi {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 12px;
  text-align: left;
}


.advdash-kpi-value {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.2;
}


.advdash-kpi-label {
  font-size: 11px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-top: 4px;
}


.advdash-kpi-sub {
  font-size: 12px;
  color: #4caf50;
  margin-top: 4px;
}


.advdash-kpi-sub.neg { color: #e53935; }



/* Sections */
.advdash-section {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 12px;
}


.advdash-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}


.advdash-section-header h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
}


.advdash-section-actions { display: flex; gap: 6px; flex-wrap: wrap; }



/* Tables : scroll horizontal sur mobile */
.advdash-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -12px;
  padding: 0 12px;
}


.advdash-table {
  width: 100%;
  min-width: 600px;
  border-collapse: collapse;
  font-size: 13px;
}


.advdash-table th,
.advdash-table td {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid #f0f0f0;
  white-space: nowrap;
}


.advdash-table th {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: #666;
  background: #fafafa;
  position: sticky;
  top: 0;
  z-index: 1;
}


.advdash-table td.num { text-align: right; font-variant-numeric: tabular-nums; }



/* Buttons & inputs (mobile friendly) */
.advdash-btn {
  min-height: 44px;
  padding: 10px 16px;
  background: #1976d2;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}


.advdash-btn:active { transform: scale(.98); }


.advdash-btn:disabled { opacity: .5; cursor: not-allowed; }


.advdash-btn.secondary { background: #fff; color: #1976d2; border: 1px solid #1976d2; }


.advdash-btn.danger    { background: #d32f2f; }


.advdash-btn.ghost     { background: transparent; color: #666; border: 1px solid #ddd; }


.advdash-btn.sm        { min-height: 36px; padding: 6px 12px; font-size: 13px; }



.advdash-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}


  .advdash-form .full { grid-column: 1 / -1; }


.advdash-form label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: .5px;
}


.advdash-form input,
.advdash-form select,
.advdash-form textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 14px;
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #fff;
  min-height: 44px;
  box-sizing: border-box;
  font-family: inherit;
}


.advdash-form input:focus,
.advdash-form select:focus,
.advdash-form textarea:focus {
  outline: none;
  border-color: #1976d2;
  box-shadow: 0 0 0 3px rgba(25, 118, 210, .15);
}


.advdash-form textarea { min-height: 80px; resize: vertical; }


.advdash-form .hint { font-size: 11px; color: #999; margin-top: 4px; }



/* Badges */
.advdash-badge {
  display: inline-block;
  padding: 2px 8px;
  font-size: 11px;
  border-radius: 10px;
  font-weight: 500;
  letter-spacing: .3px;
}


.advdash-badge.status-active  { background: #e8f5e9; color: #2e7d32; }


.advdash-badge.status-paused  { background: #fff3e0; color: #f57c00; }


.advdash-badge.status-pending { background: #e3f2fd; color: #1976d2; }


.advdash-badge.status-ended   { background: #eee; color: #777; }


.advdash-badge.status-rejected{ background: #ffebee; color: #c62828; }



/* Chips (keyword list) */
.advdash-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}


.advdash-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: #f5f5f5;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 500;
  color: #333;
}


.advdash-chip .mt { font-size: 10px; color: #666; text-transform: uppercase; }


.advdash-chip .bid { color: #1976d2; font-weight: 700; }


.advdash-chip button {
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 0 4px;
  min-height: 24px;
}


.advdash-modal {
  background: #fff;
  width: 100%;
  max-width: 100%;
  max-height: 92vh;
  border-radius: 12px 12px 0 0;
  padding: 16px;
  overflow-y: auto;
  animation: advSlideUp .25s ease;
  box-sizing: border-box;
}


  .advdash-modal {
    max-width: 720px;
    border-radius: 12px;
    max-height: 85vh;
  }


.advdash-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #eee;
}


.advdash-modal-header h3 { margin: 0; font-size: 17px; }


.advdash-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #999;
  min-width: 44px;
  min-height: 44px;
}



/* Suggestions list */
.advdash-suggestions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}


.advdash-suggestion {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 8px;
  min-height: 44px;
  cursor: pointer;
}


.advdash-suggestion:active { background: #f0f0f0; }


.advdash-suggestion-main { flex: 1; min-width: 0; }


.advdash-suggestion-kw { font-weight: 500; font-size: 14px; }


.advdash-suggestion-meta { font-size: 11px; color: #777; }


.advdash-suggestion-bid { font-size: 13px; color: #1976d2; font-weight: 700; white-space: nowrap; }



/* Responsive : sidebar collapsible sur mobile */
.advdash-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}


.advdash-sidebar {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 8px;
  overflow-x: auto;
}


.advdash-sidebar-list {
  display: flex;
  gap: 4px;
  list-style: none;
  padding: 0;
  margin: 0;
}


.advdash-sidebar-item {
  flex-shrink: 0;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  color: #555;
  white-space: nowrap;
  min-height: 44px;
  display: flex;
  align-items: center;
}


.advdash-sidebar-item.active {
  background: #e3f2fd;
  color: #1976d2;
  font-weight: 600;
}



/* Metrics inline (row with ACoS/ROAS/CVR) */
.advdash-metrics-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 0;
}


.advdash-metric-pill {
  flex-shrink: 0;
  padding: 8px 12px;
  background: #f5f5f5;
  border-radius: 8px;
  font-size: 12px;
}


.advdash-metric-pill b { display: block; font-size: 16px; color: #1a1a1a; }



/* Empty state */
.advdash-empty {
  text-align: center;
  padding: 40px 20px;
  color: #999;
}


.advdash-empty-icon { font-size: 40px; margin-bottom: 8px; opacity: .5; }


.advdash-empty-text { font-size: 14px; }



/* Toggle (active/paused) */
.advdash-toggle {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 24px;
}


.advdash-toggle input { display: none; }


.advdash-toggle-slider {
  position: absolute;
  inset: 0;
  background: #ccc;
  border-radius: 12px;
  transition: .2s;
  cursor: pointer;
}


.advdash-toggle-slider::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 2px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: .2s;
}


.advdash-toggle input:checked + .advdash-toggle-slider { background: #4caf50; }


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



/* Safe utilities */
.advdash-hidden { display: none !important; }


.advdash-muted  { color: #999; font-size: 12px; }


.advdash-pos    { color: #2e7d32; }


.advdash-neg    { color: #c62828; }



/* Chips pour selections multiples */
.advdash-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}


.advdash-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  font-size: .8125rem;
  color: #374151;
  cursor: pointer;
  background: #fff;
  user-select: none;
  transition: all .15s;
  min-height: 36px;
}


.advdash-chip:hover { border-color: #001F3F; color: #001F3F; }


.advdash-chip input[type="checkbox"] {
  margin: 0;
  width: 14px;
  height: 14px;
  accent-color: #001F3F;
}


.advdash-chip:has(input:checked) {
  background: #f0f4f8;
  border-color: #001F3F;
  color: #001F3F;
  font-weight: 600;
}



/* Headings inside forms */
.advdash-h4 {
  font-size: .875rem;
  font-weight: 700;
  color: #0f172a;
  margin: 1rem 0 .5rem;
  grid-column: 1 / -1;
}


.advdash-h2 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #0f172a;
}



/* Form grid mobile-first */
.advdash-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}


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


.advdash-field-full { grid-column: 1 / -1; }


.advdash-field label {
  font-size: .75rem;
  color: #6b7280;
  font-weight: 500;
}


.advdash-field input[type="text"],
.advdash-field input[type="number"],
.advdash-field input[type="range"],
.advdash-field input[type="email"],
.advdash-field input[type="tel"],
.advdash-field textarea,
.advdash-field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: .875rem;
  font-family: inherit;
  background: #fff;
  min-height: 42px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}


.advdash-field input:focus,
.advdash-field select:focus,
.advdash-field textarea:focus {
  border-color: #001F3F;
  box-shadow: 0 0 0 3px rgba(0,31,63,.1);
}


.advdash-field textarea { resize: vertical; }


.advdash-field select[multiple] { min-height: 100px; }



/* Buttons */
.advdash-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  color: #374151;
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  min-height: 42px;
  touch-action: manipulation;
  transition: all .15s;
  font-family: inherit;
}


.advdash-btn:hover { border-color: #001F3F; color: #001F3F; }


.advdash-btn:active { transform: scale(.98); }


.advdash-btn-primary {
  background: #001F3F;
  color: #fff;
  border-color: #001F3F;
}


.advdash-btn-primary:hover { background: #001834; color: #fff; }


.advdash-btn-sm {
  padding: 6px 12px;
  font-size: .75rem;
  min-height: 32px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #e5e7eb;
  color: #374151;
  font-weight: 600;
  cursor: pointer;
}


.advdash-btn-sm:hover { border-color: #001F3F; color: #001F3F; }


.advdash-btn-danger { background: #ef4444; color: #fff; border-color: #ef4444; }


.advdash-btn-danger:hover { background: #dc2626; color: #fff; }


@keyframes advdash-fade-in { from { opacity: 0; }


.advdash-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
}


.advdash-modal-panel {
  position: relative;
  width: 100%;
  max-height: 92vh;
  background: #fff;
  border-radius: 20px 20px 0 0;
  display: flex;
  flex-direction: column;
  animation: advdash-slide-up .3s cubic-bezier(.4,0,.2,1);
  z-index: 1;
}


@keyframes advdash-slide-up {
  from { transform: translateY(100%); }


  .advdash-modal-panel {
    max-width: 720px;
    max-height: 88vh;
    border-radius: 16px;
    animation: advdash-scale-in .2s;
  }


  @keyframes advdash-scale-in {
    from { opacity: 0; transform: scale(.96); }


.advdash-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #f1f5f9;
  flex-shrink: 0;
}


.advdash-modal-header h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}


.advdash-modal-close {
  width: 36px;
  height: 36px;
  border: none;
  background: #f1f5f9;
  border-radius: 50%;
  font-size: 1.5rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
}


.advdash-modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
}


.advdash-modal-footer {
  display: flex;
  gap: 8px;
  padding: 14px 20px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid #f1f5f9;
  flex-shrink: 0;
  justify-content: flex-end;
  background: #fff;
}



/* Tabs (mobile scroll-x) */
.advdash-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 4px;
  background: #f8fafc;
  border-radius: 12px;
  margin-bottom: 1rem;
  scroll-snap-type: x proximity;
}


.advdash-tabs::-webkit-scrollbar { display: none; }


.advdash-tab {
  flex-shrink: 0;
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #64748b;
  font-size: .875rem;
  font-weight: 600;
  cursor: pointer;
  min-height: 40px;
  scroll-snap-align: start;
  white-space: nowrap;
  transition: all .15s;
}


.advdash-tab-active {
  background: #fff;
  color: #001F3F;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}



/* List + empty state */
.advdash-list { display: flex; flex-direction: column; gap: 10px; }


.advdash-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: #94a3b8;
  font-size: .875rem;
  background: #f8fafc;
  border-radius: 12px;
}


.advdash-error {
  background: #fee2e2;
  color: #991b1b;
  padding: 10px;
  border-radius: 10px;
  font-size: .875rem;
}



/* Card generic */
.advdash-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 14px;
}


.advdash-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}


.advdash-card-title {
  font-weight: 700;
  color: #0f172a;
  font-size: .9375rem;
}


.advdash-card-meta {
  font-size: .75rem;
  color: #64748b;
  margin-top: 2px;
}

