.pricing-os-shell{
  max-width:1680px;
}

.pricing-os-topbar{
  align-items:center;
}

.pricing-os-actions{
  min-width:260px;
}

.pricing-os-hero,
.pricing-summary-grid,
.pricing-os-layout{
  margin-top:18px;
}

.pricing-os-hero{
  background:
    radial-gradient(circle at top right, rgba(212,177,112,.13), transparent 28%),
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01)),
    rgba(24,24,24,.93);
}

.hero-owner-summary{
  padding:16px 18px;
  border-radius:18px;
  border:1px solid rgba(212,177,112,.18);
  background:rgba(255,255,255,.03);
  color:rgba(255,255,255,.9);
  line-height:1.58;
}

.compact-bottom{
  margin-bottom:14px;
}

.wrap-actions{
  flex-wrap:wrap;
}

.top-gap{margin-top:16px}
.top-gap-sm{margin-top:10px}
.no-margin{margin:0 !important}
.no-top-margin{margin-top:0 !important}

.flow-shell{
  margin-top:16px;
}

.flow-label-row{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:10px;
  margin-bottom:10px;
  color:var(--muted);
  font-size:.88rem;
  text-transform:uppercase;
  letter-spacing:.08em;
}

.flow-chart{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:12px;
}

.flow-stage{
  display:flex;
  flex-direction:column;
  gap:10px;
  padding:14px;
  border-radius:18px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.03);
  min-height:122px;
}

.flow-stage strong{
  font-size:1.65rem;
  line-height:1;
}

.flow-track{
  position:relative;
  height:10px;
  border-radius:999px;
  overflow:hidden;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.04);
}

.flow-fill{
  position:absolute;
  inset:0 auto 0 0;
  border-radius:999px;
  background:linear-gradient(135deg, rgba(212,177,112,.92), rgba(239,201,123,.62));
}

.flow-stage small,
.helper-text{
  color:var(--muted);
  line-height:1.5;
}

.pricing-summary-grid{
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:16px;
}

.compact-card{
  min-height:128px;
}

.compact-card strong{
  font-size:1.92rem;
}

.pricing-os-layout{
  display:grid;
  grid-template-columns:minmax(300px,.92fr) minmax(400px,1.26fr) minmax(320px,.96fr);
  gap:18px;
  align-items:start;
}

.intake-card,
.master-card{
  grid-column:1;
}

.mapping-card{
  grid-column:2;
  grid-row:1 / span 2;
}

.rules-card,
.release-card{
  grid-column:3;
}

.compact-history-head h3{
  margin:6px 0 0;
}

.compact-head{
  margin-bottom:12px;
}

.subsection-title{
  font-size:1rem;
}

.ghost-select,
.file-input{
  min-width:160px;
}

.file-input{
  max-width:240px;
  padding:11px 12px;
}

.standalone-field{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.standalone-field.full{
  width:100%;
}

.standalone-field textarea{
  min-height:138px;
  resize:vertical;
}

.fixed-height-list{
  min-height:220px;
  max-height:420px;
  overflow:auto;
  padding-right:6px;
}

.tall-list{
  max-height:960px;
}

.compact-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.list-stack .empty-state{
  min-height:auto;
}

.batch-card,
.row-card,
.master-item,
.release-card-item,
.bridge-card{
  border:1px solid var(--line);
  border-radius:18px;
  background:rgba(255,255,255,.03);
  padding:14px 15px;
}

.batch-card{
  cursor:pointer;
  transition:border-color .15s ease, transform .15s ease, background .15s ease;
}

.batch-card:hover,
.row-card:hover{
  transform:translateY(-1px);
  border-color:rgba(212,177,112,.24);
}

.batch-card.is-active,
.row-card.is-selected{
  border-color:rgba(212,177,112,.38);
  background:linear-gradient(180deg, rgba(212,177,112,.10), rgba(255,255,255,.03));
  box-shadow:0 16px 34px rgba(0,0,0,.18);
}

.batch-card-head,
.row-card-head,
.release-card-head,
.master-item-head,
.bridge-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
}

.batch-card-head strong,
.row-card-head strong,
.release-card-head strong,
.master-item-head strong{
  font-size:1rem;
}

.batch-card-meta,
.row-card-meta,
.release-card-meta,
.master-item-meta{
  margin-top:10px;
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

.meta-chip,
.badge-chip,
.master-chip,
.status-chip{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:8px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.03);
  color:rgba(255,255,255,.88);
  font-size:.85rem;
  line-height:1;
}

.meta-chip strong,
.badge-chip strong,
.master-chip strong,
.status-chip strong{
  font-size:.85rem;
}

.status-batch-released,
.status-decision-released,
.status-map-mapped,
.status-tone-success{
  border-color:rgba(78,138,89,.32);
  background:rgba(78,138,89,.12);
}

.status-batch-ready,
.status-decision-approved,
.status-tone-accent{
  border-color:rgba(212,177,112,.34);
  background:rgba(212,177,112,.12);
}

.status-batch-review,
.status-decision-pending,
.status-map-review,
.status-tone-neutral{
  border-color:rgba(123,129,141,.3);
  background:rgba(123,129,141,.16);
}

.status-batch-needs_review,
.status-batch-received,
.status-decision-hold,
.status-map-unmapped,
.status-tone-danger{
  border-color:rgba(185,74,72,.34);
  background:rgba(185,74,72,.14);
}

