/* POURA v0.5.6 — solid overlays, membership source clarity and reliable controls */

/* Every interactive overlay has an opaque, theme-safe surface. */
.v051-modal-backdrop,
.food-amount-backdrop,
.aiw-modal,
.v13-programme-modal,
.v13-swap-modal,
.v13-feedback-modal,
.confirm-overlay,
.modal-overlay {
  background: rgba(3, 5, 8, .82) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  backdrop-filter: blur(10px) !important;
}

.v051-modal,
.food-amount-dialog,
.aiw-dialog,
.v13-programme-dialog,
.v13-swap-dialog,
.v13-feedback-dialog,
.confirm-dialog,
.modal-dialog,
.modal-content {
  background: #11151b !important;
  background-image: none !important;
  opacity: 1 !important;
  border: 1px solid rgba(255,255,255,.14) !important;
  box-shadow: 0 28px 90px rgba(0,0,0,.58) !important;
}

html[data-theme="light"] .v051-modal,
html[data-theme="light"] .food-amount-dialog,
html[data-theme="light"] .aiw-dialog,
html[data-theme="light"] .v13-programme-dialog,
html[data-theme="light"] .v13-swap-dialog,
html[data-theme="light"] .v13-feedback-dialog,
html[data-theme="light"] .confirm-dialog,
html[data-theme="light"] .modal-dialog,
html[data-theme="light"] .modal-content {
  background: #ffffff !important;
  border-color: rgba(17,24,39,.16) !important;
  box-shadow: 0 28px 80px rgba(15,23,42,.22) !important;
}

.v051-modal .input,
.food-amount-dialog .input,
.aiw-dialog .input,
.v13-programme-dialog .input,
.v13-swap-dialog .input,
.v13-feedback-dialog .input,
.v051-modal-section,
.aiw-dialog .card,
.v13-programme-dialog .card,
.v13-swap-dialog .card,
.v13-feedback-dialog .card {
  opacity: 1 !important;
}

html[data-theme="dark"] .v051-modal-section,
html[data-theme="dark"] .aiw-dialog .card,
html[data-theme="dark"] .v13-programme-dialog .card,
html[data-theme="dark"] .v13-swap-dialog .card,
html[data-theme="dark"] .v13-feedback-dialog .card {
  background: #171c23 !important;
  border-color: rgba(255,255,255,.1) !important;
}

html[data-theme="light"] .v051-modal-section,
html[data-theme="light"] .aiw-dialog .card,
html[data-theme="light"] .v13-programme-dialog .card,
html[data-theme="light"] .v13-swap-dialog .card,
html[data-theme="light"] .v13-feedback-dialog .card {
  background: #f7f8fa !important;
  border-color: rgba(17,24,39,.1) !important;
}

/* Search results are real cards instead of transparent inherited food rows. */
.v054-search-result { display: none !important; }
.v055-exercise-result {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 14px;
  margin: 0 0 8px;
  text-align: left;
  color: inherit;
  background: #171c23;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  box-shadow: 0 8px 22px rgba(0,0,0,.16);
  cursor: pointer;
  opacity: 1;
}
.v055-exercise-result:hover,
.v055-exercise-result:focus-visible {
  border-color: var(--primary, #ff5a1f);
  transform: translateY(-1px);
  outline: none;
}
html[data-theme="light"] .v055-exercise-result {
  background: #ffffff;
  border-color: rgba(17,24,39,.13);
  box-shadow: 0 7px 20px rgba(15,23,42,.08);
}
.v055-exercise-copy { display: flex; flex: 1 1 auto; min-width: 0; flex-direction: column; gap: 4px; }
.v055-exercise-copy strong { display: block; min-width: 0; overflow-wrap: anywhere; font-size: .96rem; line-height: 1.25; }
.v055-exercise-copy small { display: block; min-width: 0; overflow-wrap: anywhere; color: var(--text-dim); line-height: 1.35; }
.v055-exercise-action {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 34px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255,90,31,.14);
  color: var(--primary, #ff5a1f);
  font-weight: 800;
  font-size: .78rem;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.v055-ai-generate { border-style: dashed; }

/* Membership level and source presentation. */
.v055-global-user {
  grid-template-columns: minmax(190px,1.15fr) minmax(90px,.55fr) minmax(140px,.72fr) minmax(210px,1.35fr) minmax(82px,.46fr) auto !important;
  align-items: center;
}
.v055-plan-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  padding: 5px 10px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-size: .72rem;
  line-height: 1;
  font-weight: 850;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.v055-plan-free { color: #8a94a6; }
.v055-plan-plus { color: #4d9fff; }
.v055-plan-pro { color: #b987ff; }
.v055-plan-source { display: block; margin-top: 6px; color: var(--text-dim); }
.v055-workspace-list { display: flex; flex-wrap: wrap; gap: 5px; }
.v055-plan-title { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.v055-plan-title h3 { margin: 0; }
.v055-plan-card { border-width: 1px; }
.v055-plan-card.v055-plan-pro { border-color: rgba(185,135,255,.45); }
.v055-plan-card.v055-plan-plus { border-color: rgba(77,159,255,.45); }

.v055-membership-grid,
.v055-contract-metrics {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 10px;
  margin: 14px 0;
}
.v055-membership-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.v055-membership-grid > div,
.v055-contract-metrics > article {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 13px;
  border: 1px solid rgba(127,127,127,.18);
  border-radius: 12px;
  background: rgba(127,127,127,.07);
}
.v055-membership-grid small,
.v055-contract-metrics span,
.v055-sponsored-list > small { color: var(--text-dim); }
.v055-membership-grid span { color: var(--text-dim); font-size: .82rem; overflow-wrap: anywhere; }
.v055-contract-metrics strong { font-size: 1.45rem; line-height: 1; }
.v055-sponsored-list > div { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 7px; }
.v055-sponsored-contract { margin: 16px 0; }
.v055-contract-save { display: flex; align-items: end; justify-content: flex-end; }
.v055-pro-locked { position: relative; border-style: dashed !important; }

/* A set tap is immediately locked while the idempotent request is in flight. */
.set-check.is-saving {
  pointer-events: none;
  opacity: .62;
  position: relative;
}
.set-check.is-saving::after {
  content: '';
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: v055-spin .7s linear infinite;
}
@keyframes v055-spin { to { transform: rotate(360deg); } }

@media (max-width: 980px) {
  .v055-global-user { grid-template-columns: 1fr !important; gap: 9px; }
  .v055-contract-metrics { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media (max-width: 620px) {
  .v055-membership-grid,
  .v055-contract-metrics { grid-template-columns: 1fr; }
  .v055-exercise-result { align-items: flex-start; }
  .v055-exercise-action { min-width: 38px; }
}

.v055-plan-actions{display:flex;align-items:center;justify-content:flex-end;gap:.55rem;flex-wrap:wrap}
