.frame-preview-surface {
  min-height: clamp(28rem, 46vw, 46rem);
  align-content: end;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 22%, color-mix(in srgb, var(--frame-tone-c) 46%, transparent), transparent 24%),
    radial-gradient(circle at 72% 14%, color-mix(in srgb, var(--frame-tone-b) 38%, transparent), transparent 26%),
    linear-gradient(135deg, var(--frame-tone-a), var(--frame-tone-b) 58%, var(--frame-tone-c));
  box-shadow:
    inset 0 1px rgba(255, 255, 255, 0.3),
    inset 0 -80px 140px rgba(7, 29, 27, 0.44),
    0 1.4rem 3rem rgba(13, 34, 29, 0.14);
}

.frame-preview-surface::before {
  content: "";
  position: absolute;
  inset: -18%;
  background:
    linear-gradient(115deg, transparent 0 38%, rgba(255, 255, 255, 0.11) 46%, transparent 55%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.045) 0 1px, transparent 1px 22px);
  mix-blend-mode: screen;
  opacity: 0.78;
  pointer-events: none;
}

.frame-preview-image,
.frame-library-swatch img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 0;
}

.frame-preview-image {
  filter: saturate(1.04) contrast(1.03);
}

.frame-preview-surface::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  block-size: 48%;
  background: linear-gradient(180deg, transparent, rgba(6, 23, 21, 0.85));
  pointer-events: none;
}

.frame-preview-copy-live {
  position: relative;
  z-index: 3;
  max-width: min(48rem, 92%);
  padding: clamp(1.3rem, 3vw, 2rem);
  margin: 0;
  display: grid;
  gap: 0.95rem;
  color: #fffaf2;
}

.frame-preview-copy-live strong {
  font-family: "Tomato Grotesk", Jost, sans-serif;
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.05em;
  font-size: clamp(2.4rem, 5.4vw, 6rem);
  text-wrap: balance;
}

.frame-preview-copy-live > small {
  color: rgba(255, 250, 242, 0.78);
  font-family: "Apercu Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-preview-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.frame-preview-kicker span,
.frame-preview-kicker em {
  border-radius: 999px;
  border: 1px solid rgba(255, 250, 242, 0.24);
  background: rgba(255, 250, 242, 0.12);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0.42rem 0.62rem;
  font-family: "Apercu Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-style: normal;
  color: rgba(255, 250, 242, 0.84);
}

.frame-preview-kicker span {
  background: rgba(214, 230, 223, 0.2);
  color: #fffaf2;
}

.frame-preview-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.62rem;
  max-width: 32rem;
}

.frame-preview-meta-grid span {
  display: grid;
  gap: 0.12rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 250, 242, 0.16);
  background: rgba(255, 250, 242, 0.1);
  padding: 0.72rem 0.82rem;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.frame-preview-meta-grid small {
  font-family: "Apercu Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.62rem;
  color: rgba(255, 250, 242, 0.66);
}

.frame-preview-meta-grid b {
  font-weight: 700;
  font-size: 0.98rem;
  color: #fffaf2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.frame-preview-note {
  max-width: 34rem;
  margin: 0;
  color: rgba(255, 250, 242, 0.79);
  font-size: 1rem;
  line-height: 1.35;
}

.frame-preview-orb {
  opacity: 0.34;
  filter: blur(18px);
  z-index: 1;
}

.frame-preview-mesh {
  opacity: 0.34;
  z-index: 1;
}

.frame-library-swatch {
  position: relative;
  overflow: hidden;
}

.frame-library-swatch-button {
  appearance: none;
  border: 0;
  color: inherit;
  cursor: pointer;
  padding: 0;
  text-align: left;
  inline-size: 100%;
}

.frame-library-swatch-button:focus-visible {
  outline: 2px solid rgba(21, 53, 48, 0.72);
  outline-offset: 3px;
}