.batch-stat-grid,
.row-stat-grid,
.bridge-grid,
.release-row-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin-top:12px;
}

.batch-stat,
.row-stat,
.bridge-metric,
.release-row-metric{
  padding:10px 11px;
  border-radius:14px;
  background:rgba(255,255,255,.025);
  border:1px solid rgba(255,255,255,.05);
}

.batch-stat span,
.row-stat span,
.bridge-metric span,
.release-row-metric span{
  display:block;
  color:var(--muted);
  font-size:.78rem;
  text-transform:uppercase;
  letter-spacing:.08em;
  margin-bottom:5px;
}

.batch-stat strong,
.row-stat strong,
.bridge-metric strong,
.release-row-metric strong{
  font-size:1rem;
}

.row-card{
  cursor:pointer;
}

.row-card-copy{
  display:flex;
  flex-direction:column;
  gap:6px;
}

.row-title-line{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
}

.row-subline{
  color:var(--muted);
  font-size:.93rem;
}

.row-flag-row,
.audit-row,
.badge-row{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

.row-actions{
  margin-top:12px;
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.mini-select{
  min-width:220px;
  max-width:100%;
}

.mini-btn{
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.04);
  color:var(--text);
  cursor:pointer;
}

.mini-btn:hover{
  transform:translateY(-1px);
}

.mini-btn.approve{
  border-color:rgba(212,177,112,.32);
  background:rgba(212,177,112,.14);
}

.mini-btn.hold{
  border-color:rgba(185,74,72,.34);
  background:rgba(185,74,72,.14);
}

.mini-btn.pending{
  border-color:rgba(123,129,141,.3);
  background:rgba(123,129,141,.16);
}

.rules-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}

.rules-grid label{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.selected-row-shell{
  margin-top:16px;
  padding:14px;
  border-radius:18px;
  border:1px solid var(--line);
  background:rgba(255,255,255,.025);
}

.chart-shell{
  padding:14px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,.06);
  background:rgba(255,255,255,.02);
}

.chart-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
  margin-bottom:12px;
}

.chart-head h4{
  margin:0;
  font-size:.98rem;
}

.chart-head span{
  color:var(--muted);
  font-size:.86rem;
}

.chart-empty{
  padding:16px;
  border-radius:16px;
  border:1px dashed rgba(255,255,255,.08);
  color:var(--muted);
  background:rgba(255,255,255,.02);
}

.bar-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.bar-row{
  display:grid;
  grid-template-columns:minmax(96px,120px) minmax(0,1fr) auto;
  gap:10px;
  align-items:center;
}

.bar-label{
  font-size:.9rem;
  color:rgba(255,255,255,.9);
}

.bar-track{
  position:relative;
  height:14px;
  border-radius:999px;
  overflow:hidden;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.05);
}

.bar-fill{
  position:absolute;
  inset:0 auto 0 0;
  border-radius:999px;
  background:linear-gradient(135deg, rgba(212,177,112,.95), rgba(239,201,123,.58));
}

.bar-value{
  font-size:.88rem;
  color:rgba(255,255,255,.92);
}

.chart-note{
  margin-top:10px;
  color:var(--muted);
  font-size:.86rem;
  line-height:1.5;
}

.bridge-summary{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.bridge-grid{
  grid-template-columns:repeat(3,minmax(0,1fr));
}

.bridge-card p,
.release-card-item p,
.master-item p,
.batch-card p,
.row-card p{
  margin:8px 0 0;
  color:rgba(255,255,255,.82);
  line-height:1.5;
}

.master-list-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}

.master-item{
  min-height:150px;
}

.release-card-item + .release-card-item{
  margin-top:12px;
}

.release-rows-preview{
  margin-top:12px;
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

.release-row-pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 10px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.07);
  background:rgba(255,255,255,.03);
  font-size:.85rem;
}

.accent-btn{
  border-color:rgba(212,177,112,.34);
  background:rgba(212,177,112,.12);
}

.batch-footer,
.row-footer,
.release-footer{
  margin-top:12px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
  color:var(--muted);
  font-size:.84rem;
}

.owner-summary-line{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:12px;
}

.inline-link{
  color:var(--gold-strong);
  text-decoration:none;
}

.inline-link:hover{
  text-decoration:underline;
}

@media (max-width: 1480px){
  .pricing-summary-grid{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }

  .pricing-os-layout{
    grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  }

  .mapping-card{
    grid-column:1 / -1;
    grid-row:auto;
  }

  .rules-card,
  .release-card{
    grid-column:auto;
  }
}

@media (max-width: 980px){
  .pricing-summary-grid,
  .pricing-os-layout,
  .bridge-grid,
  .master-list-grid,
  .rules-grid,
  .flow-chart,
  .flow-label-row{
    grid-template-columns:1fr;
  }

  .batch-stat-grid,
  .row-stat-grid,
  .release-row-grid{
    grid-template-columns:1fr;
  }

  .bar-row{
    grid-template-columns:1fr;
  }

  .bar-track{
    height:12px;
  }

  .pricing-os-topbar,
  .batch-card-head,
  .row-card-head,
  .release-card-head,
  .master-item-head,
  .bridge-head,
  .section-head{
    flex-direction:column;
    align-items:flex-start;
  }

  .topbar-actions,
  .row-actions{
    width:100%;
  }

  .mini-select{
    min-width:unset;
    width:100%;
  }
}
