@import url("review.css");
@font-face {
  font-family: Manrope;
  font-display: swap;
  src: url("assets/manrope-400.ttf");
}
@font-face {
  font-family: Manrope;
  font-display: swap;
  src: url("assets/manrope-500.ttf");
  font-weight: 500;
}
@font-face {
  font-family: Manrope;
  font-display: swap;
  src: url("assets/manrope-600.ttf");
  font-weight: 600;
}
@font-face {
  font-family: Manrope;
  font-display: swap;
  src: url("assets/manrope-700.ttf");
  font-weight: 700;
}
:root {
  --bg: #f3f5f8;
  --surface: #fff;
  --panel: #fff;
  --raised: #eef2f8;
  --ink: #fff;
  --elevated: #eef2f8;
  --text: #172238;
  --muted: #566277;
  --accent: #2658df;
  --accent-soft: #e7edff;
  --line: #dbe1eb;
  --danger: #b72539;
  --radius: 16px;
  font-family: Manrope, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  padding: 11px 17px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: white;
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s,
    border-color 0.15s;
}
button:hover,
.button:hover {
  background: var(--elevated);
  border-color: #bcc8dc;
  text-decoration: none;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}
.primary:hover {
  background: #1946bd;
  border-color: #1946bd;
}
.danger {
  color: var(--danger);
  border-color: #e4bdc3;
}
.text-button,
.ghost {
  border-color: transparent;
  background: transparent;
}
.icon-button {
  min-width: 46px;
  padding: 10px;
  flex-shrink: 0;
}
.icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 34px;
  letter-spacing: -1.1px;
  line-height: 1.2;
  font-weight: 600;
}
h2 {
  font-size: 19px;
  line-height: 1.4;
  letter-spacing: -0.4px;
  font-weight: 600;
}
h3 {
  font-size: 16px;
  font-weight: 600;
}
p {
  font-size: 15px;
  line-height: 1.65;
}
small {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.55;
}
input,
textarea,
select {
  color: var(--text);
  border: 1px solid #b8c4d7;
  border-radius: 10px;
  background: white;
  padding: 12px;
  width: 100%;
  min-width: 0;
  font-size: 16px;
}
textarea {
  resize: vertical;
  min-height: 88px;
}
input[type="checkbox"],
input[type="radio"] {
  width: 19px;
  height: 19px;
  padding: 0;
  margin: 0;
  accent-color: var(--accent);
  flex-shrink: 0;
}
input[type="color"] {
  width: 100%;
  height: 48px;
  padding: 5px;
  cursor: pointer;
}
input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent);
}
:focus-visible {
  outline: 3px solid #79a2ff;
  outline-offset: 3px;
}
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline-offset: 4px;
}
button:active {
  background: #e8eefc;
}
.primary:active {
  background: #153b9d;
}
[hidden] {
  display: none !important;
}
.muted {
  color: var(--muted);
}
.sr-only,
.skip-link:not(:focus) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.skip-link:focus {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  background: white;
  padding: 12px;
}
.appbar {
  height: 88px;
  max-width: 1280px;
  margin: auto;
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.wordmark {
  display: flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -1.3px;
}
.wordmark:hover {
  text-decoration: none;
}
.wordmark img {
  width: 35px;
  height: 35px;
}
.bar-actions {
  display: flex;
  gap: 18px;
  align-items: center;
}
.balance-link {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  min-height: 44px;
  display: flex;
  align-items: center;
}
.preview-tag {
  font-size: 11px;
  color: var(--muted);
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
}
.menu {
  position: relative;
  z-index: 5;
}
.menu > summary {
  list-style: none;
  cursor: pointer;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 14px;
  font-weight: 600;
}
.menu > summary::-webkit-details-marker {
  display: none;
}
.menu[open] > summary,
.menu > summary:hover {
  background: var(--elevated);
}
.menu > nav,
.menu > div {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: white;
  border: 1px solid var(--line);
  padding: 7px;
  min-width: 224px;
  box-shadow: 0 12px 36px #17223818;
  border-radius: 14px;
  display: grid;
  gap: 2px;
}
.menu a,
.menu button {
  display: flex;
  justify-content: flex-start;
  padding: 12px;
  font-size: 14px;
  color: var(--text);
  border: 0;
  min-height: 44px;
  white-space: nowrap;
  border-radius: 7px;
}
.menu a:hover {
  background: var(--elevated);
  text-decoration: none;
}
.page {
  max-width: 1240px;
  padding: 48px 40px 80px;
  margin: auto;
}
.page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}
.video-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 30px 24px;
}
.video-card {
  min-width: 0;
  position: relative;
}
.poster-link {
  color: var(--text);
  display: block;
}
.poster-link:hover {
  text-decoration: none;
}
.poster {
  height: 300px;
  border-radius: 18px;
  background: #dfe5ef;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  isolation: isolate;
}
.poster img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.poster-link:hover .poster img {
  filter: brightness(0.96);
}
.poster-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: #ffffffeb;
  color: var(--text);
  font-size: 11px;
  font-weight: 600;
  border-radius: 7px;
  padding: 5px 8px;
  max-width: calc(100% - 24px);
}
.duration {
  position: absolute;
  bottom: 12px;
  right: 12px;
  color: white;
  background: #172238d9;
  font-size: 12px;
  padding: 4px 7px;
  border-radius: 6px;
  font-variant-numeric: tabular-nums;
}
.video-card h2 {
  font-size: 15px;
  margin: 16px 0 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.video-card p {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  line-height: 1.5;
}
.video-card p span {
  margin-left: auto;
  font-weight: 600;
}
.card-download {
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  width: fit-content;
}
.card-download .icon {
  width: 16px;
  height: 16px;
}
.search {
  display: block;
  max-width: 360px;
  margin: -12px 0 28px;
}
.empty {
  min-height: 52vh;
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-content: center;
  align-items: center;
  text-align: center;
}
.empty h2 {
  font-size: 24px;
}
.empty p {
  color: var(--muted);
}
.empty-frame {
  width: 74px;
  height: 94px;
  border: 2px solid #b8c7e9;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: var(--accent);
  margin-bottom: 5px;
}
.empty-frame .icon {
  width: 28px;
  height: 28px;
}
.empty .primary {
  margin-top: 8px;
}
.row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.stack {
  display: grid;
  gap: 24px;
}
.field {
  display: grid;
  gap: 9px;
  font-size: 14px;
  font-weight: 500;
  min-width: 0;
}
.settings {
  max-width: 680px;
  display: grid;
  gap: 30px;
}
.disclosure {
  border-top: 1px solid var(--line);
  min-width: 0;
}
.disclosure > summary {
  list-style: none;
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 15px;
  font-weight: 500;
  min-height: 64px;
  cursor: pointer;
  padding: 14px 0;
}
.disclosure > summary::-webkit-details-marker {
  display: none;
}
.disclosure > summary:after {
  content: "+";
  font-size: 20px;
  margin-left: auto;
  color: var(--muted);
  font-weight: 400;
}
.disclosure[open] > summary:after {
  content: "−";
}
.disclosure > summary > span {
  font-size: 12px;
  color: var(--muted);
}
.disclosure-body {
  display: grid;
  gap: 20px;
  padding: 8px 0 28px;
}
.disclosure-body > button {
  justify-self: start;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.section-heading .menu > summary {
  color: var(--accent);
}
.asset-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.asset {
  min-width: 0;
  position: relative;
  background: white;
  border-radius: 12px;
  border: 1px solid var(--line);
  overflow: hidden;
}
.asset > label {
  display: block;
  cursor: pointer;
}
.asset img,
.asset video,
.font-sample {
  height: 130px;
  width: 100%;
  object-fit: contain;
  display: block;
  padding: 18px;
  background: #fff;
}
.asset video {
  padding: 0;
  background: #172238;
}
.font-sample {
  font-size: 58px;
  text-align: center;
}
.asset-caption {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  font-size: 12px;
  line-height: 1.4;
  min-height: 58px;
}
.asset-caption > span {
  overflow-wrap: anywhere;
  min-width: 0;
}
.asset-delete {
  position: absolute;
  right: 0;
  top: 0;
  background: #ffffffeb;
  min-height: 40px;
  min-width: 40px;
  padding: 9px;
  border: 0;
  border-radius: 0 0 0 10px;
}
.asset-delete .icon {
  width: 16px;
  height: 16px;
}
.reference-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.reference-grid video {
  height: 200px;
}
.reference-grid .asset-delete {
  top: 200px;
}
.color-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.save-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 8px;
}
.save-footer span {
  font-size: 12px;
  color: var(--muted);
}
.error-message {
  color: var(--danger);
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.error-message:empty {
  display: none;
}
.notice {
  background: var(--accent-soft);
  border-radius: 10px;
  padding: 14px 16px;
  color: #28416e;
  font-size: 14px;
}
.check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
  line-height: 1.6;
  font-weight: 400;
}
.check input {
  margin-top: 2px;
}
.check small {
  font-size: 12px;
}
.project-page {
  padding-top: 30px;
}
.project-head {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 34px;
  min-width: 0;
}
.project-head h1 {
  font-size: 23px;
  letter-spacing: -0.5px;
  min-width: 0;
  overflow-wrap: anywhere;
  flex: 1;
}
.back-link {
  display: flex;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
  min-height: 44px;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 48px;
  align-items: start;
}
.video-column {
  min-width: 0;
  display: grid;
  justify-items: center;
}
.player-stage {
  background: #e6eaf0;
  border-radius: 20px;
  min-width: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  overflow: hidden;
}
.player-stage video {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 640px;
  border-radius: 12px;
  background: #172238;
}
.player-meta {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  font-size: 12px;
  padding: 15px 4px;
  font-variant-numeric: tabular-nums;
}
.action-panel {
  background: white;
  border-radius: 20px;
  padding: 28px;
  min-width: 0;
  box-shadow: 0 2px 4px #17223803;
}
.result-actions {
  display: grid;
  gap: 16px;
}
.result-actions h2 {
  font-size: 24px;
}
.ready-label {
  color: #246744;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.result-actions .muted {
  font-size: 13px;
}
.result-actions .primary {
  margin-top: 8px;
}
.quality {
  margin-top: -10px;
  text-align: center;
  font-size: 11px;
}
.history {
  margin-top: 30px;
}
.history .disclosure-body {
  padding-bottom: 0;
  gap: 0;
}
.history .row {
  margin: 0 0 16px;
  gap: 8px;
}
.history .row button {
  flex: 1;
  font-size: 12px;
  padding: 9px 10px;
}
.history button[aria-pressed="true"] {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--accent);
}
.version-row {
  display: grid;
  gap: 5px;
  padding: 13px 0;
  color: var(--text);
  font-size: 12px;
  border-top: 1px solid #edf0f5;
}
.version-row[aria-current] {
  color: var(--accent);
}
.version-row small {
  font-size: 11px;
}
.styles {
  margin: 0;
  padding: 0;
  border: 0;
  display: grid;
  gap: 10px;
  min-width: 0;
}
.styles legend {
  font-size: 13px;
  color: var(--muted);
  padding: 0;
  margin-bottom: 10px;
}
.styles label {
  position: relative;
  display: flex;
  align-items: center;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
  gap: 12px;
}
.styles label:has(input:checked) {
  border-color: var(--accent);
  background: #f5f8ff;
}
.styles strong {
  font-size: 15px;
  font-weight: 600;
}
.styles small {
  display: block;
  font-size: 12px;
  margin-top: 3px;
}
.styles input {
  accent-color: var(--accent);
}
.brand-row {
  border-block: 1px solid var(--line);
  padding: 15px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: var(--text);
}
.start-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 4px;
}
.start-row > div {
  display: grid;
  gap: 4px;
}
.start-row strong {
  font-size: 21px;
}
.start-row small {
  font-size: 11px;
}
.start-row button {
  font-size: 13px;
}
.action-panel .disclosure > summary {
  font-size: 13px;
}
.action-panel .stack {
  gap: 24px;
}
.action-panel .review-notes {
  margin-top: 12px;
}
.action-panel .field {
  font-size: 13px;
}
.action-panel textarea {
  font-size: 14px;
}
.waiting {
  display: grid;
  gap: 20px;
  padding: 24px 0;
  text-align: center;
  justify-items: center;
}
.waiting h2 {
  font-size: 19px;
}
.waiting p {
  color: var(--muted);
  font-size: 13px;
}
.spinner {
  width: 30px;
  height: 30px;
  border: 3px solid var(--accent-soft);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.credit-balance {
  padding: 0 0 12px;
  display: grid;
  gap: 10px;
}
.credit-balance > span {
  font-size: 14px;
  color: var(--muted);
}
.credit-balance > strong {
  font-size: 48px;
  letter-spacing: -2px;
  line-height: 1.2;
  font-weight: 500;
}
.credit-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.credit-choice {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  padding: 16px 12px;
  background: white;
  border-radius: 12px;
  cursor: pointer;
  position: relative;
  min-width: 0;
}
.credit-choice:has(input:checked) {
  border-color: var(--accent);
  background: #f5f8ff;
}
.credit-choice span {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.credit-choice strong {
  font-size: 17px;
  font-weight: 600;
}
.credit-choice small {
  font-size: 11px;
}
.credit-choice em {
  position: absolute;
  right: 8px;
  top: 6px;
  color: var(--accent);
  font-size: 10px;
  font-weight: 600;
  font-style: normal;
}
.subscription-options {
  display: grid;
  gap: 12px;
}
.subscription-options .credit-choice {
  padding: 18px;
}
.movement {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.movement small {
  display: block;
  font-size: 11px;
  margin-top: 4px;
}
.movement strong {
  white-space: nowrap;
}
.account-summary {
  display: flex;
  gap: 18px;
  align-items: center;
  margin-bottom: 10px;
  min-width: 0;
}
.account-summary > div {
  min-width: 0;
}
.account-summary strong {
  font-size: 15px;
  overflow-wrap: anywhere;
}
.account-summary small {
  display: block;
  margin-top: 7px;
}
.account-avatar {
  height: 54px;
  width: 54px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 23px;
  flex-shrink: 0;
}
.legal-links {
  font-size: 13px;
  gap: 24px;
}
.auth {
  width: min(100%, 420px);
  padding: 70px 24px;
  margin: auto;
}
.auth h1 {
  font-size: 30px;
  margin-bottom: 34px;
}
.auth-links {
  margin: 24px 0;
  display: grid;
  gap: 15px;
  font-size: 13px;
}
.auth footer {
  display: flex;
  gap: 20px;
  font-size: 12px;
  color: var(--muted);
  margin-top: 40px;
}
.auth footer a {
  color: var(--muted);
}
.auth .wordmark {
  margin-bottom: 40px;
}
.legal {
  max-width: 760px;
  background: white;
  padding: 32px;
  border-radius: 16px;
}
.legal p,
.legal li {
  font-size: 14px;
  line-height: 1.8;
  margin: 12px 0;
}
.legal h1 {
  font-size: 25px;
  margin: 15px 0;
}
.legal h2 {
  margin-top: 24px;
}
.startup {
  padding: 30vh 20px;
  text-align: center;
  color: var(--muted);
}
dialog {
  border: 0;
  border-radius: 20px;
  background: white;
  color: var(--text);
  padding: 28px;
  max-width: calc(100vw - 32px);
  width: 480px;
  max-height: calc(100dvh - 32px);
  box-shadow: 0 24px 80px #17223830;
}
dialog::backdrop {
  background: #17223870;
  backdrop-filter: blur(3px);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 26px;
}
.modal-head h2 {
  font-size: 22px;
  letter-spacing: -0.6px;
}
.modal-head .icon-button {
  border: 0;
  background: var(--bg);
}
dialog p {
  font-size: 14px;
}
dialog .stack {
  gap: 22px;
}
dialog .disclosure-body > button {
  width: 100%;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 28px;
}
.purchase-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 0 0 20px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.purchase-total strong {
  font-size: 26px;
  white-space: nowrap;
}
.dropzone {
  min-height: 220px;
  border: 1px dashed #9db0d1;
  background: #f7f9fd;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 16px;
  border-radius: 14px;
  text-align: center;
  cursor: pointer;
  padding: 24px;
}
.dropzone > .icon {
  width: 28px;
  height: 28px;
  color: var(--accent);
}
.dropzone strong {
  font-size: 18px;
  font-weight: 600;
}
.dropzone span {
  font-size: 12px;
  color: var(--muted);
}
.dropzone.dragover {
  border-color: var(--accent);
  background: var(--accent-soft);
}
dialog > .disclosure {
  margin-top: 24px;
}
.upload-progress {
  display: grid;
  gap: 10px;
  padding: 20px;
  background: white;
  border-radius: 14px;
  margin-bottom: 28px;
  font-size: 14px;
}
progress {
  accent-color: var(--accent);
  height: 6px;
  width: 100%;
}
.file-list {
  list-style: none;
  padding: 0;
  margin: 20px 0;
  display: grid;
  gap: 12px;
}
.file-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  font-size: 12px;
}
.file-list li span {
  overflow-wrap: anywhere;
  flex: 1;
  min-width: 0;
}
.file-list video,
.file-list img {
  width: 54px;
  height: 70px;
  object-fit: cover;
  border-radius: 7px;
  background: var(--bg);
}
.file-list button {
  font-size: 12px;
  min-width: 74px;
}
#toast {
  position: fixed;
  bottom: max(24px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100vw - 32px);
  padding: 13px 20px;
  border-radius: 12px;
  background: #172238;
  color: white;
  font-size: 13px;
  line-height: 1.5;
  box-shadow: 0 5px 20px #17223820;
  z-index: 100;
}
.review-timeline {
  max-width: 100%;
  padding: 10px 0;
}
.review-timeline-toolbar {
  gap: 8px;
}
.review-note-copy {
  color: var(--text);
}
.review-note {
  background: var(--bg);
}
.review-dialog {
  background: white;
}
.review-canvas {
  background: #e6eaf0;
}
.review-comment {
  background: white;
}
.review-save-state {
  color: var(--muted);
}
.review-timeline-thumb {
  background: var(--elevated);
}
.review-comment .primary.full {
  width: 100%;
}
.field-note {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.review-note-copy small {
  font-size: 11px;
}
.full {
  width: 100%;
}
@media (min-width: 1450px) {
  .player-stage video {
    max-height: 700px;
  }
}
@media (max-width: 1050px) {
  .video-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .workspace {
    gap: 26px;
    grid-template-columns: minmax(0, 1fr) 320px;
  }
  .action-panel {
    padding: 24px;
  }
  .page {
    padding-inline: 28px;
  }
  .appbar {
    padding-inline: 28px;
  }
  .poster {
    height: 300px;
  }
}
@media (max-width: 760px) {
  .appbar {
    height: 74px;
    padding: 0 20px;
  }
  .wordmark {
    font-size: 25px;
    gap: 9px;
  }
  .wordmark img {
    width: 31px;
    height: 31px;
  }
  .bar-actions {
    gap: 12px;
  }
  .preview-tag {
    display: none;
  }
  .menu > summary {
    padding: 8px;
  }
  .page {
    padding: 32px 20px 60px;
  }
  .page-head {
    gap: 16px;
    margin-bottom: 27px;
  }
  h1 {
    font-size: 27px;
    letter-spacing: -0.8px;
  }
  .page-head > .primary {
    font-size: 12px;
    min-height: 44px;
    padding: 11px 13px;
    gap: 6px;
  }
  .page-head > .primary .icon {
    width: 17px;
  }
  .video-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 16px;
  }
  .poster {
    height: 260px;
    border-radius: 13px;
  }
  .poster-badge {
    top: 8px;
    left: 8px;
    padding: 4px 6px;
    font-size: 10px;
  }
  .video-card h2 {
    font-size: 13px;
    margin: 12px 0 7px;
  }
  .video-card p {
    font-size: 10px;
    line-height: 1.5;
    gap: 3px;
  }
  .duration {
    font-size: 10px;
    bottom: 9px;
    right: 9px;
  }
  .card-download {
    font-size: 12px;
  }
  .workspace {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .project-head {
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 22px;
  }
  .project-head h1 {
    font-size: 20px;
  }
  .back-link {
    width: 100%;
    font-size: 12px;
    min-height: 28px;
  }
  .project-head > .menu {
    margin-left: auto;
  }
  .player-stage {
    padding: 14px;
    border-radius: 16px;
  }
  .player-stage video {
    max-height: min(62svh, 570px);
    max-width: 100%;
    border-radius: 10px;
  }
  .player-meta {
    padding: 12px 2px;
  }
  .action-panel {
    padding: 24px;
    border-radius: 16px;
  }
  .result-actions {
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 14px;
  }
  .result-actions h2 {
    font-size: 21px;
  }
  .result-actions .ready-label,
  .result-actions .muted {
    grid-column: 1/-1;
  }
  .result-actions .muted {
    margin-top: -10px;
  }
  .result-actions .primary {
    grid-column: 1/-1;
    margin-top: 4px;
  }
  .result-actions .quality {
    grid-column: 1/-1;
    margin-top: -8px;
  }
  .result-actions #revise {
    grid-column: 1/-1;
  }
  .history {
    margin-top: 24px;
  }
  .settings {
    gap: 24px;
  }
  .asset-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .credit-options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .credit-choice {
    padding: 16px;
  }
  .credit-choice strong {
    font-size: 18px;
  }
  .credit-choice small {
    font-size: 11px;
  }
  .reference-grid video {
    height: 180px;
  }
  .reference-grid .asset-delete {
    top: 180px;
  }
  .project-page {
    padding-top: 16px;
  }
  .auth {
    padding-top: 40px;
  }
  .legal {
    padding: 24px 20px;
  }
  dialog {
    padding: 24px;
    border-radius: 18px;
  }
  .review-dialog {
    max-width: calc(100vw - 20px);
    padding: 20px;
  }
  .empty {
    min-height: 50vh;
  }
  .review-timeline-toolbar .review-step-controls {
    order: 3;
    width: 100%;
    justify-content: space-between;
  }
  .review-timeline-toolbar .review-add {
    font-size: 12px;
  }
  .review-dialog-body {
    gap: 20px;
  }
}
@media (max-width: 370px) {
  .page {
    padding-inline: 16px;
  }
  .appbar {
    padding-inline: 16px;
  }
  .menu > summary > span {
    display: none;
  }
  .poster {
    height: 230px;
  }
  .page-head > .primary {
    padding-inline: 11px;
  }
  .video-grid {
    gap: 24px 12px;
  }
  .asset-caption {
    padding: 10px;
    font-size: 11px;
  }
  .start-row {
    flex-wrap: wrap;
  }
  .start-row button {
    flex: 1;
  }
  .credit-choice {
    padding: 14px 10px;
  }
  .balance-link {
    font-size: 13px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.review-canvas-area {
  background: #e6eaf0;
}
.review-draft {
  color: #8b5315;
}
.review-dialog .eyebrow {
  letter-spacing: 0;
  font-size: 11px;
}
.review-timeline-pin {
  min-width: 36px;
  min-height: 36px;
}
.review-step-controls .icon-button {
  min-width: 44px;
  width: 44px;
  min-height: 44px;
}
.review-note .icon-button {
  min-width: 44px;
  flex-basis: 44px;
}

.asset-caption > span {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.result-actions {
  grid-template-columns: 1fr;
}
.result-actions > h2 {
  grid-column: 1/-1;
}
@media (max-width: 760px) {
  .result-actions #download-hd {
    position: static;
    width: 100%;
    margin: 0;
    box-shadow: none;
  }
  .project-page:has(#download-hd) {
    padding-bottom: 40px;
  }
  .result-actions .quality {
    margin-top: 0;
    text-align: left;
  }
  .result-actions .muted {
    margin-top: 0;
  }
  .result-actions {
    gap: 14px;
  }
  .player-stage video {
    max-height: min(52svh, 520px);
  }
}
/* Detail pass: quieter type, stable amounts, consistent surfaces. */
h1 {
  letter-spacing: -0.035em;
}
.video-card h2 {
  font-weight: 600;
  letter-spacing: -0.025em;
}
.video-card p,
.credit-balance strong,
.credit-choice strong,
.movement-amount,
.balance-link {
  font-variant-numeric: tabular-nums lining-nums;
}
.poster-badge {
  box-shadow: 0 1px 5px #17223808;
  backdrop-filter: blur(8px);
}
.credit-choice {
  border-color: #d6deeb;
  box-shadow: 0 1px 2px #17223803;
  transition:
    background 0.16s,
    border-color 0.16s,
    box-shadow 0.16s;
}
.credit-choice:hover {
  border-color: #98acd6;
}
.credit-choice:has(input:checked) {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f0f5ff;
}
.credit-choice strong {
  font-weight: 600;
  letter-spacing: -0.035em;
}
.credit-choice em {
  background: var(--accent-soft);
  padding: 1px 5px;
  border-radius: 5px;
  font-weight: 600;
}
.credit-choice small {
  color: #566277;
}
.credit-balance > strong {
  font-weight: 500;
}
.movement-list {
  display: grid;
}
.movement {
  display: block;
  border-bottom: 1px solid var(--line);
  padding: 0;
}
.movement > summary {
  display: flex;
  align-items: center;
  gap: 16px;
  list-style: none;
  cursor: pointer;
  padding: 20px 0;
  min-height: 90px;
}
.movement > summary::-webkit-details-marker {
  display: none;
}
.movement-copy {
  min-width: 0;
  flex: 1;
  display: grid;
  gap: 5px;
}
.movement-copy > strong {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.015em;
}
.movement-video {
  font-size: 13px;
  color: var(--text);
  overflow-wrap: anywhere;
  line-height: 1.5;
}
.movement-copy > small {
  margin: 0;
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.movement-amount {
  font-size: 17px;
  letter-spacing: -0.025em;
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
}
.movement-amount > small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  margin: 3px 0 0;
}
.movement-amount.is-credit {
  color: #246744;
}
.movement-amount.is-neutral {
  color: var(--muted);
}
.movement-chevron {
  color: var(--muted);
  display: flex;
}
.movement-chevron .icon {
  width: 14px;
  height: 14px;
  transition: transform 0.15s;
}
.movement[open] .movement-chevron .icon {
  transform: rotate(90deg);
}
.movement-detail {
  display: grid;
  gap: 10px;
  padding: 0 22px 20px 0;
}
.movement-detail p {
  font-size: 13px;
  line-height: 1.65;
}
.movement-detail a {
  font-size: 13px;
  font-weight: 600;
  min-height: 44px;
  display: flex;
  align-items: center;
  width: fit-content;
}
.upload-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
}
.upload-heading > span {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.upload-heading > strong {
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.upload-progress progress {
  height: 7px;
  appearance: none;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
  background: var(--accent-soft);
}
.upload-progress progress::-webkit-progress-bar {
  background: var(--accent-soft);
  border-radius: 8px;
}
.upload-progress progress::-webkit-progress-value {
  background: var(--accent);
  border-radius: 8px;
  transition: width 0.2s;
}
.upload-progress progress::-moz-progress-bar {
  background: var(--accent);
  border-radius: 8px;
}
.upload-progress progress:indeterminate {
  background: linear-gradient(
    90deg,
    var(--accent-soft),
    #aec3ff,
    var(--accent-soft)
  );
  background-size: 200% 100%;
  animation: upload-wait 2s linear infinite;
}
.upload-progress progress:indeterminate::-webkit-progress-bar {
  background: transparent;
}
.frame-loader {
  width: 52px;
  height: 68px;
  position: relative;
  margin: 4px 0 12px;
}
.frame-loader > span {
  position: absolute;
  inset: 0;
  border: 2px solid var(--accent);
  border-radius: 12px;
  background: #f5f8ff;
}
.frame-loader:before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 23px 17px 23px 20px;
  background: var(--accent);
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}
.frame-loader > i {
  position: absolute;
  z-index: 2;
  top: 10px;
  left: 8px;
  right: 8px;
  height: 2px;
  border-radius: 2px;
  background: #86a7ff;
  animation: frame-scan 2.6s ease-in-out infinite;
  opacity: 0.75;
}
.processing-phases {
  list-style: none;
  padding: 0;
  margin: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 14px;
}
.processing-phases li {
  display: grid;
  justify-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.4;
  min-width: 0;
}
.processing-phases li > span {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid #bdc8d9;
  font-size: 12px;
}
.processing-phases .is-current {
  color: var(--accent);
}
.processing-phases .is-current > span {
  border: 5px solid var(--accent);
  background: white;
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.processing-phases .is-done > span {
  background: var(--accent-soft);
  border-color: var(--accent-soft);
  color: var(--accent);
}
.waiting > p {
  max-width: 30ch;
  font-size: 12px;
  line-height: 1.7;
}
.waiting > h2 {
  font-size: 18px;
  letter-spacing: -0.035em;
}
.waiting {
  padding: 24px 0;
  gap: 22px;
}
.primary[aria-busy="true"] {
  background: #426bdc;
  cursor: wait;
}
@keyframes frame-scan {
  0%,
  100% {
    transform: translateY(0);
    opacity: 0.3;
  }
  50% {
    transform: translateY(43px);
    opacity: 0.9;
  }
}
@keyframes upload-wait {
  to {
    background-position: -200% 0;
  }
}
@media (max-width: 370px) {
  .movement > summary {
    gap: 10px;
  }
  .movement-amount {
    font-size: 15px;
  }
  .processing-phases {
    gap: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .frame-loader > i,
  .upload-progress progress:indeterminate {
    animation: none;
  }
  .frame-loader > i {
    top: 32px;
  }
  .credit-choice,
  .movement-chevron .icon {
    transition: none;
  }
}
@media (max-width: 760px) {
  .workspace:has(.processing-phases) > .action-panel {
    order: -1;
  }
}

/* Organizing the user's work, with secondary choices kept in menus. */
.library-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
  padding-bottom: 10px;
}
.library-tabs a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 10px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.library-tabs a[aria-current="page"] {
  background: var(--accent-soft);
  color: var(--accent);
}
.library-tabs a span {
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  background: #e4e9f0;
  color: #46546c;
  min-width: 20px;
  text-align: center;
  border-radius: 6px;
  padding: 2px 4px;
}
.library-tabs a[aria-current="page"] span {
  background: #d3dfff;
  color: #2049b6;
}
.library-processing {
  display: grid;
  gap: 8px;
  margin-bottom: 22px;
}
.library-processing > a {
  display: flex;
  align-items: center;
  gap: 14px;
  background: white;
  border: 1px solid #dbe4f5;
  border-radius: 12px;
  padding: 14px 18px;
  text-decoration: none;
}
.library-processing > a > span:nth-child(2) {
  display: grid;
  gap: 4px;
  min-width: 0;
}
.library-processing strong {
  font-size: 14px;
  overflow-wrap: anywhere;
}
.library-processing small {
  font-size: 12px;
  color: var(--muted);
}
.library-processing .icon {
  margin-left: auto;
}
.status-dot {
  width: 9px;
  height: 9px;
  flex: none;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px var(--accent-soft);
}
.search {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 24px;
}
.search > .icon {
  position: absolute;
  left: 14px;
  pointer-events: none;
  width: 18px;
  color: var(--muted);
}
.search input {
  padding-left: 42px;
  width: 100%;
}
.card-heading {
  display: flex;
  align-items: start;
  gap: 6px;
  margin-top: 12px;
}
.video-card .card-heading h2 {
  margin: 0;
  white-space: normal;
  line-height: 1.45;
  flex: 1;
  min-width: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 14px;
}
.card-heading h2 a {
  color: var(--text);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.card-menu {
  flex: none;
  margin-top: -8px;
  margin-right: -9px;
}
.card-menu > summary {
  width: 40px;
  min-height: 44px;
  justify-content: center;
  padding: 8px;
}
.card-menu > div {
  min-width: 160px;
  z-index: 20;
}
.video-card .card-meta {
  margin-top: 5px;
  font-size: 12px;
  gap: 5px;
}
.video-card .card-caption {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 6px;
  min-height: 34px;
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.new-badge {
  position: absolute;
  top: 43px;
  left: 12px;
  border-radius: 6px;
  background: var(--accent);
  color: white;
  padding: 4px 7px;
  font-size: 11px;
  font-weight: 600;
}
.poster-badge.is-approved {
  background: #e2f3e8;
  color: #225d3c;
}
.load-more {
  display: block;
  margin: 32px auto 0;
}
.result-summary {
  display: grid;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
}
.result-version-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.result-secondary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.result-secondary button {
  min-width: 0;
  padding-inline: 8px;
}
.result-secondary button[aria-pressed="true"] {
  background: #e2f3e8;
  color: #225d3c;
  border-color: #b1d3bf;
}
.subtle {
  color: var(--muted);
  font-size: 12px;
}
.approved-link {
  font-size: 13px;
  text-align: center;
}
.package-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 18px 0 8px;
  flex-wrap: wrap;
}
.package-heading strong {
  font-size: 12px;
  color: var(--text);
}
.package-heading small {
  font-size: 11px;
  color: var(--muted);
}
.version-entry {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--line);
}
.version-entry:last-child {
  border-bottom: 0;
}
.version-entry .version-row {
  flex: 1;
  border: 0;
  min-width: 0;
  padding: 14px 0;
  text-decoration: none;
  display: grid;
  gap: 6px;
}
.version-row > span:first-child {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.version-row strong {
  font-size: 13px;
}
.version-row em {
  font-style: normal;
  font-size: 10px;
  color: var(--muted);
  background: var(--bg);
  padding: 3px 5px;
  border-radius: 4px;
}
.version-row .version-approved {
  color: #225d3c;
  background: #e2f3e8;
}
.version-row .version-new {
  background: var(--accent-soft);
  color: var(--accent);
}
.version-row .version-description {
  font-size: 13px;
  color: var(--text);
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.version-row small {
  line-height: 1.5;
}
.version-entry .icon-button {
  width: 40px;
  min-height: 44px;
  padding: 10px;
  flex: none;
}
.version-entry:has([aria-current="true"]) {
  box-shadow: inset 3px 0 var(--accent);
  padding-left: 12px;
}
.revision-compact {
  gap: 18px;
}
.revision-compact > #frame-notes {
  font-size: 13px;
}
.revision-compact .section-head h3 {
  font-size: 13px;
}
.revision-compact .start-row {
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
}
.revision-compact .start-row button {
  width: 100%;
}
.start-row strong {
  font-size: 15px;
}
.asset-menu {
  position: absolute;
  right: 7px;
  top: 7px;
  z-index: 3;
}
.asset-menu > summary {
  min-height: 36px;
  width: 36px;
  justify-content: center;
  border-radius: 8px;
  background: #fffffff0;
  padding: 7px;
}
.asset-menu > div {
  min-width: 190px;
}
.asset {
  overflow: visible;
}
.asset > label > img {
  border-radius: 10px;
}
.comparison-dialog {
  max-width: 740px;
  width: calc(100% - 24px);
}
.compare-videos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.compare-videos figure {
  margin: 0;
  min-width: 0;
}
.compare-videos figcaption {
  display: grid;
  gap: 5px;
  margin-bottom: 12px;
  font-size: 13px;
}
.compare-videos figcaption span {
  font-size: 12px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 36px;
}
.compare-videos video {
  display: block;
  width: 100%;
  max-height: 56svh;
  background: #152037;
  border-radius: 12px;
  object-fit: contain;
}
.compare-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 20px;
}
.compare-controls output {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-size: 13px;
}
.compare-seek {
  display: block;
  margin-top: 16px;
}
.compare-seek input {
  width: 100%;
  accent-color: var(--accent);
  padding: 0;
}
@media (max-width: 760px) {
  .library-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 3px;
  }
  .library-tabs a {
    padding: 9px 4px;
    flex-direction: column;
    gap: 5px;
    font-size: 12px;
    text-align: center;
  }
  .card-meta {
    font-size: 11px;
  }
  .video-card .card-heading h2 {
    font-size: 13px;
  }
  .new-badge {
    left: 9px;
    top: 38px;
    font-size: 10px;
  }
  .card-download {
    font-size: 12px;
    line-height: 1.5;
  }
  .result-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .result-summary {
    gap: 5px;
  }
  .result-version-label {
    font-size: 15px;
  }
  .result-actions .quality {
    margin-top: -5px;
    text-align: center;
  }
  .result-actions #revise {
    grid-column: auto;
  }
  .result-actions .text-button {
    min-height: 36px;
  }
  .action-panel {
    padding: 20px;
  }
  .history {
    margin-top: 20px;
  }
  .project-head {
    margin-bottom: 16px;
  }
  .player-stage video {
    max-height: 49svh;
  }
  .player-meta {
    padding: 10px 2px;
  }
  .start-row {
    gap: 14px;
    flex-wrap: wrap;
  }
  .start-row button {
    width: 100%;
  }
  .revision-compact .disclosure-body {
    padding-top: 18px;
  }
  .comparison-dialog {
    padding: 18px;
  }
  .compare-videos {
    gap: 10px;
  }
  .compare-videos video {
    max-height: 47svh;
  }
  .compare-controls button {
    font-size: 13px;
    padding: 10px;
  }
  .asset-menu > summary {
    min-height: 44px;
    width: 44px;
    padding: 11px;
  }
  .asset-menu > div {
    min-width: 170px;
  }
}
.result-secondary button[aria-pressed="true"]:disabled {
  opacity: 1;
  cursor: default;
}

.card-menu > summary {
  width: 44px;
}
.version-entry .icon-button {
  width: 44px;
}
.asset-menu > summary {
  min-height: 44px;
  width: 44px;
  padding: 11px;
}