.frame-library-swatch::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(9, 31, 28, 0) 38%, rgba(9, 31, 28, 0.72) 100%),
    radial-gradient(circle at 16% 18%, rgba(255, 250, 242, 0.18), transparent 32%);
  pointer-events: none;
}

.frame-library-swatch .frame-library-sheen,
.frame-library-swatch span {
  position: relative;
  z-index: 2;
}

.frame-library-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.frame-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.frame-filter-chip {
  appearance: none;
  border: 1px solid rgba(53, 83, 74, 0.12);
  background: rgba(255, 252, 247, 0.68);
  color: rgba(21, 53, 48, 0.72);
  border-radius: 999px;
  padding: 0.48rem 0.62rem;
  display: inline-flex;
  gap: 0.44rem;
  align-items: center;
  cursor: pointer;
}

.frame-filter-chip span,
.frame-filter-chip small {
  font-family: "Apercu Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-filter-chip span {
  font-size: 0.68rem;
}

.frame-filter-chip small {
  min-width: 1.35rem;
  min-height: 1.35rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(53, 83, 74, 0.08);
  font-size: 0.62rem;
}

.frame-filter-chip.active {
  background: rgba(214, 230, 223, 0.82);
  border-color: rgba(53, 83, 74, 0.22);
  color: #153530;
}

.frame-rotation-panel {
  display: grid;
  gap: 0.8rem;
  border-radius: 1.35rem;
  border: 1px solid rgba(53, 83, 74, 0.12);
  background: linear-gradient(145deg, rgba(255, 252, 247, 0.74), rgba(214, 230, 223, 0.36));
  padding: 0.95rem;
}

.frame-rotation-copy {
  display: grid;
  gap: 0.18rem;
}

.frame-rotation-copy span,
.frame-rotation-copy small,
.frame-rotation-toggles span {
  font-family: "Apercu Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-rotation-copy span,
.frame-rotation-copy small {
  color: rgba(21, 53, 48, 0.62);
  font-size: 0.68rem;
}

.frame-rotation-copy strong {
  color: #153530;
  font-size: 1rem;
  line-height: 1.2;
}

.frame-rotation-toggles {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
}

.frame-rotation-toggles label {
  display: inline-flex;
  gap: 0.42rem;
  align-items: center;
  color: rgba(21, 53, 48, 0.72);
}

.frame-rotation-toggles span {
  font-size: 0.66rem;
}

.frame-rotation-auto {
  display: grid;
  gap: 0.75rem;
  border-top: 1px solid rgba(53, 83, 74, 0.1);
  padding-top: 0.8rem;
}

.frame-rotation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: end;
}

.frame-rotation-status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}

.frame-rotation-status-grid span {
  min-height: 3.5rem;
  border-radius: 1rem;
  border: 1px solid rgba(53, 83, 74, 0.1);
  background: rgba(255, 252, 247, 0.5);
  color: rgba(21, 53, 48, 0.68);
  padding: 0.55rem 0.62rem;
  font-size: 0.74rem;
  line-height: 1.18;
}

.frame-rotation-status-grid b {
  display: block;
  color: rgba(21, 53, 48, 0.48);
  font-family: "Apercu Mono", monospace;
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  margin-bottom: 0.2rem;
  text-transform: uppercase;
}

.frame-rotation-status-grid .is-error {
  border-color: rgba(173, 72, 50, 0.22);
  background: rgba(255, 239, 228, 0.68);
  color: #8b2d1f;
}

.frame-rotation-select-wrap {
  display: grid;
  gap: 0.32rem;
}

.frame-rotation-select-wrap span {
  color: rgba(21, 53, 48, 0.62);
  font-family: "Apercu Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-rotation-select {
  min-height: 2.7rem;
  border: 1px solid rgba(53, 83, 74, 0.14);
  border-radius: 999px;
  background: rgba(255, 252, 247, 0.72);
  color: #153530;
  padding: 0 0.85rem;
  font: inherit;
}

