:root {
  --lavender: #45d6c1;
  --lavender-deep: #008a78;
  --lavender-soft: #e9fffb;
  --ink: #050505;
  --muted: #6d6679;
  --line: #141414;
  --white: #ffffff;
  --shadow: 0 28px 80px rgba(9, 6, 20, 0.14);
}

* {
  box-sizing: border-box;
}

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  position: relative;
  isolation: isolate;
  margin: 0;
  min-height: 100vh;
  font-family: Poppins, Arial, sans-serif;
  color: var(--ink);
  background:
    var(--page-bg-image, url("bg/1.png")) center / cover fixed no-repeat,
    var(--white);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.16), rgba(233, 255, 251, 0.12) 46%, rgba(5, 5, 5, 0.18));
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: screen;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.95) 0 2px, transparent 4px),
    radial-gradient(circle at 72% 18%, rgba(197, 255, 244, 0.9) 0 2px, transparent 5px),
    radial-gradient(circle at 84% 68%, rgba(255, 255, 255, 0.86) 0 1px, transparent 4px),
    linear-gradient(118deg, transparent 0 43%, rgba(255, 255, 255, 0.72) 44%, rgba(69, 214, 193, 0.48) 46%, transparent 49%),
    linear-gradient(64deg, transparent 0 58%, rgba(255, 255, 255, 0.48) 59%, transparent 62%);
  animation: backgroundSpark 5s ease-in-out infinite;
}

@keyframes backgroundSpark {
  0%, 88%, 100% {
    opacity: 0;
    transform: scale(1);
  }
  3% {
    opacity: 0.72;
    transform: scale(1.015);
  }
  6% {
    opacity: 0.18;
  }
  9% {
    opacity: 0.5;
  }
  13% {
    opacity: 0;
    transform: scale(1.03);
  }
}

.page-background-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  opacity: 0;
  transition: opacity 900ms ease;
}

.page-background-layer.is-visible {
  opacity: 1;
}

button,
input {
  font: inherit;
}

.app-shell {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(10px, 1.4vw, 18px);
}

.auth-card,
.modal {
  width: min(100%, 440px);
  border: 5px solid var(--lavender);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(30px);
  box-shadow: var(--shadow);
}

.auth-card {
  padding: 34px;
  text-align: center;
}

.auth-card > .brand-mark {
  filter: brightness(0) invert(1);
  text-align: center;
}

.brand-mark {
  display: inline-block;
  width: clamp(210px, 20vw, 340px);
  height: clamp(44px, 4.8vw, 72px);
  margin: 0 0 26px;
  overflow: hidden;
  background: url("assets/musicgen-logo-transparent.png") center / contain no-repeat;
  color: transparent !important;
  text-indent: -9999px;
  text-shadow: none !important;
  text-transform: uppercase;
}

.headline-block {
  margin-bottom: 30px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
p {
  letter-spacing: 0;
}

h1,
h2 {
  margin: 0;
  color: var(--lavender-deep);
  font-weight: 800;
  line-height: 1;
}

.auth-card h1 {
  color: var(--white);
  font-size: clamp(2rem, 7vw, 3.6rem);
  text-shadow: 0 3px 18px rgba(5, 5, 5, 0.45);
}

.auth-card .eyebrow {
  color: var(--ink);
  font-size: 1.09rem;
  line-height: 1.35;
}

.support-copy {
  margin: 16px 0 0;
  color: var(--ink);
  font-weight: 600;
  line-height: 1.6;
}

.login-form {
  display: grid;
  gap: 12px;
  justify-items: center;
}

label {
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 700;
  text-align: center;
}

input {
  width: 100%;
  min-height: 44px;
  border: 2px solid var(--line);
  border-radius: 999px;
  padding: 0 16px;
  color: var(--ink);
  background: var(--white);
  outline: none;
  text-align: left;
  line-height: 1.2;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

select,
textarea {
  width: 100%;
  border: 2px solid var(--line);
  border-radius: 18px;
  padding: 12px 16px;
  color: var(--ink);
  background: var(--white);
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus {
  border-color: var(--lavender-deep);
  box-shadow: 0 0 0 4px rgba(69, 214, 193, 0.18);
}

.password-wrap {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  overflow: hidden;
}

.password-wrap:focus-within {
  border-color: var(--lavender-deep);
  box-shadow: 0 0 0 4px rgba(69, 214, 193, 0.18);
}

.password-wrap input {
  min-height: 42px;
  border-radius: 0;
  border: 0;
  box-shadow: none;
}

.ghost-button {
  min-width: 78px;
  min-height: 42px;
  padding: 0 16px;
  border: 0;
  border-left: 2px solid var(--line);
  border-radius: 0 999px 999px 0;
  color: var(--lavender-deep);
  background: var(--white);
  font-weight: 800;
  cursor: pointer;
}

.primary-button,
.cta-button,
.outline-button {
  min-height: 54px;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.primary-button,
.cta-button {
  border: 2px solid var(--ink);
  color: var(--white);
  background: var(--ink);
}

.login-form .primary-button {
  width: 100%;
  color: var(--ink);
  background: var(--white);
}

.primary-button:hover,
.cta-button:hover,
.outline-button:hover {
  transform: translateY(-2px);
  box-shadow: 8px 8px 0 var(--lavender);
}

.outline-button {
  padding: 0 18px;
  border: 2px solid var(--ink);
  color: var(--ink);
  background: var(--white);
}

.form-error {
  min-height: 22px;
  margin: 2px 0;
  color: #b42318;
  font-size: 0.9rem;
  font-weight: 700;
}

.welcome-animation {
  position: relative;
  display: grid;
  place-items: center;
  gap: 22px;
  text-align: center;
}

.welcome-animation[hidden],
.dashboard[hidden],
.modal-backdrop[hidden] {
  display: none;
}

.pulse-ring {
  width: 132px;
  aspect-ratio: 1;
  border: 5px solid var(--lavender-deep);
  animation: pulse 900ms ease-in-out infinite alternate;
}

.welcome-animation h2 {
  font-size: clamp(1.9rem, 7vw, 4rem);
  animation: riseIn 700ms ease both;
  color: var(--white);
}

.dashboard {
  width: min(100%, 1860px);
  max-width: 100%;
  min-width: 0;
}

.dashboard-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.dashboard-nav .brand-mark {
  margin: 0;
}

.dashboard-brand-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.dashboard-nav-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.dashboard-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  font-size: 0.72rem;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.dashboard-logs-menu {
  position: relative;
}

.dashboard-logs-menu summary {
  list-style: none;
  cursor: pointer;
}

.dashboard-logs-menu summary::-webkit-details-marker {
  display: none;
}

.dashboard-logs-menu summary::after {
  content: "▾";
  margin-left: 8px;
  font-size: 0.7rem;
}

.dashboard-logs-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 30;
  min-width: 190px;
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 2px solid var(--lavender);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 22px 52px rgba(9, 6, 20, 0.18);
  backdrop-filter: blur(20px);
}

.dashboard-log-option {
  width: 100%;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 999px;
  padding: 0 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.72);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
}

.dashboard-log-option:hover {
  border-color: var(--lavender-deep);
  background: var(--lavender-soft);
}

.dashboard-footer-tools {
  display: flex;
  justify-content: flex-end;
  margin: 18px 0 4px;
  padding-top: 10px;
}

.dashboard-footer-tool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  border: 1px solid rgba(5, 5, 5, 0.16);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.62);
  font: 850 0.66rem/1 Poppins, Arial, sans-serif;
  letter-spacing: 0;
  text-decoration: none;
  text-transform: uppercase;
  opacity: 0.78;
}

.dashboard-footer-tool:hover {
  color: var(--ink);
  opacity: 1;
}

body.has-festival-marker .dashboard-calendar-fallback {
  display: none;
}

.creator-trending-videos {
  position: relative;
  margin: 0 0 18px;
  padding: clamp(16px, 2vw, 24px);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 22px 62px rgba(9, 6, 20, 0.14);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.creator-trending-videos[hidden] {
  display: none;
}

.dashboard-search-panel {
  display: flex;
  align-items: end;
  gap: 10px;
  margin: 0 0 16px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 46px rgba(9, 6, 20, 0.12);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.dashboard-search-field {
  flex: 1;
  display: grid;
  gap: 6px;
  min-width: min(100%, 260px);
  color: rgba(22, 16, 25, 0.68);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.dashboard-search-field input {
  width: 100%;
  min-height: 46px;
  border: 2px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.95);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: none;
}

.dashboard-search-field input:focus {
  border-color: var(--lavender-deep);
  outline: 3px solid rgba(0, 138, 120, 0.18);
}

.dashboard-search-clear {
  min-height: 46px;
}

.creator-trending-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.creator-trending-header .eyebrow {
  margin-bottom: 6px;
}

.creator-trending-header h2 {
  font-size: clamp(1.35rem, 2.5vw, 2.3rem);
  text-transform: uppercase;
}

.creator-running-toggle {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 2px solid var(--line);
  border-radius: 999px;
  padding: 0 16px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.92);
  font-size: 0.72rem;
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
  cursor: pointer;
}

.creator-running-toggle::after {
  content: "";
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid currentColor;
  transform: rotate(0deg);
  transform-origin: 50% 45%;
  transition: transform 160ms ease;
}

.creator-running-toggle[aria-expanded="false"]::after {
  transform: rotate(-90deg);
}

.creator-running-toggle:hover,
.creator-running-toggle:focus-visible {
  border-color: var(--lavender-deep);
  color: var(--lavender-deep);
  outline: none;
}

.creator-video-job-grids[hidden] {
  display: none;
}

.creator-video-jobs-panel.is-collapsed {
  padding-bottom: clamp(16px, 2vw, 24px);
}

.creator-video-job-grids {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(12px, 1.6vw, 18px);
  align-items: stretch;
}

.creator-video-job-column {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 12px;
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 18px;
  padding: clamp(12px, 1.35vw, 16px);
  background: rgba(255, 255, 255, 0.68);
}

.creator-video-job-column-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.creator-video-job-column-header .eyebrow {
  margin-bottom: 5px;
}

.creator-video-job-column-header h3 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1rem, 1.5vw, 1.3rem);
  line-height: 1.12;
  text-transform: uppercase;
}

.creator-video-job-column .creator-trending-history-link {
  position: static;
}

.creator-trending-controls {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.creator-trending-history-link {
  position: absolute;
  top: clamp(16px, 2vw, 24px);
  right: clamp(16px, 2vw, 24px);
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--line);
  border-radius: 999px;
  padding: 0 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.9);
  font-size: 0.72rem;
  font-weight: 950;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.creator-trending-history-link:hover {
  border-color: var(--lavender-deep);
  color: var(--lavender-deep);
}

.creator-progen-approval-toggle {
  cursor: pointer;
}

.creator-progen-approval-toggle.is-active {
  border-color: var(--lavender-deep);
  color: var(--white);
  background: var(--lavender-deep);
  box-shadow: 0 10px 24px rgba(0, 138, 120, 0.22);
}

.creator-trending-arrow {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border: 2px solid var(--line);
  border-radius: 999px;
  color: var(--white);
  background: var(--lavender-deep);
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(0, 138, 120, 0.24);
}

.creator-trending-status {
  margin: 0;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 700;
}

.creator-trending-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(250px, 320px);
  gap: 14px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  padding-bottom: 4px;
}

.creator-progen-track {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
  max-height: 430px;
  overflow: auto;
  padding-right: 4px;
  scrollbar-width: thin;
}

.creator-video-jobs-panel {
  --dashboard-video-job-card-height: 151px;
}

.creator-video-jobs-panel .creator-trending-track,
.creator-video-jobs-panel .creator-progen-track {
  display: grid;
  grid-auto-flow: row;
  grid-auto-columns: unset;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-height: calc((var(--dashboard-video-job-card-height) * 2) + 10px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 6px 0 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 138, 120, 0.62) rgba(0, 138, 120, 0.12);
}

.creator-video-jobs-panel .creator-trending-track::-webkit-scrollbar,
.creator-video-jobs-panel .creator-progen-track::-webkit-scrollbar {
  width: 8px;
}

.creator-video-jobs-panel .creator-trending-track::-webkit-scrollbar-thumb,
.creator-video-jobs-panel .creator-progen-track::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(0, 138, 120, 0.58);
}

.creator-video-jobs-panel .creator-trending-card {
  min-width: 0;
  min-height: var(--dashboard-video-job-card-height);
}

.creator-video-jobs-panel .creator-trending-copy {
  display: none;
}

.creator-video-jobs-panel .creator-video-job-meter,
.creator-video-jobs-panel .creator-progen-job-top {
  min-height: var(--dashboard-video-job-card-height);
  height: var(--dashboard-video-job-card-height);
}

.creator-trending-card {
  min-width: 0;
  overflow: hidden;
  border: 2px solid rgba(5, 5, 5, 0.14);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  scroll-snap-align: start;
  box-shadow: 0 16px 40px rgba(9, 6, 20, 0.12);
}

.creator-trending-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  color: var(--white);
  background: linear-gradient(135deg, var(--lavender-deep), #1d1235);
  text-decoration: none;
}

.creator-trending-media img,
.creator-trending-media video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 220ms ease;
}

.creator-trending-card:hover img,
.creator-trending-card:hover video {
  transform: scale(1.04);
}

.creator-trending-play {
  position: absolute;
  right: 10px;
  bottom: 10px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--white);
  background: rgba(5, 5, 5, 0.72);
  font-size: 0.7rem;
  font-weight: 900;
}

.creator-trending-copy {
  display: grid;
  gap: 7px;
  padding: 14px;
}

.creator-trending-copy h3 {
  margin: 0;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.25;
}

.creator-trending-copy p {
  margin: 0;
  color: var(--lavender-deep);
  font-size: 0.85rem;
  font-weight: 800;
}

.creator-trending-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.creator-trending-meta span {
  border: 1px solid rgba(0, 138, 120, 0.2);
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--muted);
  background: rgba(233, 255, 251, 0.76);
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
}

.creator-video-job-card {
  min-height: 100%;
}

.creator-video-project-card {
  min-width: min(440px, 88vw);
}

.creator-video-project-card .creator-trending-copy h3 {
  font-size: 1.08rem;
}

.creator-video-project-card .creator-trending-copy p {
  color: var(--muted);
  font-size: 0.76rem;
  text-transform: uppercase;
}

.creator-video-project-card.has-job-frame {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.creator-video-project-card.has-job-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image: var(--job-frame);
  background-position: center;
  background-size: cover;
  opacity: 0.24;
  filter: saturate(1.08);
}

.creator-video-project-card.has-job-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.78)),
    radial-gradient(circle at 88% 12%, rgba(0, 138, 120, 0.16), transparent 30%);
  pointer-events: none;
}

.creator-video-job-meter {
  display: grid;
  align-content: center;
  gap: 9px;
  padding: 18px;
  text-decoration: none;
  min-height: 150px;
}

.creator-video-project-card.has-job-frame .creator-video-job-meter {
  border: 1px solid rgba(255, 255, 255, 0.42);
  background:
    linear-gradient(135deg, rgba(7, 39, 35, 0.78), rgba(0, 138, 120, 0.58)),
    var(--job-frame) center / cover;
  box-shadow: inset 0 -70px 80px rgba(5, 34, 30, 0.42);
}

