/* Deals Intelligence + deals subpage layout */

body.restaurant-menu-page .mp-dealintel-section {
  padding: 32px 0 28px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

body.restaurant-menu-page .mp-dealintel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-4);
}

body.restaurant-menu-page .mp-dealintel-head__title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 4px 0 0;
  line-height: 1.25;
}

body.restaurant-menu-page .mp-dealintel-head__live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface-alt);
  border: 1px solid var(--border);
}

body.restaurant-menu-page .mp-dealintel-head__clock {
  font-variant-numeric: tabular-nums;
}

body.restaurant-menu-page .mp-dealintel-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
}

/* Status panel */
body.restaurant-menu-page .mp-dealintel-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--sp-4);
  align-items: center;
  padding: 18px 20px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  margin-bottom: var(--sp-3);
}

body.restaurant-menu-page .mp-dealintel-panel--active {
  border-color: rgba(34, 197, 94, 0.2);
  background: linear-gradient(135deg, var(--surface) 0%, #f0fdf4 100%);
}

body.restaurant-menu-page .mp-dealintel-panel--limited {
  border-color: rgba(245, 158, 11, 0.22);
  background: linear-gradient(135deg, var(--surface) 0%, #fffbeb 100%);
}

body.restaurant-menu-page .mp-dealintel-panel__label {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

body.restaurant-menu-page .mp-dealintel-panel__detail {
  font-size: 13px;
  color: var(--text-muted);
  margin: 4px 0 0;
  max-width: 48ch;
}

body.restaurant-menu-page .mp-dealintel-panel__countdown {
  text-align: right;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  min-width: 148px;
}

body.restaurant-menu-page .mp-dealintel-panel__countdown-lbl {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

body.restaurant-menu-page .mp-dealintel-panel__countdown-val {
  display: block;
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  margin-top: 2px;
}

body.restaurant-menu-page .mp-dealintel-panel__countdown-note {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  max-width: 18ch;
  margin-left: auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Metrics strip */
body.restaurant-menu-page .mp-dealintel-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--border);
  margin-bottom: var(--sp-4);
}

body.restaurant-menu-page .mp-dealintel-metric {
  padding: 14px 16px;
  background: var(--surface);
  text-align: center;
}

body.restaurant-menu-page .mp-dealintel-metric__val {
  display: block;
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.1;
}

body.restaurant-menu-page .mp-dealintel-metric__lbl {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Rewards — light block */
body.restaurant-menu-page .mp-dealintel-rewards {
  display: grid;
  grid-template-columns: 1.2fr auto;
  gap: var(--sp-4);
  padding: 18px 20px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface);
}

body.restaurant-menu-page .mp-dealintel-rewards__eyebrow {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 0 0 4px;
}

body.restaurant-menu-page .mp-dealintel-rewards__title {
  font-size: 16px;
  font-weight: 800;
  margin: 0;
  color: var(--text);
}

body.restaurant-menu-page .mp-dealintel-rewards__tagline {
  font-size: 13px;
  color: var(--text-muted);
  margin: 4px 0 0;
  line-height: 1.45;
}

body.restaurant-menu-page .mp-dealintel-rewards__facts {
  display: flex;
  gap: var(--sp-4);
  align-items: flex-start;
}

body.restaurant-menu-page .mp-dealintel-rewards__fact-val {
  display: block;
  font-size: 15px;
  font-weight: 800;
  color: var(--text);
}

body.restaurant-menu-page .mp-dealintel-rewards__fact-lbl {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

body.restaurant-menu-page .mp-dealintel-rewards__list {
  grid-column: 1 / -1;
  list-style: none;
  margin: 0;
  padding: 12px 0 0;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px 16px;
}

body.restaurant-menu-page .mp-dealintel-rewards__list li {
  font-size: 12px;
  color: var(--text-muted);
}

body.restaurant-menu-page .mp-dealintel-rewards__list strong {
  display: block;
  font-size: 13px;
  color: var(--text);
  font-weight: 600;
}

@media (max-width: 720px) {
  body.restaurant-menu-page .mp-dealintel-panel {
    grid-template-columns: 1fr;
  }

  body.restaurant-menu-page .mp-dealintel-panel__countdown {
    text-align: left;
  }

  body.restaurant-menu-page .mp-dealintel-panel__countdown-note {
    margin-left: 0;
  }

  body.restaurant-menu-page .mp-dealintel-rewards {
    grid-template-columns: 1fr;
  }

  body.restaurant-menu-page .mp-dealintel-metrics {
    grid-template-columns: 1fr;
  }
}

/* ---- Deals page: spotlight + catalog ---- */

body.restaurant-menu-page .mp-deals-page {
  padding-top: var(--sp-6);
}

body.restaurant-menu-page .mp-deals-spotlight {
  display: grid;
  grid-template-columns: 1.4fr minmax(200px, 0.8fr);
  gap: var(--sp-5);
  align-items: stretch;
  padding: 24px 28px;
  margin-bottom: var(--sp-6);
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.04);
}

body.restaurant-menu-page .mp-deals-spotlight--app {
  border-color: rgba(99, 102, 241, 0.18);
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 55%, #eef2ff 100%);
}

body.restaurant-menu-page .mp-deals-spotlight__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #4338ca;
  background: #eef2ff;
  border: 1px solid rgba(99, 102, 241, 0.15);
  margin-bottom: 12px;
}

body.restaurant-menu-page .mp-deals-spotlight--app .mp-deals-spotlight__badge::before {
  content: '';
  width: 14px;
  height: 14px;
  background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234338ca' stroke-width='2'%3E%3Crect x='5' y='2' width='14' height='20' rx='3'/%3E%3Cline x1='12' y1='18' x2='12' y2='18.01'/%3E%3C/svg%3E");
}

body.restaurant-menu-page .mp-deals-spotlight__title {
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0 0 10px;
  color: var(--text);
}

body.restaurant-menu-page .mp-deals-spotlight__desc {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0;
  max-width: 52ch;
}

body.restaurant-menu-page .mp-deals-spotlight__aside {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 10px;
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
}

body.restaurant-menu-page .mp-deals-spotlight--app .mp-deals-spotlight__aside {
  background: rgba(255, 255, 255, 0.85);
}

body.restaurant-menu-page .mp-deals-spotlight__save {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  margin: 0;
  line-height: 1;
}

body.restaurant-menu-page .mp-deals-spotlight__timer {
  font-size: 12px;
  font-weight: 600;
  color: #b45309;
  margin: 0;
  font-variant-numeric: tabular-nums;
}

body.restaurant-menu-page .mp-deals-spotlight__cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}

body.restaurant-menu-page .mp-deals-spotlight__cta:hover {
  border-color: var(--border-strong);
  background: var(--surface-alt);
}

body.restaurant-menu-page .mp-deals-page__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-4);
  flex-wrap: wrap;
  margin-bottom: var(--sp-4);
  padding-bottom: var(--sp-3);
  border-bottom: 1px solid var(--border);
}