@media (max-width: 760px) {
  .frame-rotation-status-grid {
    grid-template-columns: 1fr;
  }
}

.frame-qa-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.38rem;
  align-items: center;
  margin-top: 0.18rem;
}

.frame-qa-chip {
  border-radius: 999px;
  border: 1px solid rgba(53, 83, 74, 0.12);
  background: rgba(255, 252, 247, 0.72);
  color: rgba(21, 53, 48, 0.72);
  padding: 0.28rem 0.46rem;
  font-family: "Apercu Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-qa-chip.is-good,
.frame-qa-chip.is-live {
  background: rgba(214, 230, 223, 0.72);
  color: #153530;
  border-color: rgba(53, 83, 74, 0.16);
}

.frame-qa-chip.is-warn {
  background: rgba(251, 205, 130, 0.34);
  color: #6e4a10;
  border-color: rgba(214, 162, 109, 0.26);
}

.frame-review-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: clamp(1rem, 3vw, 2rem);
  background: rgba(10, 30, 27, 0.34);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.frame-review-shell {
  width: min(74rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  overflow: auto;
  border-radius: 2rem;
  border: 1px solid rgba(255, 255, 255, 0.46);
  background: linear-gradient(145deg, rgba(255, 250, 242, 0.96), rgba(226, 239, 232, 0.92));
  box-shadow: 0 2rem 5rem rgba(13, 34, 29, 0.28), inset 0 1px rgba(255, 255, 255, 0.76);
  padding: clamp(1rem, 2vw, 1.4rem);
  display: grid;
  gap: 1rem;
}

.frame-review-head,
.frame-review-actions,
.frame-review-meta {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.frame-review-head h3 {
  margin: 0.2rem 0 0;
  font-family: "Tomato Grotesk", Jost, sans-serif;
  font-weight: 400;
  line-height: 0.96;
  letter-spacing: -0.04em;
  font-size: clamp(1.8rem, 3vw, 3.2rem);
  max-width: 20ch;
}

.frame-review-close {
  appearance: none;
  border: 1px solid rgba(53, 83, 74, 0.14);
  background: rgba(255, 252, 247, 0.76);
  color: #153530;
  border-radius: 999px;
  padding: 0.72rem 0.9rem;
  cursor: pointer;
  font-weight: 700;
}

.frame-review-video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 1.35rem;
  border: 1px solid rgba(53, 83, 74, 0.12);
  background: #071d1b;
  min-height: 18rem;
}

.frame-review-video-shell video,
.frame-review-video-shell img {
  display: block;
  width: 100%;
  max-height: min(62vh, 42rem);
  object-fit: contain;
  background: #071d1b;
}

.frame-qa-chip-row-modal {
  margin-top: 0;
}

.frame-review-meta {
  justify-content: flex-start;
}

.frame-review-meta span {
  border-radius: 999px;
  border: 1px solid rgba(53, 83, 74, 0.1);
  background: rgba(255, 252, 247, 0.68);
  padding: 0.46rem 0.62rem;
  color: rgba(21, 53, 48, 0.66);
  font-family: "Apercu Mono", monospace;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.frame-review-meta b {
  color: #153530;
}

.frame-delete-button {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(98, 54, 42, 0.58);
  cursor: pointer;
  padding: 0.35rem 0.2rem;
  font-family: "Apercu Mono", monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 0.22rem;
  text-decoration-thickness: 1px;
}

.frame-delete-button:hover:not(:disabled) {
  color: rgba(142, 50, 31, 0.88);
}

.frame-delete-button:disabled {
  cursor: default;
  opacity: 0.28;
  text-decoration: none;
}

@media (max-width: 860px) {
  .frame-preview-surface {
    min-height: 28rem;
  }

  .frame-preview-meta-grid {
    grid-template-columns: 1fr;
  }

  .frame-preview-copy-live strong {
    font-size: clamp(2rem, 12vw, 3.6rem);
  }
}