.creator-video-job-meter strong {
  color: var(--white);
  font-size: clamp(1.7rem, 4vw, 2.6rem);
  font-weight: 900;
  line-height: 1;
}

.creator-video-job-meter span {
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.creator-video-job-meter small {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.creator-video-job-meter .creator-video-job-title {
  color: #fff;
  font-size: clamp(0.82rem, 1.3vw, 1.05rem);
  line-height: 1.08;
  letter-spacing: 0;
  text-wrap: balance;
}

.creator-video-job-progress {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
}

.creator-video-job-progress i {
  width: var(--progress, 0%);
  height: 100%;
  display: block;
  border-radius: inherit;
  background: linear-gradient(90deg, #8b5cf6, #22c55e);
}

.creator-video-job-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 10px;
}

.creator-video-job-view-more {
  width: 100%;
  min-width: 0;
  justify-content: center;
  text-align: center;
}

.creator-video-job-actions a,
.creator-video-job-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(0, 138, 120, 0.22);
  border-radius: 999px;
  padding: 8px 10px;
  color: var(--lavender-deep);
  background: rgba(255, 255, 255, 0.78);
  font: 800 0.68rem/1 Poppins, Arial, sans-serif;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
}

.creator-progen-job-card {
  display: grid;
  min-height: 100%;
  cursor: pointer;
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.creator-progen-job-card:hover,
.creator-progen-job-card:focus-visible {
  border-color: rgba(0, 138, 120, 0.55);
  box-shadow: 0 20px 48px rgba(0, 138, 120, 0.18);
  transform: translateY(-2px);
  outline: none;
}

.creator-progen-job-card:focus-visible {
  outline: 3px solid rgba(0, 138, 120, 0.32);
  outline-offset: 3px;
}

.creator-progen-job-top {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  gap: 6px;
  min-height: 132px;
  align-content: end;
  padding: 16px;
  color: var(--white);
  background:
    radial-gradient(circle at 86% 10%, rgba(255, 255, 255, 0.24), transparent 30%),
    linear-gradient(135deg, #07241f, var(--lavender-deep));
}

.creator-progen-job-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.creator-progen-job-scrim {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(17, 10, 29, 0.2), rgba(17, 10, 29, 0.82)),
    radial-gradient(circle at 84% 14%, rgba(0, 138, 120, 0.42), transparent 34%);
  pointer-events: none;
}

.creator-progen-job-card.has-progen-media .creator-progen-job-top {
  background: #07241f;
}

.creator-progen-job-top strong {
  max-width: 100%;
  font-size: clamp(1rem, 1.7vw, 1.42rem);
  line-height: 1.08;
  text-wrap: balance;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.58);
  overflow-wrap: anywhere;
}

.creator-progen-job-top em {
  width: fit-content;
  max-width: 100%;
  border-radius: 999px;
  padding: 4px 8px;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(5, 5, 5, 0.36);
  font-size: 0.62rem;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

@media (max-width: 640px) {
  .creator-video-job-grids {
    grid-template-columns: 1fr;
  }

  .creator-video-job-column-header {
    align-items: stretch;
    flex-direction: column;
  }

  .creator-video-job-column .creator-trending-controls {
    justify-content: flex-start;
  }

  .creator-progen-track {
    grid-template-columns: 1fr;
  }

  .creator-video-jobs-panel .creator-trending-track,
  .creator-video-jobs-panel .creator-progen-track {
    grid-template-columns: 1fr;
    max-height: calc((var(--dashboard-video-job-card-height) * 3) + 20px);
    overflow-y: auto;
    padding-right: 6px;
  }

  .creator-video-project-card {
    min-width: min(320px, 86vw);
  }

  .creator-video-job-meter {
    aspect-ratio: auto;
    min-height: 116px;
    padding: 16px;
  }

  .creator-trending-copy {
    gap: 9px;
    padding: 13px;
  }

  .creator-trending-copy p {
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.35;
  }

  .creator-video-job-view-more {
    min-height: 40px;
    color: #fff !important;
    border-color: var(--lavender-deep) !important;
    background: var(--lavender-deep) !important;
  }
}

.creator-video-job-actions a:hover,
.creator-video-job-actions button:hover:not(:disabled) {
  border-color: rgba(0, 138, 120, 0.42);
  background: var(--lavender-soft);
}

.creator-video-job-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.creator-video-project-jobs {
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 14px;
  background: rgba(233, 255, 251, 0.46);
}

.creator-video-project-jobs summary {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  color: var(--lavender-deep);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  cursor: pointer;
}

.creator-video-project-jobs ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0 10px 10px;
  list-style: none;
}

.creator-video-project-jobs li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  padding: 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.74);
  font-size: 0.72rem;
}

.creator-video-project-jobs li span {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.creator-video-project-jobs li strong {
  color: var(--lavender-deep);
  font-weight: 900;
  text-transform: uppercase;
}

.creator-video-project-jobs li em {
  grid-column: 1 / -1;
  color: var(--muted);
  font-style: normal;
  font-weight: 800;
  text-transform: uppercase;
}

.global-logout-button,
#logoutButton {
  min-height: 32px;
  padding: 0 10px;
  font-size: 0.68rem;
  text-transform: uppercase;
  white-space: nowrap;
}

.creator-wallet-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 32px;
  border: 2px solid rgba(255, 255, 255, 0.52);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--white);
  background: rgba(5, 5, 5, 0.34);
  box-shadow: 0 10px 26px rgba(5, 5, 5, 0.18);
  font-size: 0.72rem;
  font-weight: 900;
  white-space: nowrap;
}

.creator-wallet-chip svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex: 0 0 auto;
}

.creator-wallet-history-link {
  display: inline-grid;
  place-items: center;
  width: 32px;
  min-width: 32px;
  height: 32px;
  border: 2px solid rgba(255, 255, 255, 0.52);
  border-radius: 999px;
  color: #fff !important;
  background: rgba(5, 5, 5, 0.34);
  box-shadow: 0 10px 26px rgba(5, 5, 5, 0.18);
  text-decoration: none;
}

.creator-wallet-history-link svg {
  width: 16px;
  height: 16px;
  fill: #fff !important;
}

.creator-wallet-history-link:hover,
.creator-wallet-history-link:focus-visible {
  background: rgba(0, 138, 120, 0.72);
  outline: none;
}

.creator-wallet-chip[data-state="loading"] {
  opacity: 0.74;
}

.creator-wallet-chip[data-state="error"] {
  border-color: rgba(252, 165, 165, 0.78);
  color: #fee2e2;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr;  /* full width — action-panel removed */
  gap: 18px;
  min-width: 0;
}

.hero-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(20px, 2.4vw, 32px);
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 24px 70px rgba(9, 6, 20, 0.14);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* ── Hero top: identity left, stats right ─────────────────────────────── */
.hero-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: clamp(20px, 3vw, 48px);
  padding-bottom: clamp(16px, 2vw, 24px);
  min-width: 0;
  /* subtle bottom rule only when calendar is also visible */
}

.hero-top + .content-calendar {
  border-top: 1px solid rgba(5, 5, 5, 0.08);
  margin-top: 0;
}

.hero-identity {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hero-panel h1 {
  max-width: 760px;
  font-size: clamp(2.3rem, 5vw, 4.2rem);
  line-height: 1;
  margin-bottom: 10px;
}

/* ── Stat chips strip ─────────────────────────────────────────────────── */
.management-overview {
  display: block;
  width: clamp(460px, 42vw, 620px);
  min-width: 0;
}

.management-overview[hidden] {
  display: none;
}

.management-overview:not(.is-management) .management-overview-totals,
.management-overview:not(.is-management) .management-status-title {
  display: none;
}

.management-overview.is-management {
  display: grid;
  grid-template-columns: repeat(2, minmax(360px, 1fr));
  align-items: start;
  gap: clamp(18px, 2vw, 28px);
  width: clamp(760px, 62vw, 1080px);
}

.dashboard[data-role="management"] .hero-top {
  grid-template-columns: minmax(240px, 0.62fr) minmax(760px, 1.38fr);
  gap: clamp(18px, 2vw, 30px);
}

.management-key-panel,
.management-status-panel {
  min-width: 0;
}

.management-overview-totals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.management-total-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  min-height: 94px;
  padding: 12px 14px;
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
}

.management-total-value {
  color: var(--lavender-deep);
  font-size: clamp(1.3rem, 2vw, 1.9rem);
  font-weight: 850;
  line-height: 1;
}

.management-total-label {
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 850;
  letter-spacing: 0.05em;
  line-height: 1.25;
  text-transform: uppercase;
}

.management-featured-card .management-total-value {
  display: -webkit-box;
  min-height: 2.15em;
  overflow: hidden;
  font-size: clamp(0.95rem, 1.1vw, 1.18rem);
  line-height: 1.08;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.management-top-video-link {
  color: var(--lavender-deep);
  text-decoration: none;
}

.management-top-video-link:hover {
  text-decoration: underline;
}

.management-top-video-link[aria-disabled="true"] {
  color: var(--muted);
  pointer-events: none;
}

.management-status-title {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 850;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(82px, 1fr));
  gap: 10px;
  flex-shrink: 0;
  width: clamp(460px, 42vw, 620px);
}

.management-overview .hero-stats {
  width: 100%;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.hero-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid rgba(0, 138, 120, 0.14);
  border-radius: 14px;
  background: rgba(244, 255, 252, 0.72);
  transition: background 160ms ease;
}

.hero-stat:hover {
  background: rgba(233, 255, 251, 0.9);
}

.hero-stat-value {
  display: block;
  color: var(--lavender-deep);
  font-size: clamp(1.4rem, 2.2vw, 2rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
}

.hero-stat-label {
  display: block;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.3;
}

.content-calendar {
  width: 100%;
  max-width: none;
  min-width: 0;
  margin: 22px 0 4px;
  border: 1px solid rgba(5, 5, 5, 0.12);
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.72);
}

.calendar-header {
  display: grid;
  grid-template-columns: minmax(180px, auto) minmax(0, 1fr);
  align-items: flex-start;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(5, 5, 5, 0.12);
  background: rgba(255, 255, 255, 0.64);
}