body.restaurant-menu-page .mp-deals-page__note {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
  max-width: 36ch;
  line-height: 1.45;
}

body.restaurant-menu-page .mp-deals-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-4);
}

body.restaurant-menu-page .mp-deals-card {
  display: flex;
  flex-direction: column;
  padding: 20px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface);
  min-height: 100%;
}

body.restaurant-menu-page .mp-deals-card--featured {
  border-color: rgba(99, 102, 241, 0.22);
  box-shadow: inset 0 0 0 1px rgba(99, 102, 241, 0.06);
}

body.restaurant-menu-page .mp-deals-card--scheduled {
  opacity: 0.72;
}

body.restaurant-menu-page .mp-deals-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

body.restaurant-menu-page .mp-deals-card__source {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

body.restaurant-menu-page .mp-deals-card__flag {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2ff;
  color: #4338ca;
}

body.restaurant-menu-page .mp-deals-card__flag--muted {
  background: var(--surface-alt);
  color: var(--text-muted);
}

body.restaurant-menu-page .mp-deals-card__title {
  font-size: 17px;
  font-weight: 700;
  margin: 0 0 8px;
  line-height: 1.3;
  color: var(--text);
}

body.restaurant-menu-page .mp-deals-card__desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0 0 12px;
  flex: 1;
}

body.restaurant-menu-page .mp-deals-card__facts {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

body.restaurant-menu-page .mp-deals-card__facts li {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--surface-alt);
  color: var(--text-muted);
}

body.restaurant-menu-page .mp-deals-card__code {
  font-family: ui-monospace, monospace;
  color: #15803d;
  background: #f0fdf4 !important;
}

body.restaurant-menu-page .mp-deals-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

body.restaurant-menu-page .mp-deals-card__save {
  font-size: 14px;
  font-weight: 700;
  color: #15803d;
}

body.restaurant-menu-page .mp-deals-card__exp {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

@media (max-width: 900px) {
  body.restaurant-menu-page .mp-deals-spotlight {
    grid-template-columns: 1fr;
  }

  body.restaurant-menu-page .mp-deals-grid {
    grid-template-columns: 1fr;
  }
}