.calendar-kicker {
  margin: 0 0 6px;
  color: var(--lavender-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.calendar-header h2 {
  color: var(--ink);
  font-size: 1.15rem;
  line-height: 1.2;
}

.calendar-view-controls {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(4px, 0.6vw, 8px);
  width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}

.calendar-view-controls::-webkit-scrollbar {
  display: none;
}

.dashboard[data-role="management"] .calendar-toggle {
  text-transform: uppercase;
}

.calendar-view-select-wrap,
.creator-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 800;
}

.calendar-view-select-wrap {
  display: none;
}

.calendar-view-select-wrap[hidden],
.creator-filter[hidden] {
  display: none;
}

.calendar-view-select-wrap select,
.creator-filter select {
  width: auto;
  max-width: min(220px, 70vw);
  min-height: 34px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0 12px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

.dashboard[data-role="management"] .calendar-view-controls {
  gap: clamp(6px, 0.6vw, 10px);
  justify-content: flex-end;
  overflow: visible;
}

.dashboard[data-role="management"] .calendar-toggle {
  min-height: clamp(42px, 2.55vw, 48px);
  padding: 0 clamp(13px, 1vw, 20px);
  font-size: clamp(0.73rem, 0.8vw, 0.9rem);
  letter-spacing: 0.02em;
  box-shadow: 0 6px 14px rgba(9, 6, 20, 0.07);
}

.creator-ranking {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(5, 5, 5, 0.08);
  background: rgba(255, 255, 255, 0.72);
}

.creator-ranking h3 {
  margin: 0 0 14px;
  color: var(--lavender-deep);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.creator-ranking ol {
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: stretch;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  margin: 0;
  padding: 0 0 4px;
  list-style: none;
}

/* ── Single rank card ───────────────────────────────────────────────── */
.creator-rank-item {
  display: grid;
  grid-template-columns: 20px 32px minmax(238px, 1fr);
  align-items: start;
  gap: 7px;
  flex: 0 0 min(470px, 92vw);
  padding: 10px 12px;
  border: 1px solid rgba(0, 138, 120, 0.1);
  border-radius: 12px;
  background: rgba(244, 255, 252, 0.6);
  transition: background 160ms ease, border-color 160ms ease;
}

.creator-rank-item:first-child {
  border-color: rgba(0, 138, 120, 0.28);
  background: rgba(0, 138, 120, 0.06);
}

.creator-rank-item:hover {
  background: rgba(233, 255, 251, 0.9);
  border-color: rgba(0, 138, 120, 0.22);
}

/* Position / medal */
.creator-rank-position {
  font-size: 1rem;
  text-align: center;
  line-height: 1;
  font-weight: 800;
  color: var(--muted);
  padding-top: 2px;
}

/* Avatar circle */
.creator-rank-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--lavender-deep);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  user-select: none;
}

.creator-rank-item:first-child .creator-rank-avatar {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}

/* Identity column: name + stat chips */
.creator-rank-identity {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.creator-rank-name {
  display: block;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

/* ── Stat chips row ─────────────────────────────────────────────────── */
.creator-rank-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.creator-rank-stats::-webkit-scrollbar {
  display: none;
}

.creator-rank-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  min-width: 0;
  padding: 4px 5px;
  border: 1px solid rgba(0, 138, 120, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.creator-rank-stat[data-type="published"] {
  border-color: rgba(37, 99, 235, 0.2);
  background: rgba(239, 246, 255, 0.8);
}

.creator-rank-stat[data-type="build"] {
  border-color: rgba(5, 150, 105, 0.2);
  background: rgba(236, 253, 245, 0.8);
}

.creator-rank-stat[data-type="review"] {
  border-color: rgba(124, 58, 237, 0.2);
  background: rgba(245, 243, 255, 0.82);
}

.creator-rank-stat[data-type="delayed"] {
  border-color: rgba(220, 38, 38, 0.15);
  background: rgba(254, 242, 242, 0.8);
}

.creator-rank-stat.is-alert {
  border-color: rgba(220, 38, 38, 0.4);
  background: rgba(254, 226, 226, 0.9);
}

.creator-rank-stat-value {
  display: block;
  font-size: 0.88rem;
  font-weight: 800;
  line-height: 1;
  color: var(--ink);
}

.creator-rank-stat[data-type="published"] .creator-rank-stat-value { color: #1d4ed8; }
.creator-rank-stat[data-type="build"]     .creator-rank-stat-value { color: #047857; }
.creator-rank-stat[data-type="review"]    .creator-rank-stat-value { color: #6d28d9; }
.creator-rank-stat[data-type="delayed"]   .creator-rank-stat-value { color: #b91c1c; }

.creator-rank-stat-label {
  display: block;
  max-width: 100%;
  overflow: hidden;
  font-size: 0.44rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* Score + bar + info btn */
.creator-rank-score-wrap {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
  position: relative;
  padding-left: 66px;
}

.creator-rank-score {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--lavender-deep);
  white-space: nowrap;
}

.creator-rank-bar-track {
  width: 100%;
  min-width: 58px;
  max-width: 96px;
  height: 4px;
  border-radius: 999px;
  background: rgba(0, 138, 120, 0.12);
  overflow: hidden;
  flex-shrink: 0;
}

.creator-rank-bar-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  transition: width 600ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* Info icon button */
.creator-rank-info-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border: 1.5px solid rgba(0, 138, 120, 0.35);
  border-radius: 50%;
  background: transparent;
  color: var(--lavender-deep);
  font-size: 0.6rem;
  font-weight: 900;
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
  line-height: 1;
  transition: background 160ms ease, color 160ms ease;
  position: relative;
}

.creator-rank-info-btn:hover {
  background: var(--lavender-deep);
  color: #fff;
}

/* Tooltip */
.creator-rank-tooltip {
  display: none;
  position: absolute;
  left: 66px;
  right: auto;
  top: calc(100% + 8px);
  z-index: 9000;
  width: 260px;
  padding: 12px 14px;
  border: 1.5px solid rgba(0, 138, 120, 0.22);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 32px rgba(20, 8, 42, 0.18);
  color: var(--ink);
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.6;
  white-space: normal;
  text-align: left;
  pointer-events: none;
}

.creator-rank-info-btn:hover + .creator-rank-tooltip,
.creator-rank-info-btn:focus + .creator-rank-tooltip {
  display: block;
}

/* last card — tooltip opens upward */
.creator-rank-item:last-child .creator-rank-tooltip {
  left: auto;
  right: 0;
}



.calendar-toggle,
.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: clamp(22px, 2vw, 30px);
  border: 1px solid rgba(5, 5, 5, 0.2);
  border-radius: 999px;
  padding: 0 clamp(6px, 0.8vw, 12px);
  background: var(--white);
  color: var(--ink);
  font-size: clamp(0.52rem, 0.8vw, 0.78rem);
  font-weight: 800;
  white-space: nowrap;
}

.calendar-toggle {
  min-height: 48px;
  padding: 0 24px;
  font-size: 0.96rem;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(9, 6, 20, 0.08);
}

.calendar-toggle.is-active {
  color: var(--white);
  border-color: var(--lavender-deep);
  background: var(--lavender-deep);
}

.calendar-table-wrap {
  overflow-x: auto;
  max-width: 100%;
}

.content-calendar table {
  width: 100%;
  min-width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: clamp(0.74rem, 0.82vw, 0.96rem);
}

.content-calendar th,
.content-calendar td {
  padding: clamp(7px, 0.58vw, 10px) clamp(3px, 0.35vw, 6px);
  border-bottom: 1px solid rgba(5, 5, 5, 0.14);
  text-align: left;
  vertical-align: middle;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-calendar th {
  color: rgba(5, 5, 5, 0.62);
  font-size: clamp(0.54rem, 0.6vw, 0.72rem);
  font-weight: 800;
  letter-spacing: clamp(0.02em, 0.12vw, 0.08em);
  text-transform: uppercase;
  white-space: nowrap;
  word-break: keep-all;
}

.content-calendar td {
  font-weight: 700;
}

.calendar-action-heading,
.calendar-action-cell,
.calendar-past-heading,
.calendar-past-cell,
.calendar-metrics-heading,
.calendar-metrics-cell {
  display: none;
}

.calendar-details-heading,
.calendar-details-cell {
  display: table-cell;
}

.content-calendar[data-view="past"] .calendar-past-heading,
.content-calendar[data-view="past"] .calendar-past-cell,
.content-calendar[data-view="past"] .calendar-metrics-heading,
.content-calendar[data-view="past"] .calendar-metrics-cell {
  display: table-cell;
}

.dashboard[data-role="creator"] .calendar-action-heading,
.dashboard[data-role="creator"] .calendar-action-cell,
.dashboard[data-role="auditor"] .calendar-action-heading,
.dashboard[data-role="auditor"] .calendar-action-cell,
.dashboard[data-role="teamlead"] .calendar-action-heading,
.dashboard[data-role="teamlead"] .calendar-action-cell,
.dashboard[data-role="management"] .calendar-action-heading,
.dashboard[data-role="management"] .calendar-action-cell,
.audit-queue-table .calendar-action-heading,
.audit-queue-table .calendar-action-cell {
  display: table-cell;
}

.calendar-details-button,
.calendar-start-button {
  min-height: clamp(25px, 2.5vw, 30px);
  border: 1px solid rgba(5, 5, 5, 0.24);
  border-radius: 999px;
  padding: 0 clamp(10px, 1.2vw, 14px);
  color: var(--ink);
  background: var(--white);
  font-size: clamp(0.6rem, 0.74vw, 0.68rem);
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

.calendar-start-button {
  width: auto;
  min-width: 70px;
  min-height: 30px;
  padding: 0 12px;
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
  font-size: 0.62rem;
  justify-content: center;
}

.calendar-start-button:disabled {
  border-color: rgba(5, 5, 5, 0.16);
  background: rgba(5, 5, 5, 0.16);
  color: rgba(5, 5, 5, 0.55);
  cursor: wait;
}

.calendar-continue-button {
  border-color: #f97316;
  background: #f97316;
  color: var(--ink);
  box-shadow: 0 8px 18px rgba(249, 115, 22, 0.24);
}

.calendar-supergen-button {
  margin-left: 6px;
  border-color: rgba(0, 138, 120, 0.42);
  background: #e9fffb;
  color: var(--lavender-deep);
}

.calendar-song-player {
  display: none;
}

.calendar-song-control {
  display: inline-grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 4px;
  width: min(100px, 100%);
  min-width: 100px;
  max-width: 100%;
}

.calendar-song-play-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: fit-content;
  min-width: 100px;
  height: 32px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0 9px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.86);
  font-size: 0.62rem;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
}

.calendar-song-play-icon {
  min-width: 10px;
  text-align: center;
}

.calendar-song-progress-wrap {
  display: flex;
  align-items: center;
  width: 100%;
  min-width: 100px;
  min-height: 22px;
  padding: 0;
}

.calendar-song-progress {
  --song-progress: 0%;
  width: 100%;
  height: 22px;
  margin: 0;
  border-radius: 999px;
  border: 2px solid var(--ink);
  background:
    linear-gradient(90deg, var(--lavender-deep) var(--song-progress), rgba(255, 255, 255, 0.86) var(--song-progress));
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
  accent-color: var(--lavender-deep);
  cursor: pointer;
  touch-action: pan-x;
  -webkit-appearance: none;
  appearance: none;
}

.calendar-song-progress::-webkit-slider-runnable-track {
  height: 18px;
  border-radius: 999px;
  background: transparent;
}

.calendar-song-progress::-webkit-slider-thumb {
  width: 16px;
  height: 16px;
  margin-top: 0;
  border: 2px solid var(--white);
  border-radius: 50%;
  background: var(--lavender-deep);
  box-shadow: 0 2px 7px rgba(9, 6, 20, 0.26);
  -webkit-appearance: none;
  appearance: none;
}

.calendar-song-progress::-moz-range-track {
  height: 18px;
  border-radius: 999px;
  background: transparent;
}

.calendar-song-progress::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 2px solid var(--white);
  border-radius: 50%;
  background: var(--lavender-deep);
  box-shadow: 0 2px 7px rgba(9, 6, 20, 0.26);
}

.calendar-song-link {
  display: inline-flex;
  align-items: center;
  min-height: 19px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  font-size: 0.47rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.calendar-asset-button,
.calendar-video-link {
  min-height: clamp(28px, 2.6vw, 32px);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0 clamp(10px, 1.2vw, 14px);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.86);
  font-size: clamp(0.58rem, 0.72vw, 0.66rem);
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.calendar-draft-video-link {
  gap: 6px;
  background: var(--ink);
  color: #fff;
}

.calendar-video-play-svg {
  width: 13px;
  height: 13px;
  fill: currentColor;
  flex: 0 0 auto;
}

.calendar-asset-button {
  cursor: pointer;
}

.content-calendar tbody tr:last-child td {
  border-bottom: 0;
}

.content-calendar tr.is-delayed td {
  color: #b91c1c;
  background: #fff1f2;
}

.content-calendar tr.is-unassigned td {
  color: #5f566f;
  background: rgba(233, 255, 251, 0.58);
}

.content-calendar tr.is-delayed td:nth-child(2) {
  color: #dc2626;
  font-weight: 900;
}

.content-calendar td.is-urgent {
  color: #dc2626;
  font-weight: 900;
}

.status-pill {
  min-height: 21px;
  border-color: var(--lavender-deep);
  color: var(--lavender-deep);
  padding: 0 8px;
  font-size: 0.56rem;
}

.status-delayed-marker {
  display: block;
  width: fit-content;
  margin: 5px auto 0;
  color: #dc2626;
  font-size: 0.58rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.04em;
}

.status-draft {
  border-color: #7c3aed;
  background: #f3e8ff;
  color: #5b21b6;
}

.status-review,
.status-under-review {
  border-color: #d97706;
  background: #fff7ed;
  color: #9a3412;
}

.status-scheduled {
  border-color: #059669;
  background: #ecfdf5;
  color: #047857;
}

.status-in-progress,
.status-in-progress-lyrics,
.status-in-progress-song,
.status-in-progress-video,
.status-in-progress-partial-video {
  border-color: #9a3412;
  background: #ffedd5;
  color: #7c2d12;
}

.status-in-progress-lyrics {
  border-color: #7c3aed;
  background: #f3e8ff;
  color: #5b21b6;
}

.status-in-progress-song {
  border-color: #0ea5e9;
  background: #e0f2fe;
  color: #075985;
}

.status-due-for-render {
  border-color: #22c55e;
  background: #dcfce7;
  color: #166534;
}

.status-pre-publish-due,
.status-post-production-due {
  border-color: #00c853;
  background: #bbf7d0;
  color: #064e3b;
}

.status-delivered {
  border-color: #0f766e;
  background: #ccfbf1;
  color: #115e59;
}

.status-published,
.status-approved {
  border-color: #2563eb;
  background: #eff6ff;
  color: #1d4ed8;
}

.status-rejected,
.status-blocked,
.status-delayed {
  border-color: #dc2626;
  background: #fef2f2;
  color: #b91c1c;
}

.status-no-content-assigned {
  border-color: #8b5cf6;
  background: #f5f3ff;
  color: #5b21b6;
}

.hero-identity > p:not(.eyebrow) {
  max-width: 560px;
  margin: 10px 0 20px;
  color: var(--muted);
  font-size: 0.96rem;
  line-height: 1.7;
}

.hero-action-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.hero-action-row:has(> [hidden]:only-child) {
  display: none;
}

.cta-button {
  width: min(100%, 220px);
}

.new-project-button {
  min-width: 160px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.9);
}

.dashboard-balance-card {
  display: inline-grid;
  gap: 4px;
  width: min(100%, 360px);
  margin-top: 14px;
  padding: 14px 16px;
  border: 1.5px solid rgba(0, 138, 120, 0.2);
  border-radius: 16px;
  background: rgba(244, 255, 252, 0.78);
  box-shadow: 0 14px 34px rgba(88, 52, 126, 0.1);
}

.dashboard-balance-card[hidden] {
  display: none;
}

.dashboard-balance-label {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.dashboard-balance-card strong {
  color: var(--lavender-deep);
  font-size: clamp(1.55rem, 3vw, 2.25rem);
  line-height: 1;
}

.dashboard-balance-card span:last-child {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.45;
}

.engine-shortcut-button {
  min-width: 182px;
  color: var(--ink);
  background: linear-gradient(135deg, rgba(255,255,255,0.96), rgba(239,231,255,0.92));
  border-color: var(--lavender-deep);
  box-shadow: 0 14px 30px rgba(0, 138, 120, 0.14);
}

.user-admin-button {
  min-width: 160px;
  color: var(--white);
  border-color: var(--lavender-deep);
  background: var(--lavender-deep);
}

/* action-panel and .metric removed — metrics now live in .hero-stat chips */

.modal-backdrop {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(255, 255, 255, 0.68);
  backdrop-filter: blur(12px);
}

.modal {
  position: relative;
  padding: 34px;
}

.modal > .brand-mark {
  text-align: center;
  color: var(--lavender-deep);
}


.modal h2 {
  font-size: clamp(1.7rem, 6vw, 3.2rem);
}

.modal p:not(.brand-mark) {
  color: var(--muted);
  line-height: 1.6;
}

.welcome-modal {
  width: min(94vw, 680px);
  padding: clamp(30px, 5vw, 52px);
  border-width: 3px;
  border-color: rgba(69, 214, 193, 0.72);
  border-radius: 30px;
  overflow: hidden;
  text-align: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(245, 239, 255, 0.76)),
    radial-gradient(circle at 18% 14%, rgba(69, 214, 193, 0.2), transparent 32%),
    radial-gradient(circle at 86% 12%, rgba(255, 255, 255, 0.9), transparent 26%);
}

.welcome-modal::before {
  content: "";
  position: absolute;
  top: -140px;
  right: -120px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background:
    repeating-conic-gradient(from 18deg, rgba(69, 214, 193, 0.18) 0 8deg, transparent 8deg 16deg),
    radial-gradient(circle, transparent 0 42%, rgba(0, 138, 120, 0.14) 43% 44%, transparent 45%);
  opacity: 0.82;
  pointer-events: none;
}

.welcome-modal > * {
  position: relative;
  z-index: 1;
}

.welcome-modal > .brand-mark {
  margin-bottom: 18px;
  filter: none;
}

.welcome-modal h2 {
  max-width: 560px;
  margin: 0 auto 14px;
  color: var(--ink);
  font-size: clamp(2.45rem, 7vw, 5.2rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.welcome-modal h2 span {
  display: block;
  margin-top: 8px;
  color: var(--lavender-deep);
  font-size: 1.08em;
  overflow-wrap: anywhere;
  text-shadow: 0 12px 32px rgba(0, 138, 120, 0.2);
}

.welcome-modal p:not(.brand-mark) {
  max-width: 470px;
  margin: 0 auto 24px;
  color: rgba(5, 5, 5, 0.68);
  font-size: 1rem;
}

.welcome-modal .primary-button {
  width: auto;
  min-width: 210px;
  padding-inline: 30px;
}

.management-comment-guidance {
  margin-top: 10px;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 14px;
  padding: 10px 12px;
  background: rgba(244, 255, 252, 0.78);
  color: var(--ink) !important;
}

.project-modal {
  width: min(100%, 620px);
  max-height: calc(100vh - 44px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.progen-review-player-modal {
  width: min(96vw, 960px);
}

.progen-review-player-shell {
  min-height: 220px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 16px;
  overflow: hidden;
  background: #070316;
}

.progen-review-player-shell video {
  width: 100%;
  max-height: min(64vh, 560px);
  display: block;
  background: #070316;
}

.progen-review-player-modal .primary-button {
  width: fit-content;
  margin-top: 14px;
}

.audit-queue-modal {
  width: min(96vw, 1180px);
}

.user-access-modal {
  width: min(96vw, 1180px);
}

.creator-target-modal {
  width: min(96vw, 1240px);
}

.user-access-intro-copy {
  margin-top: 8px;
  margin-bottom: 24px;
}

.user-access-layout,
.creator-target-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 20px;
  min-height: 0;
  overflow: hidden;
}

.user-access-list-panel,
.user-access-form,
.creator-target-list-panel,
.creator-target-form {
  min-height: 0;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 18px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.user-access-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.user-access-panel-head h3,
.user-access-form h3,
.creator-target-form h3 {
  margin: 0;
  color: var(--lavender-deep);
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.user-access-small-button {
  min-height: 34px;
  padding: 0 14px;
  font-size: 0.72rem;
}

.user-access-table-wrap {
  max-height: min(56vh, 520px);
  overflow: auto;
}

.user-access-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
  font-size: 0.78rem;
}

.user-access-table th {
  color: var(--muted);
  font-size: 0.68rem;
  text-align: left;
  text-transform: uppercase;
}

.user-access-table td {
  padding: 10px;
  border-top: 1px solid rgba(0, 138, 120, 0.12);
  border-bottom: 1px solid rgba(0, 138, 120, 0.12);
  background: rgba(255, 255, 255, 0.76);
  color: var(--ink);
  vertical-align: middle;
}

.user-access-table td:first-child {
  border-left: 1px solid rgba(0, 138, 120, 0.12);
  border-radius: 12px 0 0 12px;
}

.user-access-table td:last-child {
  border-right: 1px solid rgba(0, 138, 120, 0.12);
  border-radius: 0 12px 12px 0;
}

.user-access-table strong,
.user-access-table span {
  display: block;
}

.user-access-table span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.66rem;
}

.user-access-form,
.creator-target-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
}

.user-access-form label,
.creator-target-form label,
.language-permission-grid legend,
.balance-permission-grid legend,
.creator-quarter-grid legend {
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.user-access-form input,
.user-access-form select,
.creator-target-form input,
.creator-target-form select {
  width: 100%;
  min-height: 42px;
  border: 2px solid rgba(5, 5, 5, 0.16);
  border-radius: 14px;
  padding: 0 12px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-size: 0.9rem;
}

.language-permission-grid {
  border: 0;
  margin: 2px 0 0;
  padding: 0;
}

.balance-permission-grid {
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 16px;
  margin: 4px 0 0;
  padding: 12px;
  background: rgba(255, 255, 255, 0.62);
}

.balance-rate-copy {
  margin: 4px 0 10px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 750;
  line-height: 1.45;
}

.balance-input-grid {
  display: grid;
  grid-template-columns: minmax(180px, 1fr);
  gap: 10px;
}

.balance-input-grid label {
  display: grid;
  gap: 5px;
  font-size: 0.64rem;
}

.balance-chip {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  min-height: 30px;
  border-radius: 999px;
  background: rgba(0, 138, 120, 0.11);
  color: var(--lavender-deep) !important;
  font-size: 0.78rem !important;
  font-weight: 900;
}

.balance-breakdown {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 750;
}

.user-access-action-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.balance-assign-button {
  border-color: rgba(22, 163, 74, 0.34) !important;
  color: #15803d !important;
  background: #ecfdf5 !important;
}

.user-delete-button {
  border-color: rgba(220, 38, 38, 0.38) !important;
  color: #b91c1c !important;
  background: #fff1f2 !important;
}

#accessLanguageChoices {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.language-permission-choice {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 999px;
  padding: 0 10px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 800;
}

.language-permission-choice input {
  width: 16px;
  min-height: 16px;
  accent-color: var(--lavender-deep);
}

.language-permission-choice:has(input:disabled) {
  opacity: 0.48;
}

.creator-target-groups {
  display: grid;
  gap: 12px;
  max-height: min(62vh, 620px);
  overflow: auto;
}

.creator-head-group {
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 16px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.68);
}

.creator-head-group h4 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 0.86rem;
}

.creator-target-card {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(0, 138, 120, 0.14);
  padding: 10px 0;
}

.creator-target-card:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.creator-target-card strong {
  color: var(--lavender-deep);
  font-size: 0.92rem;
}

.creator-target-meta,
.creator-target-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.creator-target-meta span {
  border-radius: 999px;
  padding: 5px 9px;
  background: rgba(0, 138, 120, 0.1);
  color: var(--ink);
  font-size: 0.68rem;
  font-weight: 850;
}

.creator-target-actions button {
  min-height: 32px;
  padding: 0 10px;
  font-size: 0.68rem;
}

.creator-target-fy-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.creator-quarter-grid {
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 16px;
  margin: 4px 0 0;
  padding: 12px;
  background: rgba(255, 255, 255, 0.62);
}

.creator-quarter-breakdown {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.creator-quarter-row {
  display: grid;
  grid-template-columns: 62px repeat(4, minmax(64px, 1fr)) 72px;
  gap: 6px;
  align-items: center;
}

.creator-quarter-row strong,
.creator-quarter-row span {
  color: var(--ink);
  font-size: 0.7rem;
  font-weight: 900;
}

.creator-quarter-row input {
  min-height: 34px;
  padding: 0 8px;
  font-size: 0.82rem;
}

.custom-language-row {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.custom-language-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.user-access-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.user-access-actions .primary-button,
.user-access-actions .outline-button {
  min-height: 44px;
  padding: 0 18px;
  font-size: 0.78rem;
}

.user-access-success-modal {
  width: min(94vw, 620px);
}

.user-access-success-list {
  display: grid;
  grid-template-columns: minmax(130px, 0.42fr) minmax(0, 1fr);
  gap: 10px 14px;
  margin: 18px 0 22px;
  padding: 16px;
  border: 1px solid rgba(0, 138, 120, 0.16);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.68);
}

.user-access-success-list dt {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
}

.user-access-success-list dd {
  margin: 0;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.user-access-success-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.user-access-success-actions .primary-button,
.user-access-success-actions .outline-button {
  min-height: 44px;
  padding: 0 18px;
  font-size: 0.78rem;
}

.audit-queue-table {
  margin-top: 22px;
  max-height: 70vh;
}

.project-details-list {
  display: grid;
  grid-template-columns: minmax(130px, 0.4fr) minmax(0, 1fr);
  gap: 12px 18px;
  margin: 24px 0 0;
  max-height: min(62vh, 560px);
  overflow-y: auto;
  padding-right: 8px;
  scrollbar-color: rgba(0, 138, 120, 0.5) rgba(0, 138, 120, 0.1);
}

.project-details-list dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-details-list dd {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.project-notes-copy {
  margin: 24px 0 0;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.7;
  white-space: pre-wrap;
  max-height: min(62vh, 560px);
  overflow-y: auto;
  padding-right: 8px;
  scrollbar-color: rgba(0, 138, 120, 0.5) rgba(0, 138, 120, 0.1);
}

.project-notes-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.project-notes-actions[hidden] {
  display: none;
}

.project-transliterate-button {
  min-height: 40px;
  padding: 0 16px;
}

.project-notes-status {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.scheduled-project-list {
  display: grid;
  gap: 12px;
  margin-top: 22px;
  max-height: 52vh;
  overflow-y: auto;
}

.scheduled-project-button {
  width: 100%;
  border: 2px solid var(--ink);
  border-radius: 16px;
  padding: 14px 16px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.88);
  cursor: pointer;
  font-weight: 800;
  text-align: left;
}

.scheduled-project-button span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.scheduled-project-button.is-coming-soon,
.scheduled-project-button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
  background: rgba(255, 255, 255, 0.58);
}

.scheduled-project-button.is-coming-soon small {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  border-radius: 999px;
  padding: 3px 8px;
  background: rgba(0, 138, 120, 0.12);
  color: var(--lavender-deep);
  font-size: 0.62rem;
  font-weight: 900;
  vertical-align: middle;
}

.audit-review-form {
  display: grid;
  gap: 12px;
  margin-top: 22px;
}

.management-comment-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.voice-comment-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  border: 1px solid rgba(0, 138, 120, 0.24);
  border-radius: 999px;
  padding: 0 16px;
  background: var(--lavender-deep);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 850;
  cursor: pointer;
  transition: transform 140ms ease, background 140ms ease;
}

.voice-comment-button:hover {
  transform: translateY(-1px);
  background: #5f25c9;
}

.voice-comment-button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.voice-comment-button.is-recording {
  background: #b91c1c;
}

.voice-comment-button svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
}

.voice-comment-status {
  min-height: 1.25em;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 750;
}

.confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}

.audit-video-preview {
  display: grid;
  place-items: center;
  min-height: 180px;
  margin-top: 18px;
  border: 2px solid var(--ink);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  font-weight: 800;
  overflow: hidden;
}

.audit-video-preview video {
  display: block;
  width: 100%;
  max-height: 360px;
  background: #000000;
}

.audit-video-preview a {
  color: var(--lavender-deep);
  font-weight: 900;
}

.audit-video-preview.is-empty {
  color: var(--muted);
}

.audit-lyrics-block {
  margin-top: 16px;
  border: 2px solid var(--ink);
  border-radius: 18px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.78);
}

.audit-lyrics-block h3 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 0.9rem;
  letter-spacing: 0;
}

.audit-lyrics-block p {
  max-height: 180px;
  margin: 0;
  overflow-y: auto;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.6;
  white-space: pre-wrap;
}

.close-button {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  background: var(--white);
  font-size: 1rem;
  font-weight: 900;
  cursor: pointer;
}

@keyframes pulse {
  from {
    transform: scale(0.82) rotate(0deg);
    box-shadow: 0 0 0 rgba(69, 214, 193, 0);
  }
  to {
    transform: scale(1) rotate(45deg);
    box-shadow: 16px 16px 0 var(--lavender-soft);
  }
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 780px) {
  .app-shell {
    padding: 18px;
  }

  .auth-card {
    padding: 26px;
  }

  /* grid is already 1fr — no override needed */

  .dashboard-nav {
    align-items: center;
    flex-direction: row;
    flex-wrap: wrap;
  }

  .dashboard-nav-actions {
    align-items: center;
    gap: 8px;
  }

  /* hero-top stacks on narrow screens */
  .hero-top {
    grid-template-columns: 1fr;
  }

  .management-overview,
  .management-overview.is-management {
    width: 100%;
    grid-template-columns: 1fr;
  }

  .dashboard[data-role="management"] .hero-top {
    grid-template-columns: 1fr;
  }

  .management-overview-totals {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .user-access-layout,
  .creator-target-layout {
    grid-template-columns: 1fr;
    overflow-y: auto;
  }

  .user-access-table-wrap {
    max-height: 34vh;
  }

  #accessLanguageChoices {
    grid-template-columns: 1fr;
  }

  .custom-language-controls {
    grid-template-columns: 1fr;
  }

  .creator-target-fy-row,
  .creator-quarter-row {
    grid-template-columns: 1fr;
  }

  .balance-input-grid {
    grid-template-columns: 1fr;
  }

  .hero-stats,
  .management-overview .hero-stats {
    width: 100%;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 8px;
  }

  .hero-stat {
    padding: 10px 10px;
    border-radius: 12px;
  }

  .hero-stat-value {
    font-size: clamp(1.1rem, 4vw, 1.5rem);
  }

  .hero-panel h1 {
    font-size: clamp(2rem, 7vw, 3.2rem);
  }

  .outline-button {
    width: auto;
  }

  .calendar-header {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .calendar-view-controls {
    max-width: 100%;
  }

  .content-calendar table {
    min-width: 0;
    table-layout: auto;
    font-size: clamp(0.62rem, 2.7vw, 0.78rem);
  }

  .content-calendar th,
  .content-calendar td {
    padding: clamp(8px, 2.4vw, 12px) clamp(5px, 1.8vw, 8px);
  }

  .content-calendar th {
    font-size: clamp(0.5rem, 2vw, 0.62rem);
    letter-spacing: 0;
  }

  .content-calendar th:nth-child(1) {
    font-size: 0;
  }

  .content-calendar th:nth-child(1)::after {
    content: "Date";
    font-size: clamp(0.5rem, 2vw, 0.62rem);
  }

  .content-calendar th:nth-child(2) {
    font-size: 0;
  }

  .content-calendar th:nth-child(2)::after {
    content: "Days Left";
    font-size: clamp(0.5rem, 2vw, 0.62rem);
  }

  .content-calendar th:nth-child(4) {
    font-size: 0;
  }

  .content-calendar th:nth-child(4)::after {
    content: "Song";
    font-size: clamp(0.5rem, 2vw, 0.62rem);
  }

  .content-calendar:not([data-view="best"]) th:nth-child(12),
  .content-calendar:not([data-view="best"]) td:nth-child(12),
  .content-calendar:not([data-view="best"]) th:nth-child(13),
  .content-calendar:not([data-view="best"]) td:nth-child(13) {
    display: none;
  }

  .calendar-details-heading,
  .calendar-details-cell,
  .calendar-action-heading,
  .calendar-action-cell,
  .content-calendar[data-view="past"] .calendar-past-heading,
  .content-calendar[data-view="past"] .calendar-past-cell,
  .content-calendar[data-view="past"] .calendar-metrics-heading,
  .content-calendar[data-view="past"] .calendar-metrics-cell {
    display: table-cell;
  }

  .status-pill {
    min-height: 16px;
    padding: 0 5px;
    font-size: 0.41rem;
  }

  .calendar-details-button,
  .calendar-start-button {
    min-height: 24px;
    padding: 0 9px;
    font-size: 0.56rem;
  }

  .calendar-start-button {
    width: auto;
    min-width: 58px;
    min-height: 28px;
    padding: 0 10px;
  }

  .project-details-list {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

/* Extra-small: stats wrap to 2×2, nav stacks */
@media (max-width: 480px) {
  body {
    background-attachment: scroll;
  }

  .app-shell {
    place-items: start center;
    padding: 10px;
  }

  .auth-card {
    padding: 22px 18px;
    border-radius: 22px;
  }

  .dashboard-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .dashboard-nav-actions {
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .dashboard-logs-menu {
    width: 100%;
  }

  .dashboard-logs-dropdown {
    position: static;
    margin-top: 8px;
  }

  .outline-button {
    width: 100%;
  }

  .dashboard-link-button {
    justify-content: center;
  }

  .creator-trending-videos {
    border-radius: 18px;
    padding: 14px;
  }

  .creator-trending-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .creator-trending-controls {
    width: 100%;
    justify-content: flex-end;
    flex-wrap: wrap;
  }

  .creator-trending-history-link {
    min-height: 34px;
  }

  .creator-trending-track {
    grid-auto-columns: minmax(230px, 84vw);
  }

  .hero-stats,
  .management-overview .hero-stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .management-overview-totals {
    grid-template-columns: 1fr;
  }

  .hero-panel,
  .content-calendar {
    border-radius: 18px;
    padding: 16px;
  }

  .hero-action-row {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .calendar-table-wrap {
    margin-inline: -10px;
    padding-inline: 10px;
  }

  .content-calendar table {
    min-width: 920px;
  }

  .modal {
    width: min(100%, calc(100vw - 20px));
    max-height: calc(100vh - 24px);
    overflow: auto;
    border-radius: 20px;
  }
}

@media (max-width: 420px) {
  .auth-card,
  .modal {
    border-width: 4px;
  }

  .password-wrap {
    grid-template-columns: 1fr;
  }

  .ghost-button {
    min-height: 44px;
    border-radius: 0 0 18px 18px;
    border-left: 0;
    border-top: 2px solid var(--line);
  }
}

@media (max-width: 640px) {
  html,
  body,
  .app-shell,
  .dashboard,
  .dashboard-grid,
  .hero-panel,
  .content-calendar,
  .calendar-table-wrap {
    max-width: 100vw;
    overflow-x: hidden;
  }

  .dashboard {
    width: 100%;
  }

  .dashboard-nav {
    position: sticky;
    top: 0;
    z-index: 20;
    width: calc(100% + 20px);
    max-width: calc(100vw);
    margin: -10px -10px 12px;
    padding: 10px;
    border-radius: 0 0 18px 18px;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    box-shadow: 0 12px 28px rgba(9, 6, 20, 0.1);
  }

  .dashboard-brand-actions {
    justify-content: space-between;
    width: 100%;
    min-width: 0;
  }

  .dashboard-nav .brand-mark {
    color: var(--ink);
    text-shadow: none;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
  }

  .global-logout-button,
  #logoutButton {
    min-height: 30px;
    padding: 0 9px;
    font-size: 0.58rem;
  }

  .dashboard-nav-actions {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-width: 0;
  }

  .dashboard-link-button,
  .new-project-button,
  .cta-button {
    min-height: 42px;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    padding-inline: 10px;
    font-size: 0.66rem;
    white-space: normal;
    line-height: 1.15;
  }

  .hero-panel {
    padding: 14px;
    border-radius: 18px;
    width: 100%;
  }

  .hero-panel h1 {
    font-size: clamp(1.75rem, 10vw, 2.55rem);
  }

  .hero-identity > p:not(.eyebrow) {
    font-size: 0.84rem;
    line-height: 1.55;
  }

  .hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    min-width: 0;
  }

  .hero-stat {
    min-width: 0;
    padding: 10px 9px;
  }

  .hero-stat-label {
    font-size: 0.52rem;
  }

  .content-calendar {
    width: 100%;
    max-width: 100%;
    padding: 0;
    border-radius: 16px;
    overflow: visible;
  }

  .calendar-header {
    padding: 14px;
    border-radius: 16px 16px 0 0;
  }

  .calendar-header h2 {
    font-size: 0.98rem;
  }

  .calendar-view-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible;
    gap: 8px;
    min-width: 0;
  }

  .calendar-view-select-wrap {
    display: flex;
  }

  .calendar-view-select-wrap select {
    width: 100%;
    max-width: none;
  }

  .dashboard[data-role="management"] .calendar-view-controls {
    display: none;
  }

  .calendar-toggle {
    min-height: 40px;
    padding: 0 10px;
    font-size: 0.66rem;
    white-space: normal;
    line-height: 1.15;
  }

  .creator-filter {
    align-items: stretch;
    flex-direction: column;
    text-align: left;
  }

  .creator-filter select {
    width: 100%;
    max-width: none;
  }

  .creator-ranking {
    padding: 12px;
  }

  .creator-rank-item {
    grid-template-columns: 20px 32px minmax(238px, 1fr);
  }

  .creator-rank-score-wrap {
    grid-column: 1 / -1;
    align-items: stretch;
    padding-left: 68px;
  }

  .creator-rank-bar-track {
    width: 100%;
  }

  .calendar-table-wrap {
    margin: 0;
    padding: 12px;
    overflow: visible;
    max-width: 100%;
  }

  .content-calendar table,
  .content-calendar thead,
  .content-calendar tbody,
  .content-calendar tr,
  .content-calendar th,
  .content-calendar td {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .content-calendar table {
    min-width: 0 !important;
    table-layout: auto !important;
    border-collapse: separate;
    border-spacing: 0;
  }

  .content-calendar thead {
    display: none !important;
  }

  .content-calendar tbody {
    display: grid !important;
    gap: 12px;
  }

  .content-calendar tbody tr {
    display: grid !important;
    gap: 0;
    overflow: hidden;
    max-width: 100%;
    border: 1px solid rgba(5, 5, 5, 0.12);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 12px 30px rgba(9, 6, 20, 0.08);
  }

  .content-calendar th,
  .content-calendar td,
  .content-calendar:not([data-view="best"]) td:nth-child(12),
  .content-calendar:not([data-view="best"]) td:nth-child(13),
  .calendar-details-cell,
  .calendar-action-cell,
  .content-calendar[data-view="past"] .calendar-past-cell,
  .content-calendar[data-view="past"] .calendar-metrics-cell {
    display: grid;
  }

  .content-calendar td {
    display: grid !important;
    grid-template-columns: minmax(92px, 0.38fr) minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(5, 5, 5, 0.08);
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    word-break: break-word;
    overflow-wrap: anywhere;
    font-size: 0.78rem;
  }

  .content-calendar td > * {
    min-width: 0;
    max-width: 100%;
  }

  .content-calendar tbody tr td:last-child {
    border-bottom: 0;
  }

  .content-calendar td::before {
    color: rgba(5, 5, 5, 0.56);
    font-size: 0.56rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    content: "Field";
  }

  .content-calendar:not([data-view="best"]) td:nth-child(1)::before { content: "Date"; }
  .content-calendar:not([data-view="best"]) td:nth-child(2)::before { content: "Time Left"; }
  .content-calendar:not([data-view="best"]) td:nth-child(3)::before { content: "Language"; }
  .content-calendar:not([data-view="best"]) td:nth-child(4)::before { content: "Song"; }
  .content-calendar:not([data-view="best"]) td:nth-child(5)::before { content: "Notes"; }
  .content-calendar:not([data-view="best"]) td:nth-child(6)::before { content: "Status"; }
  .content-calendar:not([data-view="best"]) td:nth-child(7)::before { content: "Song Link"; }
  .content-calendar:not([data-view="best"]) td:nth-child(8)::before { content: "Lyrics"; }
  .content-calendar:not([data-view="best"]) td:nth-child(9)::before { content: "Final / Temp URL"; }
  .content-calendar:not([data-view="best"]) td:nth-child(10)::before { content: "Details"; }
  .content-calendar:not([data-view="best"]) td:nth-child(11)::before { content: "Action"; }
  .content-calendar:not([data-view="best"]) td:nth-child(12)::before { content: "Score"; }
  .content-calendar:not([data-view="best"]) td:nth-child(13)::before { content: "Metrics"; }

  .content-calendar[data-view="best"] td:nth-child(1)::before { content: "Song"; }
  .content-calendar[data-view="best"] td:nth-child(2)::before { content: "Creator"; }
  .content-calendar[data-view="best"] td:nth-child(3)::before { content: "Views"; }
  .content-calendar[data-view="best"] td:nth-child(4)::before { content: "Language"; }
  .content-calendar[data-view="best"] td:nth-child(5)::before { content: "Type"; }
  .content-calendar[data-view="best"] td:nth-child(6)::before { content: "Song Link"; }
  .content-calendar[data-view="best"] td:nth-child(7)::before { content: "Metrics"; }

  .calendar-details-button,
  .calendar-start-button,
  .calendar-asset-button,
  .calendar-video-link,
  .calendar-song-link {
    justify-self: start;
    min-height: 34px;
    max-width: 100%;
    white-space: normal;
    line-height: 1.15;
    overflow-wrap: anywhere;
  }

  .calendar-start-button {
    min-width: 104px;
    font-size: 0.68rem;
  }

  .calendar-supergen-button {
    margin-left: 0;
    margin-top: 6px;
  }

  .status-pill {
    justify-self: start;
    min-height: 26px;
    padding: 4px 9px;
    font-size: 0.58rem;
    white-space: normal;
    line-height: 1.2;
  }
}

@media (max-width: 380px) {
  .calendar-view-controls,
  .dashboard-nav-actions,
  .hero-stats {
    grid-template-columns: 1fr;
  }

  .content-calendar td {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .creator-rank-score-wrap {
    padding-left: 0;
  }
}

/* Global Divyaverse button capitalization */
button,
[role="button"],
.primary-button,
.outline-button,
.compact-button,
.cta-button,
.ghost-button,
.idea-button,
.nav-link,
.dashboard-link-button,
.dashboard-log-option,
.calendar-toggle,
.calendar-details-button,
.calendar-start-button,
.calendar-asset-button,
.calendar-video-link,
.calendar-song-link,
.festival-calendar-button,
.festival-vault-button {
  text-transform: uppercase !important;
}

.concept-agent-backdrop {
  align-items: center;
  justify-content: center;
  padding: clamp(14px, 3vw, 44px);
  background:
    radial-gradient(circle at 50% 110%, rgba(216, 170, 85, 0.34), transparent 34%),
    radial-gradient(circle at 12% 22%, rgba(0, 138, 120, 0.42), transparent 34%),
    radial-gradient(circle at 82% 12%, rgba(241, 211, 139, 0.22), transparent 30%),
    rgba(2, 6, 22, 0.76);
  backdrop-filter: blur(18px);
}

.concept-agent-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: clamp(18px, 3vw, 36px);
  width: min(1240px, 100%);
  max-height: min(860px, calc(100dvh - 28px));
  overflow: auto;
  border: 2px solid rgba(232, 238, 255, 0.76);
  border-radius: clamp(24px, 3vw, 38px);
  padding: clamp(18px, 3vw, 34px);
  color: #fff;
  background:
    radial-gradient(circle at 40% 45%, rgba(0, 138, 120, 0.38), transparent 34%),
    radial-gradient(circle at 72% 68%, rgba(216, 170, 85, 0.18), transparent 28%),
    linear-gradient(145deg, rgba(13, 8, 28, 0.98), rgba(36, 18, 62, 0.94) 56%, rgba(9, 7, 24, 0.98));
  box-shadow: 0 38px 120px rgba(0, 0, 0, 0.58);
}

.concept-agent-close,
.concept-agent-gear {
  position: absolute;
  top: 20px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  color: rgba(255,255,255,0.92);
  background: rgba(255,255,255,0.08);
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 2;
}

.concept-agent-close {
  right: 20px;
  font-weight: 950;
}

.concept-agent-gear {
  right: 70px;
}

.concept-agent-gear svg,
.concept-agent-controls svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.concept-agent-stage {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: min(680px, calc(100dvh - 96px));
  gap: clamp(14px, 2vw, 24px);
  padding: clamp(22px, 5vw, 70px) 8px;
  text-align: center;
}

.concept-agent-eyebrow {
  margin: 0;
  color: rgba(241, 211, 139, 0.92);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.concept-agent-stage h2 {
  margin: 0;
  color: #f8fbff;
  font-size: clamp(2rem, 5vw, 5rem);
  font-weight: 950;
  line-height: 0.98;
  letter-spacing: 0;
}

.concept-agent-orb {
  width: clamp(132px, 17vw, 220px);
  aspect-ratio: 1;
  border-radius: 999px;
  background:
    radial-gradient(circle at 26% 22%, rgba(255, 255, 255, 0.58), transparent 11%),
    radial-gradient(circle at 74% 67%, rgba(241, 211, 139, 0.95), transparent 34%),
    radial-gradient(circle at 30% 72%, rgba(0, 138, 120, 0.9), transparent 43%),
    linear-gradient(135deg, #006b5f, #008a78 54%, #d8aa55);
  box-shadow:
    inset 18px 18px 42px rgba(0, 0, 0, 0.34),
    0 0 0 10px rgba(241, 211, 139, 0.12),
    0 34px 90px rgba(0, 138, 120, 0.34);
  animation: conceptAgentOrbPulse 1.65s ease-in-out infinite;
}

@keyframes conceptAgentOrbPulse {
  0%, 100% { transform: translateY(0) scale(1); filter: saturate(1); }
  50% { transform: translateY(-7px) scale(1.045); filter: saturate(1.18); }
}

.concept-agent-speech {
  max-width: 760px;
  margin: 0;
  color: rgba(246, 249, 255, 0.94);
  font-size: clamp(1.18rem, 2.3vw, 2.2rem);
  font-weight: 900;
  line-height: 1.3;
}

.concept-agent-status {
  min-height: 24px;
  margin: 0;
  color: rgba(219, 229, 255, 0.74);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.concept-agent-controls {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(217, 226, 255, 0.34);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
}

.concept-agent-controls button {
  width: 72px;
  height: 72px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: rgba(111, 135, 202, 0.34);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.concept-agent-controls button:last-child,
.concept-agent-controls button.is-listening {
  background: linear-gradient(135deg, rgba(0, 138, 120, 0.92), rgba(216, 170, 85, 0.86));
}

.concept-agent-controls button.is-listening {
  box-shadow: 0 0 0 8px rgba(216, 170, 85, 0.14), 0 24px 64px rgba(0, 138, 120, 0.32);
  animation: conceptAgentMicPulse 1.15s ease-in-out infinite;
}

@keyframes conceptAgentMicPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

.concept-agent-workbench {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: clamp(16px, 2vw, 24px);
  border: 1px solid rgba(241, 211, 139, 0.22);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.075);
}

.concept-agent-progress {
  display: grid;
  gap: 8px;
}

.concept-agent-step {
  display: flex;
  align-items: center;
  min-height: 34px;
  border: 1px solid rgba(232, 238, 255, 0.14);
  border-radius: 999px;
  padding: 0 12px;
  color: rgba(240, 245, 255, 0.68);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.72rem;
  font-weight: 950;
}

.concept-agent-step.is-active {
  border-color: rgba(241, 211, 139, 0.54);
  color: #fff;
  background: rgba(241, 211, 139, 0.12);
}

.concept-agent-step.is-done {
  border-color: rgba(91, 255, 184, 0.42);
  color: #dffff4;
  background: rgba(91, 255, 184, 0.11);
}

.concept-agent-workbench label {
  color: rgba(240,245,255,0.84);
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.concept-agent-text-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.concept-agent-text-row input {
  min-height: 44px;
  border: 1px solid rgba(232, 238, 255, 0.18);
  border-radius: 999px;
  padding: 0 14px;
  color: #fff;
  background: rgba(255,255,255,0.08);
  font: inherit;
  outline: none;
}

.concept-agent-draft {
  display: grid;
  gap: 10px;
}

.concept-agent-draft div {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(232, 238, 255, 0.12);
  border-radius: 14px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.055);
}

.concept-agent-draft strong {
  color: rgba(177, 197, 255, 0.94);
  font-size: 0.72rem;
  font-weight: 950;
  text-transform: uppercase;
}

.concept-agent-draft span {
  color: rgba(255,255,255,0.88);
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.45;
}

.concept-agent-final-note {
  border-color: rgba(241, 211, 139, 0.32) !important;
  background: rgba(241, 211, 139, 0.1) !important;
}

.concept-agent-push,
.concept-agent-open-project {
  justify-self: stretch;
  text-align: center;
}

@media (max-width: 860px) {
  .concept-agent-panel {
    grid-template-columns: 1fr;
  }

  .concept-agent-stage {
    min-height: auto;
    padding-top: 54px;
  }
}

/* Mobile comfort layer: keeps dashboard actions, cards, and tables usable on phones. */
@media (max-width: 640px) {
  button,
  input,
  select,
  textarea {
    font-size: max(16px, 1rem);
  }

  button,
  .primary-button,
  .outline-button,
  .compact-button,
  .cta-button,
  .dashboard-link-button,
  .new-project-button {
    min-height: 44px;
    border-radius: 14px;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .brand-mark {
    width: min(260px, 76vw);
    height: 54px;
    margin-bottom: 0;
  }

  .dashboard-nav {
    gap: 10px;
  }

  .dashboard-nav-actions {
    gap: 8px;
  }

  .dashboard-logs-menu,
  .dashboard-logs-menu > button {
    width: 100%;
  }

  .hero-panel,
  .content-calendar,
  .creator-trending-videos,
  .management-overview {
    box-shadow: 0 14px 34px rgba(9, 6, 20, 0.1);
  }

  .hero-top,
  .hero-identity,
  .headline-block {
    min-width: 0;
  }

  .hero-panel h1,
  .headline-block h1,
  .headline-block h2 {
    overflow-wrap: anywhere;
  }

  .hero-action-row > *,
  .calendar-view-controls > *,
  .dashboard-nav-actions > * {
    min-width: 0;
  }

  .modal {
    padding: 18px;
  }
}

@media (max-width: 420px) {
  .app-shell {
    padding: 8px;
  }

  .auth-card,
  .modal,
  .hero-panel,
  .content-calendar,
  .creator-trending-videos {
    border-radius: 16px;
  }

  .dashboard-nav-actions,
  .hero-action-row,
  .calendar-view-controls,
  .hero-stats,
  .management-overview .hero-stats {
    grid-template-columns: 1fr;
  }

  .content-calendar td {
    padding: 9px 10px;
  }
}

/* Mobile dashboard polish: denser, softer project cards for phone screens. */
@media (max-width: 640px) {
  .app-shell {
    padding-inline: 8px;
  }

  .dashboard-nav {
    border: 1px solid rgba(255, 255, 255, 0.62);
    background: rgba(255, 255, 255, 0.9);
  }

  .dashboard-brand-actions {
    gap: 8px;
  }

  .creator-wallet-chip {
    min-height: 30px;
    padding: 0 10px;
    color: var(--white);
    font-size: 0.7rem;
  }

  .creator-wallet-history-link {
    width: 30px;
    min-width: 30px;
    height: 30px;
  }

  .dashboard-link-button,
  .new-project-button,
  .cta-button,
  .outline-button {
    min-height: 40px;
    border-width: 2px;
    border-radius: 13px;
    font-size: 0.72rem;
    line-height: 1.12;
  }

  .creator-trending-videos {
    padding: 15px;
    border-radius: 18px;
  }

  .creator-trending-header {
    gap: 10px;
    margin-bottom: 10px;
  }

  .creator-trending-header h2 {
    font-size: clamp(1.35rem, 8vw, 2rem);
    line-height: 1.04;
  }

  .creator-trending-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }

  .creator-trending-status {
    font-size: 0.86rem;
    line-height: 1.55;
  }

  .hero-panel {
    padding: 14px;
  }

  .hero-panel h1 {
    font-size: clamp(2rem, 12vw, 3rem);
    letter-spacing: 0;
  }

  .content-calendar {
    border: 1px solid rgba(5, 5, 5, 0.08);
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 14px 34px rgba(9, 6, 20, 0.08);
  }

  .calendar-header {
    gap: 10px;
    padding: 13px;
    background: rgba(255, 255, 255, 0.78);
  }

  .calendar-kicker {
    margin-bottom: 4px;
    font-size: 0.62rem;
    letter-spacing: 0.1em;
  }

  .calendar-header h2 {
    font-size: 0.9rem;
    line-height: 1.25;
  }

  .calendar-view-select-wrap {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    width: 100%;
    font-size: 0.84rem;
  }

  .calendar-view-select-wrap select {
    min-height: 38px;
    border-width: 2px;
    font-size: 0.88rem;
  }

  .calendar-table-wrap {
    padding: 10px;
  }

  .content-calendar tbody {
    gap: 10px;
  }

  .content-calendar tbody tr {
    border-color: rgba(5, 5, 5, 0.09);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 10px 24px rgba(9, 6, 20, 0.075);
  }

  .content-calendar tr.is-delayed td,
  .content-calendar tr.is-unassigned td {
    background: transparent;
  }

  .content-calendar td {
    grid-template-columns: minmax(78px, 0.3fr) minmax(0, 1fr);
    min-height: 37px;
    padding: 9px 12px;
    gap: 9px;
    color: #32293c;
    font-size: 0.78rem;
    line-height: 1.28;
  }

  .content-calendar td::before {
    align-self: center;
    color: rgba(50, 41, 60, 0.62);
    font-size: 0.62rem;
    letter-spacing: 0.055em;
    line-height: 1.2;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(4),
  .content-calendar[data-view="best"] td:nth-child(1) {
    color: #a92d2d;
    font-size: 0.92rem;
    font-weight: 900;
    letter-spacing: 0;
    line-height: 1.22;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(10),
  .content-calendar:not([data-view="best"]) td:nth-child(11) {
    align-items: start;
  }

  .calendar-details-button,
  .calendar-start-button,
  .calendar-asset-button,
  .calendar-video-link,
  .calendar-song-link {
    min-height: 32px;
    border-width: 1.5px;
    padding: 0 11px;
    border-radius: 999px;
    font-size: 0.68rem;
    line-height: 1.1;
    box-shadow: none;
  }

  .calendar-song-control {
    justify-self: stretch;
    width: min(112px, 100%);
    min-width: 100px;
  }

  .calendar-song-play-button {
    justify-self: start;
    min-width: 112px;
    min-height: 32px;
    padding: 0 12px;
    border-width: 2px;
    font-size: 0.7rem;
    white-space: nowrap;
  }

  .calendar-song-progress-wrap {
    min-width: 100px;
    min-height: 22px;
    padding-block: 0;
  }

  .calendar-song-progress {
    height: 22px;
  }

  .calendar-asset-button,
  .calendar-video-link {
    border-width: 2px;
  }

  .calendar-start-button {
    min-width: 96px;
    min-height: 38px;
    padding: 0 15px;
    color: #fff;
    border-color: #f47c2f;
    background: #f47c2f;
    font-size: 0.74rem;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(5),
  .content-calendar:not([data-view="best"]) td:nth-child(7),
  .content-calendar:not([data-view="best"]) td:nth-child(8),
  .content-calendar:not([data-view="best"]) td:nth-child(9),
  .content-calendar:not([data-view="best"]) td:nth-child(10),
  .content-calendar:not([data-view="best"]) td:nth-child(12),
  .content-calendar:not([data-view="best"]) td:nth-child(13) {
    display: none !important;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(11) {
    grid-template-columns: 1fr;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(11)::before {
    content: "Next action";
  }

  .calendar-action-cell {
    gap: 8px;
  }

  .calendar-action-cell .calendar-details-button:not(.calendar-supergen-button),
  .calendar-action-cell .calendar-start-button {
    width: 100%;
    justify-self: stretch;
  }

  .calendar-supergen-button {
    min-height: 32px;
    margin-top: 6px;
    color: var(--lavender-deep);
    background: #f3eaff;
  }

  .status-pill {
    min-height: 27px;
    padding: 5px 10px;
    font-size: 0.66rem;
    line-height: 1.15;
  }
}

@media (max-width: 420px) {
  .dashboard-nav-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-logs-menu {
    grid-column: 1 / -1;
  }

  .content-calendar td {
    grid-template-columns: minmax(82px, 0.36fr) minmax(0, 1fr);
    padding: 8px 10px;
  }

  .calendar-details-button,
  .calendar-start-button,
  .calendar-asset-button,
  .calendar-video-link,
  .calendar-song-play-button,
  .calendar-song-link {
    font-size: 0.66rem;
  }
}

.api-logs-modal {
  width: min(1120px, calc(100vw - 28px));
  max-height: min(820px, calc(100vh - 28px));
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.api-logs-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 16px 0;
}

.api-logs-toolbar label {
  display: grid;
  gap: 6px;
  min-width: min(260px, 100%);
  color: rgba(64, 43, 94, 0.82);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.api-logs-toolbar select {
  min-height: 42px;
  border: 1px solid rgba(87, 66, 120, 0.22);
  border-radius: 12px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.86);
  color: #241936;
  font: inherit;
  font-weight: 700;
}

.api-logs-table-wrap {
  min-height: 260px;
  overflow: auto;
  border: 1px solid rgba(87, 66, 120, 0.14);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.64);
}

.api-logs-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
  color: #251734;
  font-size: 0.82rem;
}

.api-logs-table th,
.api-logs-table td {
  padding: 12px;
  border-bottom: 1px solid rgba(87, 66, 120, 0.12);
  text-align: left;
  vertical-align: top;
}

.api-logs-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(245, 241, 255, 0.96);
  color: rgba(64, 43, 94, 0.82);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.api-logs-table td:nth-child(3) {
  max-width: 420px;
}

.api-logs-table code {
  display: block;
  overflow-wrap: anywhere;
  color: #21172e;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.74rem;
  line-height: 1.45;
}

.api-logs-table small {
  display: block;
  margin-top: 7px;
  color: rgba(64, 43, 94, 0.62);
  overflow-wrap: anywhere;
}

.api-logs-table td:nth-child(2) strong,
.api-logs-table td:nth-child(2) span {
  display: block;
}

.api-logs-table td:nth-child(2) span {
  margin-top: 4px;
  color: rgba(64, 43, 94, 0.62);
  font-size: 0.72rem;
  font-weight: 800;
}

.api-logs-table tr.is-failed {
  background: rgba(186, 66, 47, 0.09);
}

.api-logs-table tr.is-failed td:nth-child(4),
.api-logs-table tr.is-failed td:nth-child(6) {
  color: #9f2d22;
  font-weight: 800;
}

.api-logs-table tr.is-ok td:nth-child(4) {
  color: #217743;
  font-weight: 800;
}

@media (max-width: 720px) {
  .api-logs-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .api-logs-toolbar .outline-button,
  .api-logs-toolbar .danger-button {
    width: 100%;
  }
}

/* Creator profile / project history */
.creator-profile-modal {
  width: min(1120px, calc(100vw - 28px));
  max-height: min(86vh, 920px);
  overflow-y: auto;
}

.creator-profile-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin: 18px 0;
}

.creator-profile-log-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: center;
  gap: 14px;
  margin: 14px 0 6px;
  padding: 14px;
  border: 1px solid rgba(0, 138, 120, 0.18);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(246, 240, 255, 0.9));
}

.creator-profile-log-panel p {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.45;
}

.creator-profile-log-panel .panel-label {
  margin-bottom: 4px;
  color: var(--lavender-deep);
}

.creator-profile-quickgen-row {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
}

.creator-profile-quickgen-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  text-decoration: none;
  white-space: nowrap;
}

.creator-profile-stat-card {
  padding: 14px;
  border: 1px solid rgba(5, 5, 5, 0.12);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(255,255,255,0.92), rgba(247,243,255,0.86));
  box-shadow: 0 12px 28px rgba(31, 20, 55, 0.08);
}

.creator-profile-stat-card strong {
  display: block;
  color: var(--ink);
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 1000;
  line-height: 1;
}

.creator-profile-stat-card span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
}

.creator-profile-projects {
  display: grid;
  gap: 12px;
}

.creator-profile-project-card {
  padding: 16px;
  border: 1px solid rgba(5, 5, 5, 0.12);
  border-radius: 18px;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 14px 34px rgba(31, 20, 55, 0.08);
}

.creator-profile-project-head,
.creator-profile-project-actions,
.creator-profile-project-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.creator-profile-project-head {
  justify-content: space-between;
  gap: 14px;
}

.creator-profile-project-head strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 1000;
}

.creator-profile-project-head span,
.creator-profile-project-meta span,
.creator-profile-prompt-preview span,
.creator-profile-empty-link {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.creator-profile-project-meta {
  margin-top: 10px;
}

.creator-profile-project-meta span {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(0, 138, 120, 0.08);
}

.creator-profile-prompt-preview {
  display: grid;
  gap: 6px;
  margin: 12px 0;
}

.creator-profile-prompt-preview span {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.creator-profile-project-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  font-size: 0.68rem;
  font-weight: 950;
  text-decoration: none;
  text-transform: uppercase;
}

@media (max-width: 720px) {
  .creator-profile-log-panel {
    grid-template-columns: 1fr;
  }

  .creator-profile-quickgen-row {
    justify-content: stretch;
  }

  .creator-profile-quickgen-link {
    flex: 1 1 160px;
  }
}

.creator-log-button {
  margin-top: 6px;
}

/* Navbar UX polish: keeps account controls grouped and action buttons aligned. */
.dashboard-nav {
  display: grid;
  grid-template-columns: minmax(260px, auto) minmax(420px, 1fr);
  align-items: center;
  gap: 14px;
}

.dashboard-brand-actions {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.dashboard-brand-actions .brand-mark {
  flex: 1 1 auto;
  min-width: 190px;
}

.dashboard-nav-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
  align-items: stretch;
  justify-content: stretch;
  gap: 9px;
  min-width: 0;
}

.dashboard-nav-actions > *,
.dashboard-logs-menu,
.dashboard-logs-menu > summary,
.dashboard-link-button {
  min-width: 0;
}

.dashboard-link-button,
.dashboard-logs-menu > summary {
  width: 100%;
  min-height: 40px;
  padding-inline: 12px;
}

.global-logout-button,
#logoutButton,
.creator-wallet-chip,
.creator-wallet-history-link {
  flex: 0 0 auto;
}

@media (max-width: 980px) {
  .dashboard-nav {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .dashboard-nav {
    gap: 10px;
    padding: 10px;
  }

  .dashboard-brand-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
    width: 100%;
  }

  .dashboard-brand-actions .brand-mark {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .global-logout-button,
  #logoutButton {
    min-height: 34px;
    width: 100%;
    padding-inline: 12px;
  }

  .creator-wallet-chip {
    justify-content: center;
    min-width: 0;
    width: 100%;
    padding-inline: 10px;
  }

  .creator-wallet-history-link {
    width: 34px;
    min-width: 34px;
    height: 34px;
  }

  .dashboard-nav-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
}

@media (max-width: 390px) {
  .dashboard-nav-actions {
    grid-template-columns: 1fr;
  }
}

/* Dashboard wide-layout polish: use the screen generously and keep row content readable. */
.dashboard {
  width: min(95vw, 1880px);
  max-width: 95vw;
  position: relative;
  overflow: visible;
}

/* Keep header menus above dashboard cards. */
.dashboard-nav {
  position: relative;
  z-index: 12000;
  overflow: visible;
  isolation: isolate;
}

.dashboard-nav-actions,
.dashboard-logs-menu {
  position: relative;
  z-index: 12010;
  overflow: visible;
}

.dashboard-logs-menu[open] {
  z-index: 12020;
}

.dashboard-logs-dropdown {
  z-index: 12030;
}

.dashboard-grid,
.hero-panel,
.content-calendar,
.creator-trending-videos {
  width: 100%;
  min-width: 0;
}

.hero-panel {
  padding-inline: clamp(18px, 2vw, 34px);
}

.calendar-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.content-calendar table {
  width: 100%;
  min-width: min(1320px, 100%);
  table-layout: fixed;
}

.content-calendar th,
.content-calendar td {
  padding-inline: clamp(6px, 0.55vw, 11px);
  overflow-wrap: anywhere;
}

.content-calendar td {
  white-space: normal;
  text-overflow: clip;
}

.content-calendar th:nth-child(1),
.content-calendar td:nth-child(1) {
  width: 7.5%;
}

.content-calendar th:nth-child(2),
.content-calendar td:nth-child(2) {
  width: 8.5%;
}

.content-calendar th:nth-child(3),
.content-calendar td:nth-child(3) {
  width: 7%;
}

.content-calendar th:nth-child(4),
.content-calendar td:nth-child(4) {
  width: 16%;
}

.content-calendar th:nth-child(5),
.content-calendar td:nth-child(5) {
  width: 7.5%;
}

.content-calendar th:nth-child(6),
.content-calendar td:nth-child(6) {
  width: 10%;
}

.content-calendar th:nth-child(7),
.content-calendar td:nth-child(7),
.content-calendar th:nth-child(8),
.content-calendar td:nth-child(8),
.content-calendar th:nth-child(10),
.content-calendar td:nth-child(10),
.content-calendar th:nth-child(13),
.content-calendar td:nth-child(13) {
  width: 7.5%;
}

.content-calendar th:nth-child(9),
.content-calendar td:nth-child(9),
.content-calendar th:nth-child(11),
.content-calendar td:nth-child(11) {
  width: 9%;
}

.content-calendar th:nth-child(12),
.content-calendar td:nth-child(12) {
  width: 5%;
}

.content-calendar td:nth-child(4) {
  color: #a92d2d;
  font-size: clamp(0.82rem, 0.9vw, 1.02rem);
  font-weight: 900;
  line-height: 1.22;
}

.content-calendar:not([data-view="best"]) th:nth-child(1),
.content-calendar:not([data-view="best"]) td:nth-child(1) {
  width: 6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(2),
.content-calendar:not([data-view="best"]) td:nth-child(2) {
  width: 6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(3),
.content-calendar:not([data-view="best"]) td:nth-child(3) {
  width: 6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(4),
.content-calendar:not([data-view="best"]) td:nth-child(4) {
  width: 19%;
}

.content-calendar:not([data-view="best"]) th:nth-child(5),
.content-calendar:not([data-view="best"]) td:nth-child(5) {
  width: 7%;
}

.content-calendar:not([data-view="best"]) th:nth-child(6),
.content-calendar:not([data-view="best"]) td:nth-child(6) {
  width: 8.5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(7),
.content-calendar:not([data-view="best"]) td:nth-child(7) {
  width: 9%;
}

.content-calendar:not([data-view="best"]) th:nth-child(8),
.content-calendar:not([data-view="best"]) td:nth-child(8) {
  width: 7.5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(9),
.content-calendar:not([data-view="best"]) td:nth-child(9) {
  width: 8.5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(10),
.content-calendar:not([data-view="best"]) td:nth-child(10) {
  width: 8.5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(11),
.content-calendar:not([data-view="best"]) td:nth-child(11) {
  width: 14%;
}

.status-pill,
.calendar-details-button,
.calendar-start-button,
.calendar-asset-button,
.calendar-video-link,
.calendar-song-link {
  max-width: 100%;
  white-space: normal;
  line-height: 1.14;
}

.calendar-details-button,
.calendar-start-button,
.calendar-asset-button,
.calendar-video-link {
  min-width: min(104px, 100%);
  justify-content: center;
}

.calendar-song-control {
  width: min(126px, 100%);
  min-width: min(126px, 100%);
}

.calendar-song-play-button {
  width: min(126px, 100%);
  min-width: min(126px, 100%);
}

.calendar-song-progress-wrap {
  width: min(126px, 100%);
  min-width: min(126px, 100%);
}

@media (min-width: 641px) {
  .content-calendar tbody tr {
    min-height: 58px;
  }

  .content-calendar td {
    height: auto;
  }
}

@media (max-width: 640px) {
  .dashboard {
    width: min(95vw, calc(100vw - 16px));
    max-width: min(95vw, calc(100vw - 16px));
  }

  .app-shell {
    padding-inline: max(8px, 2.5vw);
  }

  .dashboard-nav {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
  }

  .hero-panel,
  .content-calendar,
  .creator-trending-videos {
    width: 100%;
  }

  .content-calendar tbody tr {
    width: 100%;
  }

  .content-calendar td {
    grid-template-columns: minmax(86px, 0.34fr) minmax(0, 1fr);
  }

  .calendar-song-control,
  .calendar-song-play-button,
  .calendar-song-progress-wrap {
    width: min(140px, 100%);
    min-width: min(112px, 100%);
  }
}

/* Dashboard density pass: cleaner single-view desktop, compact controls, tighter table columns. */
.app-shell {
  padding: clamp(8px, 1vw, 14px);
}

.dashboard {
  width: min(98vw, 1840px);
  max-width: 98vw;
}

.dashboard-nav {
  margin-bottom: 12px;
}

.creator-trending-videos {
  margin-bottom: 12px;
  padding: clamp(12px, 1.2vw, 18px);
  border-radius: 16px;
}

.creator-trending-header {
  margin-bottom: 10px;
}

.creator-trending-header h2 {
  font-size: clamp(1.2rem, 1.8vw, 1.8rem);
}

.creator-trending-arrow {
  width: 34px;
  height: 34px;
  font-size: 1.1rem;
}

.creator-trending-history-link {
  min-height: 30px;
  padding-inline: 12px;
  font-size: 0.62rem;
}

.creator-video-project-card {
  min-width: min(330px, 82vw);
}

.creator-video-job-meter {
  min-height: 118px;
  padding: 14px;
}

.creator-video-job-meter strong {
  font-size: clamp(1.35rem, 2.4vw, 2rem);
}

.creator-trending-copy {
  padding: 10px 12px 12px;
}

.hero-panel {
  padding: clamp(14px, 1.35vw, 22px);
  border-radius: 16px;
}

.hero-top {
  gap: clamp(14px, 1.6vw, 26px);
  padding-bottom: clamp(10px, 1.2vw, 16px);
}

.hero-panel h1 {
  max-width: 640px;
  margin-bottom: 6px;
  font-size: clamp(1.9rem, 3.2vw, 3rem);
}

.hero-identity > p:not(.eyebrow) {
  max-width: 500px;
  margin: 6px 0 12px;
  font-size: 0.82rem;
  line-height: 1.5;
}

.hero-action-row {
  gap: 8px;
}

.cta-button,
.new-project-button,
.user-admin-button,
.engine-shortcut-button {
  width: auto;
  min-width: 0;
  min-height: 34px;
  padding: 0 14px;
  border-width: 2px;
  font-size: 0.68rem;
  line-height: 1;
  white-space: nowrap;
}

.dashboard-balance-card {
  width: min(100%, 280px);
  margin-top: 10px;
  padding: 11px 13px;
  border-color: #050505;
  background: #050505;
  box-shadow: 0 14px 34px rgba(5, 5, 5, 0.2);
}

.dashboard-balance-label,
.dashboard-balance-card span:last-child {
  color: rgba(255, 255, 255, 0.72);
}

.dashboard-balance-card strong {
  color: #fff;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
}

.management-overview:not(.is-management) {
  width: min(420px, 36vw);
}

.hero-stats {
  width: min(420px, 36vw);
  gap: 8px;
}

.hero-stat {
  min-height: 58px;
  padding: 9px 10px;
  border-radius: 10px;
}

.hero-stat-value {
  font-size: clamp(1.05rem, 1.55vw, 1.5rem);
  letter-spacing: 0;
}

.hero-stat-label {
  font-size: 0.5rem;
  line-height: 1.15;
}

.content-calendar {
  margin-top: 12px;
  border-radius: 14px;
}

.calendar-header {
  grid-template-columns: minmax(190px, auto) minmax(0, 1fr);
  gap: 12px;
  padding: 12px 14px;
}

.calendar-header h2 {
  font-size: 1rem;
}

.calendar-kicker {
  margin-bottom: 3px;
  font-size: 0.6rem;
}

.calendar-toggle {
  min-height: 32px;
  padding: 0 13px;
  font-size: 0.66rem;
  box-shadow: none;
}

.content-calendar table {
  min-width: 1200px;
  font-size: clamp(0.72rem, 0.78vw, 0.92rem);
}

.content-calendar th,
.content-calendar td {
  padding: 8px 7px;
  line-height: 1.2;
}

.content-calendar th {
  font-size: clamp(0.5rem, 0.54vw, 0.64rem);
  letter-spacing: 0.03em;
}

.calendar-sort-heading {
  padding-inline: 4px;
}

.calendar-sort-heading::after {
  content: none !important;
}

.calendar-sort-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 100%;
  min-height: 24px;
  border: 0;
  border-radius: 999px;
  padding: 3px 6px;
  color: inherit;
  background: transparent;
  font: inherit;
  font-size: clamp(0.58rem, 0.64vw, 0.76rem);
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
  cursor: pointer;
}

.calendar-sort-button:hover,
.calendar-sort-button:focus-visible {
  color: var(--lavender-deep);
  background: rgba(0, 138, 120, 0.1);
  outline: none;
}

.calendar-sort-arrow {
  display: inline-grid;
  place-items: center;
  min-width: 14px;
  color: var(--lavender-deep);
  font-size: 0.72em;
  line-height: 1;
}

.content-calendar:not([data-view="best"]) th:nth-child(1),
.content-calendar:not([data-view="best"]) td:nth-child(1) {
  width: 4.2%;
}

.content-calendar:not([data-view="best"]) th:nth-child(2),
.content-calendar:not([data-view="best"]) td:nth-child(2) {
  width: 5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(3),
.content-calendar:not([data-view="best"]) td:nth-child(3) {
  width: 5.6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(4),
.content-calendar:not([data-view="best"]) td:nth-child(4) {
  width: 25.5%;
}

.content-calendar:not([data-view="best"]) th:nth-child(5),
.content-calendar:not([data-view="best"]) td:nth-child(5) {
  width: 7.2%;
}

.content-calendar:not([data-view="best"]) th:nth-child(6),
.content-calendar:not([data-view="best"]) td:nth-child(6) {
  width: 8%;
}

.content-calendar:not([data-view="best"]) th:nth-child(7),
.content-calendar:not([data-view="best"]) td:nth-child(7) {
  width: 8.4%;
}

.content-calendar:not([data-view="best"]) th:nth-child(8),
.content-calendar:not([data-view="best"]) td:nth-child(8) {
  width: 7.4%;
}

.content-calendar:not([data-view="best"]) th:nth-child(9),
.content-calendar:not([data-view="best"]) td:nth-child(9) {
  width: 8.6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(10),
.content-calendar:not([data-view="best"]) td:nth-child(10) {
  width: 11.6%;
}

.content-calendar:not([data-view="best"]) th:nth-child(11),
.content-calendar:not([data-view="best"]) td:nth-child(11) {
  width: 8.5%;
}

.content-calendar td:nth-child(4) {
  font-size: clamp(0.8rem, 0.86vw, 1rem);
}

.status-pill,
.calendar-details-button,
.calendar-start-button,
.calendar-asset-button,
.calendar-video-link,
.calendar-song-link {
  min-height: 26px;
  padding: 0 10px;
  border-width: 1.5px;
  font-size: clamp(0.55rem, 0.6vw, 0.68rem);
  line-height: 1.08;
  white-space: nowrap;
}

.calendar-details-button,
.calendar-start-button,
.calendar-asset-button,
.calendar-video-link {
  min-width: 0;
}

.creator-log-button,
.calendar-supergen-button {
  margin-top: 5px;
  margin-left: 0;
}

.calendar-start-button {
  min-height: 28px;
  padding-inline: 11px;
}

.calendar-song-control,
.calendar-song-play-button,
.calendar-song-progress-wrap {
  width: min(126px, 100%);
  min-width: min(102px, 100%);
}

.calendar-song-play-button {
  height: 28px;
  min-width: 102px;
  padding: 0 8px;
  font-size: 0.62rem;
}

.calendar-song-progress-wrap {
  min-height: 14px;
}

.calendar-song-progress {
  height: 11px;
}

.calendar-song-progress::-webkit-slider-runnable-track {
  height: 9px;
}

.calendar-song-progress::-webkit-slider-thumb {
  width: 17px;
  height: 17px;
  margin-top: -4px;
}

.calendar-song-progress::-moz-range-track {
  height: 9px;
}

.calendar-song-progress::-moz-range-thumb {
  width: 17px;
  height: 17px;
}

@media (min-width: 1100px) {
  .dashboard[data-role="creator"] .hero-top {
    grid-template-columns: minmax(360px, 1fr) auto;
  }
}

@media (max-width: 1099px) {
  .hero-top {
    grid-template-columns: 1fr;
  }

  .management-overview:not(.is-management),
  .hero-stats {
    width: 100%;
  }
}

/* Final mobile dashboard corrections. Keep these at the end so desktop density rules
   cannot override the phone card layout. */
@media (max-width: 640px) {
  html,
  body {
    overflow-x: hidden;
  }

  .app-shell {
    padding: max(10px, env(safe-area-inset-top)) 8px max(116px, calc(env(safe-area-inset-bottom) + 96px));
  }

  .dashboard {
    width: 100%;
    max-width: 100%;
    padding-bottom: 104px;
  }

  .dashboard-grid {
    gap: 12px;
  }

  .dashboard-nav {
    width: 100%;
    max-width: 100%;
    margin: 0 0 12px;
    padding: 12px;
    border-radius: 18px;
  }

  .dashboard-nav-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .dashboard-link-button,
  .dashboard-logs-menu > summary {
    min-height: 38px;
    border-radius: 14px;
    font-size: 0.7rem;
    line-height: 1.12;
    word-break: normal;
    overflow-wrap: normal;
    hyphens: none;
  }

  .creator-trending-videos,
  .hero-panel,
  .content-calendar {
    width: 100%;
    max-width: 100%;
    border-radius: 18px;
  }

  .hero-panel {
    padding: 16px;
  }

  .hero-action-row {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .cta-button,
  .new-project-button {
    width: 100%;
    min-height: 42px;
    white-space: nowrap;
  }

  .dashboard-balance-card {
    width: min(100%, 320px);
  }

  .hero-stats {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-stat {
    min-width: 0;
    min-height: 72px;
  }

  .hero-stat-label {
    overflow-wrap: normal;
    word-break: normal;
  }

  .content-calendar {
    overflow: hidden;
    margin-top: 14px;
    background: rgba(255, 255, 255, 0.84);
  }

  .calendar-header {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px 14px;
  }

  .calendar-header h2 {
    max-width: 100%;
    font-size: clamp(1.18rem, 6vw, 1.55rem);
    line-height: 1.12;
  }

  .calendar-view-controls {
    display: none !important;
  }

  .calendar-view-select-wrap {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    width: 100%;
    gap: 10px;
    font-size: 0.88rem;
  }

  .calendar-view-select-wrap select,
  .creator-filter select {
    width: 100%;
    max-width: none;
    min-height: 42px;
    border-radius: 16px;
    font-size: 1rem;
    font-weight: 850;
  }

  .calendar-table-wrap {
    margin: 0;
    padding: 12px;
    overflow: visible;
    max-width: 100%;
  }

  .content-calendar table,
  .content-calendar thead,
  .content-calendar tbody,
  .content-calendar tr,
  .content-calendar th,
  .content-calendar td {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .content-calendar table {
    border-collapse: separate;
    border-spacing: 0;
    table-layout: auto;
    font-size: 1rem;
  }

  .content-calendar thead {
    display: none !important;
  }

  .content-calendar tbody {
    display: grid !important;
    gap: 14px;
  }

  .content-calendar tbody tr {
    display: grid !important;
    overflow: hidden;
    border: 1px solid rgba(5, 5, 5, 0.1);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 12px 26px rgba(9, 6, 20, 0.08);
  }

  .content-calendar tr.is-delayed td,
  .content-calendar tr.is-unassigned td {
    background: transparent;
  }

  .content-calendar td {
    display: grid !important;
    grid-template-columns: minmax(104px, 0.38fr) minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    min-height: 44px;
    padding: 11px 14px;
    border-bottom: 1px solid rgba(5, 5, 5, 0.08);
    color: #32293c;
    font-size: 0.92rem;
    line-height: 1.25;
    white-space: normal !important;
    word-break: normal;
    overflow-wrap: anywhere;
    text-overflow: clip;
    overflow: visible;
  }

  .content-calendar td::before {
    align-self: center;
    color: rgba(50, 41, 60, 0.62);
    font-size: 0.7rem;
    font-weight: 900;
    letter-spacing: 0.055em;
    line-height: 1.15;
    text-transform: uppercase;
  }

  .content-calendar td > * {
    min-width: 0;
    max-width: 100%;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(4),
  .content-calendar[data-view="best"] td:nth-child(1) {
    color: #a92d2d;
    font-size: clamp(1rem, 4.8vw, 1.22rem);
    font-weight: 900;
    line-height: 1.18;
    overflow-wrap: anywhere;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(5),
  .content-calendar:not([data-view="best"]) td:nth-child(7),
  .content-calendar:not([data-view="best"]) td:nth-child(8),
  .content-calendar:not([data-view="best"]) td:nth-child(9),
  .content-calendar:not([data-view="best"]) td:nth-child(10),
  .content-calendar:not([data-view="best"]) td:nth-child(12),
  .content-calendar:not([data-view="best"]) td:nth-child(13) {
    display: none !important;
  }

  .status-pill {
    justify-self: start;
    min-height: 30px;
    max-width: 100%;
    padding: 6px 12px;
    font-size: 0.78rem;
    line-height: 1.12;
    white-space: normal;
  }

  .calendar-details-button,
  .calendar-start-button,
  .calendar-asset-button,
  .calendar-video-link,
  .calendar-song-link {
    min-height: 36px;
    max-width: 100%;
    border-radius: 999px;
    font-size: 0.78rem;
    line-height: 1.12;
    white-space: normal;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(11) {
    grid-template-columns: 1fr;
    padding-top: 14px;
  }

  .content-calendar:not([data-view="best"]) td:nth-child(11)::before {
    content: "Next action";
  }

  .calendar-action-cell .calendar-start-button,
  .calendar-action-cell .calendar-details-button:not(.calendar-supergen-button) {
    width: 100%;
    justify-self: stretch;
  }

  .calendar-start-button {
    min-height: 46px;
    padding-inline: 16px;
    color: #fff;
    background: #f47c2f;
    border-color: #f47c2f;
    font-size: 0.86rem;
  }
}

@media (max-width: 390px) {
  .dashboard-nav-actions {
    grid-template-columns: 1fr;
  }

  .content-calendar td {
    grid-template-columns: minmax(92px, 0.38fr) minmax(0, 1fr);
    padding: 10px 12px;
  }
}

@media (max-width: 640px) {
  .dashboard-brand-actions {
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
  }

  .dashboard-brand-actions .brand-mark {
    grid-column: 1 / -1;
    justify-self: center;
    width: min(260px, 76vw);
    height: 54px;
    margin-inline: auto;
    background-position: center;
  }

  .global-logout-button,
  #logoutButton {
    justify-self: start;
    width: auto;
    min-width: 92px;
    min-height: 34px;
    padding-inline: 14px;
    font-size: 0.66rem;
  }

  .creator-wallet-chip {
    justify-self: end;
    width: auto;
    min-width: 0;
  }

  .creator-wallet-history-link {
    justify-self: end;
  }
}

/* Final mobile dashboard header and monitor fixes. */
@media (max-width: 640px) {
  .dashboard-brand-actions {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 8px;
  }

  .dashboard-brand-actions .brand-mark {
    grid-column: 1 / -1;
    justify-self: center;
    width: min(260px, 76vw);
    height: 54px;
    margin-inline: auto;
    background-position: center;
  }

  .global-logout-button,
  #logoutButton {
    justify-self: start;
    width: 76px;
    min-width: 76px;
    max-width: 76px;
    min-height: 30px;
    padding-inline: 8px;
    font-size: 0.6rem;
    white-space: nowrap;
  }

  .dashboard-nav-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-link-button,
  .dashboard-logs-menu > summary {
    min-height: 36px;
    border-radius: 16px;
    padding-inline: 8px;
    font-size: clamp(0.52rem, 2.4vw, 0.64rem);
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .content-calendar .calendar-view-controls,
  #calendarViewControls {
    display: none !important;
  }

  .creator-trending-videos {
    padding: 18px 14px 16px;
  }

  .creator-trending-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 10px;
    padding-right: 84px;
  }

  .creator-trending-header h2 {
    max-width: 100%;
    font-size: clamp(1.32rem, 7vw, 2rem);
    line-height: 1.08;
  }

  .creator-trending-controls {
    justify-self: end;
    width: auto;
    gap: 6px;
  }

  .creator-trending-history-link {
    top: 18px;
    right: 14px;
    min-height: 30px;
    padding: 0 10px;
    border-width: 2px;
    font-size: 0.58rem;
    font-weight: 950;
    letter-spacing: 0;
  }

  .creator-trending-arrow {
    width: 38px;
    height: 38px;
  }
}

@media (max-width: 420px) {
  .dashboard-brand-actions {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .global-logout-button,
  #logoutButton {
    width: 68px;
    min-width: 68px;
    max-width: 68px;
    font-size: 0.56rem;
  }

  .dashboard-link-button,
  .dashboard-logs-menu > summary {
    font-size: clamp(0.48rem, 2.75vw, 0.58rem);
  }

  .creator-trending-header {
    padding-right: 74px;
  }

  .creator-trending-history-link {
    min-height: 28px;
    padding-inline: 9px;
    font-size: 0.54rem;
  }
}

@media (min-width: 900px) {
  .dashboard[data-role="creator"] .hero-top {
    grid-template-columns: minmax(300px, 1fr) auto auto;
    align-items: start;
    column-gap: 18px;
    row-gap: 8px;
    padding-bottom: 8px;
  }

  .dashboard[data-role="creator"] .hero-identity {
    display: contents;
  }

  .dashboard[data-role="creator"] #dashboardRole,
  .dashboard[data-role="creator"] #dashboardGreeting,
  .dashboard[data-role="creator"] #dashboardCopy,
  .dashboard[data-role="creator"] .dashboard-balance-card {
    grid-column: 1;
  }

  .dashboard[data-role="creator"] #dashboardRole {
    grid-row: 1;
  }

  .dashboard[data-role="creator"] #dashboardGreeting {
    grid-row: 2;
    align-self: start;
    margin-bottom: 0;
  }

  .dashboard[data-role="creator"] #dashboardCopy {
    grid-row: 3;
    margin: 0 0 2px;
    line-height: 1.35;
  }

  .dashboard[data-role="creator"] .dashboard-balance-card {
    grid-row: 4;
    margin-top: 8px;
  }

  .dashboard[data-role="creator"] .hero-action-row {
    grid-column: 2;
    grid-row: 2;
    align-self: start;
    justify-self: end;
    display: flex;
    gap: 13px;
    width: auto;
    margin-top: 0;
  }

  .dashboard[data-role="creator"] .management-overview {
    grid-column: 3;
    grid-row: 2;
    align-self: start;
  }

  .dashboard[data-role="creator"] .hero-top + .content-calendar {
    margin-top: 0;
  }

  .dashboard[data-role="creator"] #dashboardAction,
  .dashboard[data-role="creator"] #newProjectButton {
    min-width: 132px;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    font-size: 0.88rem;
    line-height: 1;
    white-space: nowrap;
  }
}

/* Final desktop dashboard table polish. */
@media (min-width: 641px) {
  .dashboard[data-role="creator"] .content-calendar table {
    min-width: 1280px;
    border-spacing: 0;
  }

  .dashboard[data-role="creator"] .content-calendar th,
  .dashboard[data-role="creator"] .content-calendar td {
    padding: 9px 8px;
  }

  .dashboard[data-role="creator"] .content-calendar th {
    color: var(--ink);
    font-size: clamp(0.67rem, 0.71vw, 0.83rem);
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(1),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(1) {
    width: 5%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(2),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(2) {
    width: 5.8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(3),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(3) {
    width: 5.8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(4),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(4) {
    width: 22.2%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(5),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(5) {
    width: 8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(6),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(6) {
    width: 8.8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(7),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(7) {
    width: 10.2%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(8),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(8) {
    width: 7.8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(9),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(9) {
    width: 8.8%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(10),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(10) {
    width: 10.5%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(11),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(11) {
    width: 7.1%;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(1),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(3),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(4) {
    color: var(--ink);
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(4) {
    text-transform: uppercase;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(5),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(5),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(6),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(6),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(7),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(7),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(8),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(8),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(9),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(9),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(10),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(10),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) th:nth-child(11),
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(11) {
    text-align: center;
  }

  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(5) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(6) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(7) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(8) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(9) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(10) > *,
  .dashboard[data-role="creator"] .content-calendar:not([data-view="best"]) td:nth-child(11) > * {
    margin-inline: auto;
  }

  .dashboard[data-role="creator"] .calendar-song-control {
    width: min(116px, 100%);
    min-width: min(116px, 100%);
    gap: 6px;
    place-items: center;
  }

  .dashboard[data-role="creator"] .calendar-song-play-button {
    width: min(116px, 100%);
    min-width: min(96px, 100%);
    height: 25px;
    border: 1.5px solid rgba(5, 5, 5, 0.72);
    padding: 0 10px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: inset 0 -1px 0 rgba(5, 5, 5, 0.08);
    font-size: 0.58rem;
    letter-spacing: 0.02em;
  }

  .dashboard[data-role="creator"] .calendar-song-control.is-playing .calendar-song-play-button {
    border-color: rgba(0, 138, 120, 0.8);
    color: var(--lavender-deep);
    background: #effffb;
  }

  .dashboard[data-role="creator"] .calendar-song-progress-wrap {
    position: relative;
    width: min(104px, 100%);
    min-width: min(96px, 100%);
    min-height: 12px;
  }

  .dashboard[data-role="creator"] .calendar-song-progress-wrap::before {
    content: "";
    position: absolute;
    left: 5px;
    right: 5px;
    top: 50%;
    height: 1px;
    background: rgba(5, 5, 5, 0.2);
    transform: translateY(-50%);
    pointer-events: none;
  }

  .dashboard[data-role="creator"] .calendar-song-progress {
    height: 8px;
    border: 0;
    background:
      linear-gradient(90deg, var(--lavender-deep) var(--song-progress), rgba(5, 5, 5, 0.12) var(--song-progress));
    box-shadow: inset 0 0 0 1px rgba(5, 5, 5, 0.12);
  }

  .dashboard[data-role="creator"] .calendar-song-progress::-webkit-slider-runnable-track {
    height: 8px;
  }

  .dashboard[data-role="creator"] .calendar-song-progress::-webkit-slider-thumb {
    width: 8px;
    height: 8px;
    margin-top: 0;
    border: 1.5px solid var(--white);
    background: var(--lavender-deep);
    box-shadow: 0 0 0 1px rgba(0, 138, 120, 0.42);
  }

  .dashboard[data-role="creator"] .calendar-song-progress::-moz-range-track {
    height: 8px;
  }

  .dashboard[data-role="creator"] .calendar-song-progress::-moz-range-thumb {
    width: 8px;
    height: 8px;
    border: 1.5px solid var(--white);
    background: var(--lavender-deep);
    box-shadow: 0 0 0 1px rgba(0, 138, 120, 0.42);
  }
}

/* mobile-new-project-fit-20260620: prevent New Project chooser copy from spilling across cards. */
@media (max-width: 640px) {
  #newProjectPopup {
    align-items: flex-start;
    place-items: start center;
    padding: max(18px, env(safe-area-inset-top)) 16px max(18px, env(safe-area-inset-bottom));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  #newProjectPopup .project-modal {
    width: min(100%, 390px);
    max-height: none;
    min-height: auto;
    margin: 14px auto;
    padding: 28px 22px 24px;
    overflow: visible;
    border-radius: 24px;
  }

  #newProjectPopup .brand-mark {
    margin: 0 54px 12px 0;
    max-width: calc(100% - 64px);
    overflow-wrap: anywhere;
    line-height: 1;
  }

  #newProjectPopup .close-button {
    top: 22px;
    right: 22px;
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    line-height: 1;
  }

  #newProjectPopup h2 {
    margin: 0 0 14px;
    font-size: 2.1rem;
    line-height: 1.05;
  }

  #newProjectPopup .project-notes-copy {
    margin: 0 0 18px;
    max-height: none;
    overflow: visible;
    padding-right: 0;
    font-size: 1rem;
    line-height: 1.45;
    white-space: normal;
  }

  #newProjectPopup .scheduled-project-list {
    gap: 12px;
    margin-top: 0;
    max-height: none;
    overflow: visible;
  }

  #newProjectPopup .scheduled-project-button {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-height: auto;
    height: auto;
    padding: 16px 18px;
    border-radius: 18px;
    line-height: 1.15;
    white-space: normal;
    overflow: visible;
  }

  #newProjectPopup .scheduled-project-button span {
    margin-top: 10px;
    font-size: 0.86rem;
    line-height: 1.35;
    white-space: normal;
    overflow: visible;
  }

  #newProjectPopup .scheduled-project-button.is-coming-soon small {
    margin: 10px 0 0;
  }
}

@media (max-width: 380px) {
  #newProjectPopup .project-modal {
    padding: 24px 18px 22px;
  }

  #newProjectPopup h2 {
    font-size: 1.85rem;
  }

  #newProjectPopup .scheduled-project-button {
    padding: 14px 16px;
  }
}

/* mobile-new-project-hide-tools-20260620: keep floating helper button off the modal. */
@media (max-width: 640px) {
  body:has(#newProjectPopup:not([hidden])) #dvFloatingToolsToggle,
  body:has(#newProjectPopup:not([hidden])) .dv-floating-tools-toggle {
    display: none !important;
  }
}
