:root {
  --bg: #f8f4ed;
  --surface: #ffffff;
  --surface-2: #f1ebe1;
  --ink: #171410;
  --muted: #7d756a;
  --line: #e4dacb;
  --gold: #b88746;
  --gold-2: #e8d6b8;
  --ai: #5b35d5;
  --ai-2: #7a5cf4;
  --green: #6f985d;
  --green-soft: #edf6e8;
  --danger: #b94a48;
  --shadow: 0 24px 70px rgba(38, 31, 22, 0.12);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  margin: 0;
  background:
    radial-gradient(circle at 12% 8%, rgba(184, 135, 70, 0.16), transparent 28rem),
    radial-gradient(circle at 90% 0%, rgba(91, 53, 213, 0.11), transparent 30rem),
    linear-gradient(135deg, #fbf8f2 0%, #f4eee5 48%, #fbf8f2 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.is-hidden {
  display: none !important;
}

.login-view {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
}

.login-shell {
  width: min(1180px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 56px;
  align-items: center;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  position: relative;
  width: 34px;
  height: 38px;
  border-left: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
}

.brand-mark::before,
.brand-mark::after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 11px;
  border: 2px solid var(--gold);
  border-bottom: 0;
}

.brand-mark::before {
  left: 7px;
  height: 29px;
}

.brand-mark::after {
  left: 20px;
  height: 22px;
}

.brand-name {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 34px;
  font-weight: 700;
  line-height: 0.92;
}

.brand-name span {
  color: var(--gold);
}

.brand-kicker {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 1.4px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin: 42px 0 22px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(58px, 7vw, 98px);
  line-height: 0.94;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 4px;
  font-size: 30px;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 26px;
  letter-spacing: 0;
}

.lead {
  max-width: 620px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
}

.login-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
}

.login-proof span,
.hero-badge,
.segmented,
.profile-pill,
.sidebar-status,
.workflow-strip article,
.metric-card,
.price-card,
.empty-state,
.export-summary,
.copy-card,
.upload-card,
.compare-card,
.voice-card,
.portfolio-row {
  border: 1px solid rgba(228, 218, 203, 0.92);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 44px rgba(38, 31, 22, 0.07);
  backdrop-filter: blur(20px);
}

.login-proof span {
  border-radius: 999px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 850;
}

.login-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.login-card h2,
.login-card p {
  padding: 0 4px;
}

.login-card p {
  color: var(--muted);
}

.login-hero {
  position: relative;
  overflow: hidden;
  height: 245px;
  margin-bottom: 24px;
  border-radius: var(--radius);
  background: var(--surface-2);
}

.login-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-badge {
  position: absolute;
  right: 14px;
  bottom: 14px;
  border-color: rgba(111, 152, 93, 0.34);
  border-radius: 999px;
  background: rgba(237, 246, 232, 0.92);
  color: #315828;
  padding: 9px 13px;
  font-size: 13px;
  font-weight: 900;
}

label {
  display: grid;
  gap: 8px;
  margin: 14px 0;
  color: #5f574e;
  font-size: 12px;
  font-weight: 850;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fffdfa;
  color: var(--ink);
  outline: 0;
  padding: 14px 14px;
  font-size: 15px;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

textarea {
  min-height: 150px;
  resize: vertical;
  line-height: 1.45;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(91, 53, 213, 0.52);
  box-shadow: 0 0 0 4px rgba(91, 53, 213, 0.11);
  background: #fff;
}

.primary-action,
.secondary-action,
.ghost-button,
.text-button {
  border: 0;
  cursor: pointer;
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease, background 160ms ease;
}

.primary-action {
  min-height: 48px;
  border-radius: var(--radius);
  padding: 0 20px;
  color: #fff;
  background: linear-gradient(135deg, var(--ai), var(--ai-2));
  box-shadow: 0 16px 32px rgba(91, 53, 213, 0.24);
}

.secondary-action,
.ghost-button,
.text-button {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  padding: 0 16px;
}

.text-button {
  border: 0;
  background: transparent;
  color: var(--ai);
}

.primary-action:hover,
.secondary-action:hover,
.ghost-button:hover {
  transform: translateY(-1px);
}

.form-message {
  min-height: 20px;
  margin: 12px 0 0;
  color: var(--danger);
  font-size: 13px;
  font-weight: 780;
}

.form-message.is-good {
  color: #406c33;
}

.app-view {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 28px;
  border-right: 1px solid var(--line);
  background: rgba(255, 252, 247, 0.82);
  backdrop-filter: blur(24px);
  padding: 28px 22px;
}

.sidebar-brand .brand-name {
  font-size: 28px;
}

.side-nav {
  display: grid;
  align-content: start;
  gap: 8px;
}

.nav-item {
  width: 100%;
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: #5f574e;
  cursor: pointer;
  padding: 0 14px;
  text-align: left;
  font-weight: 850;
}

.nav-item:hover,
.nav-item.is-active {
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
  box-shadow: 0 12px 28px rgba(38, 31, 22, 0.07);
}

.nav-item.is-active {
  color: var(--ai);
}

.sidebar-status {
  display: grid;
  gap: 12px;
  border-radius: var(--radius);
  padding: 14px;
}

.sidebar-status div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.sidebar-status span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 820;
}

.sidebar-status strong {
  color: var(--ink);
  font-size: 12px;
}

.workspace {
  min-width: 0;
  padding: 30px clamp(24px, 4vw, 56px) 48px;
}

.topbar,
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.profile-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: var(--radius);
  padding: 8px;
}

.profile-pill img {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
}

.profile-pill span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.panel-view {
  display: none;
}

.panel-view.is-active {
  display: block;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px 250px;
  gap: 18px;
}

.hero-panel {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  border-radius: var(--radius);
  background: #201c18;
  box-shadow: var(--shadow);
}

.hero-panel img {
  width: 100%;
  height: 100%;
  min-height: 360px;
  object-fit: cover;
}

.hero-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(16, 14, 12, 0.76), rgba(16, 14, 12, 0.1) 68%);
}

.hero-overlay {
  position: absolute;
  inset: auto auto 28px 28px;
  z-index: 1;
  max-width: 420px;
  color: #fff;
}

.hero-overlay h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 46px;
  line-height: 0.98;
}

.hero-overlay p:not(.eyebrow) {
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.5;
}

.metric-card {
  display: grid;
  align-content: end;
  min-height: 360px;
  border-radius: var(--radius);
  padding: 22px;
}

.metric-card span,
.price-card span,
.copy-card span,
.image-frame span,
.social-preview span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.metric-card strong {
  display: block;
  margin: 10px 0;
  font-size: 44px;
  line-height: 1;
}

.metric-card p,
.workflow-strip p,
.empty-state p,
.price-card p,
.export-summary li,
.drop-zone p {
  color: var(--muted);
  line-height: 1.45;
}

.workflow-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin: 22px 0;
}

.workflow-strip article {
  border-radius: var(--radius);
  padding: 18px;
}

.workflow-strip span {
  color: var(--ai);
  font-weight: 950;
}

.workflow-strip strong {
  display: block;
  margin: 8px 0 4px;
  font-size: 17px;
}

.portfolio-section,
.inline-voice-panel,
.form-grid,
.retouch-grid,
.voice-grid,
.social-grid,
.export-grid,
.pricing-grid {
  margin-top: 22px;
}

.inline-voice-panel {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 18px;
  border: 1px solid rgba(228, 218, 203, 0.92);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 44px rgba(38, 31, 22, 0.07);
  backdrop-filter: blur(20px);
  padding: 18px;
}

.inline-voice-panel > div:first-child span,
.scene-card span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.inline-voice-panel > div:first-child strong {
  display: block;
  margin-top: 6px;
  font-size: 22px;
}

.inline-voice-panel > div:first-child p {
  color: var(--muted);
  line-height: 1.45;
}

.inline-voice-panel label {
  margin: 0;
}

.inline-voice-panel textarea {
  min-height: 112px;
}

.voice-upload-row {
  grid-column: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) repeat(3, auto);
  gap: 10px;
  align-items: end;
}

.audio-upload input {
  padding: 11px;
}

.empty-state {
  border-radius: var(--radius);
  padding: 22px;
}

.portfolio-list {
  display: grid;
  gap: 10px;
}

.portfolio-row {
  display: grid;
  grid-template-columns: 132px 1fr auto;
  gap: 16px;
  align-items: center;
  border-radius: var(--radius);
  padding: 10px;
}

.portfolio-row img {
  width: 132px;
  height: 82px;
  border-radius: 6px;
  object-fit: cover;
}

.portfolio-row p {
  margin-bottom: 0;
  color: var(--muted);
}

.portfolio-row .status-pill {
  border-radius: 999px;
  background: var(--green-soft);
  color: #37632f;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 900;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 18px;
  max-width: 980px;
}

.full {
  grid-column: 1 / -1;
}

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

.segmented {
  display: inline-flex;
  gap: 4px;
  border-radius: var(--radius);
  padding: 4px;
}

.segmented button {
  min-height: 38px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 0 14px;
  font-weight: 900;
}

.segmented button.is-selected {
  background: var(--ai);
  color: #fff;
}

.retouch-grid {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 20px;
}

.upload-card,
.voice-card,
.copy-card,
.export-summary {
  border-radius: var(--radius);
  padding: 18px;
}

.drop-zone {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 250px;
  border: 1px dashed rgba(184, 135, 70, 0.55);
  border-radius: var(--radius);
  background: rgba(248, 244, 237, 0.74);
  padding: 24px;
  text-align: center;
}

.drop-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.drop-zone strong {
  font-size: 22px;
}

.retouch-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.is-disabled {
  pointer-events: none;
  opacity: 0.48;
}

.compare-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  border-radius: var(--radius);
  padding: 12px;
}

.image-frame {
  position: relative;
  overflow: hidden;
  min-height: 430px;
  border-radius: var(--radius);
  background: #201c18;
}

.image-frame img {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
}

.image-frame span {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 1;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  padding: 8px 12px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
}

.voice-grid,
.video-grid,
.social-grid,
.export-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.8fr);
  gap: 18px;
}

.video-grid {
  grid-template-columns: minmax(0, 1.1fr) minmax(390px, 0.9fr);
}

.video-stage,
.scene-card {
  border: 1px solid rgba(228, 218, 203, 0.92);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 44px rgba(38, 31, 22, 0.07);
  backdrop-filter: blur(20px);
  padding: 16px;
}

.video-preview {
  position: relative;
  overflow: hidden;
  min-height: 520px;
  border-radius: var(--radius);
  background: #201c18;
}

.video-preview img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

.video-preview::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(16, 14, 12, 0.78));
}

.video-preview div {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 1;
  color: #fff;
}

.video-preview span,
.scene-card span {
  color: var(--gold-2);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.video-preview strong {
  display: block;
  max-width: 560px;
  margin-top: 8px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 36px;
  line-height: 1;
}

.video-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.credit-preview {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 16px;
  align-items: center;
  margin-top: 12px;
  border: 1px solid rgba(91, 53, 213, 0.22);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #f5f0ff, #fffdfa);
  padding: 14px;
}

.credit-preview strong {
  font-size: 15px;
}

.credit-preview span {
  color: var(--ai);
  font-size: 24px;
  font-weight: 950;
}

.credit-preview p {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.compact {
  margin-bottom: 12px;
}

.compact strong {
  display: block;
  margin-top: 4px;
  font-size: 18px;
}

.scene-list {
  display: grid;
  gap: 10px;
}

.scene-item {
  display: grid;
  grid-template-columns: 92px 1fr;
  align-items: center;
  gap: 12px;
  min-height: 74px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fffdfa;
  cursor: pointer;
  padding: 8px;
  text-align: left;
}

.scene-item img {
  width: 92px;
  height: 58px;
  border-radius: 6px;
  object-fit: cover;
}

.scene-item span {
  color: var(--ink);
  font-size: 15px;
  letter-spacing: 0;
  text-transform: none;
}

.scene-item.is-selected {
  border-color: rgba(91, 53, 213, 0.5);
  background: #f3efff;
  box-shadow: 0 12px 26px rgba(91, 53, 213, 0.12);
}

.video-brief-card,
.video-history-card {
  grid-column: 1 / -1;
}

.video-history-card {
  border: 1px solid rgba(228, 218, 203, 0.92);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 44px rgba(38, 31, 22, 0.07);
  backdrop-filter: blur(20px);
  padding: 18px;
}

.compact-empty {
  box-shadow: none;
}

.video-history-list {
  display: grid;
  gap: 12px;
}

.video-job-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fffdfa;
  padding: 10px;
}

.video-job-media {
  overflow: hidden;
  width: 220px;
  height: 126px;
  border-radius: 6px;
  background: #171410;
}

.video-job-media img,
.video-job-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-job-main {
  min-width: 0;
}

.video-job-main strong {
  display: block;
  margin-bottom: 6px;
  font-size: 17px;
}

.video-job-main p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.progress-track {
  overflow: hidden;
  height: 7px;
  margin-top: 10px;
  border-radius: 999px;
  background: #eee7dc;
}

.progress-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--ai), var(--gold));
}

.video-job-actions {
  display: grid;
  gap: 8px;
  max-width: 170px;
}

.video-job-actions button,
.video-job-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  padding: 0 12px;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.video-job-actions .primary-small {
  border-color: transparent;
  background: var(--ink);
  color: #fff;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 26px;
  border-radius: 999px;
  background: #f2eadf;
  color: var(--muted);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
}

.status-chip.completed {
  background: var(--green-soft);
  color: #37632f;
}

.status-chip.failed {
  background: #f9e5e4;
  color: var(--danger);
}

.status-chip.processing,
.status-chip.generating_scenes,
.status-chip.pending {
  background: #f3efff;
  color: var(--ai);
}

.video-job-status {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fffdfa;
  padding: 14px;
}

.video-job-status strong {
  font-size: 15px;
}

.video-job-status p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.45;
}

.video-result {
  margin-top: 14px;
  display: grid;
  gap: 14px;
}

.video-result-item {
  display: grid;
  gap: 10px;
}

.video-result video,
.video-result img {
  width: 100%;
  max-height: 520px;
  border-radius: var(--radius);
  background: #111;
  object-fit: contain;
}

.video-result a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin-top: 10px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  padding: 0 14px;
  font-weight: 900;
}

.copy-card textarea {
  min-height: 260px;
  margin-top: 12px;
}

.social-preview {
  position: relative;
  overflow: hidden;
  min-height: 520px;
  border-radius: var(--radius);
  background: #201c18;
  box-shadow: var(--shadow);
}

.social-preview img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

.social-preview div {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  padding: 16px;
}

.social-preview strong {
  display: block;
  margin-top: 6px;
  font-size: 22px;
}

.export-summary ul {
  margin: 18px 0 0;
  padding-left: 18px;
}

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

.price-card {
  min-height: 220px;
  border-radius: var(--radius);
  padding: 22px;
}

.price-card strong {
  display: block;
  margin: 18px 0 10px;
  font-size: 30px;
}

.price-card.is-featured {
  border-color: rgba(91, 53, 213, 0.42);
  background: linear-gradient(180deg, #f3efff, #ffffff);
  box-shadow: 0 24px 60px rgba(91, 53, 213, 0.16);
}

@media (max-width: 1180px) {
  .app-view {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .dashboard-grid {
    grid-template-columns: 1fr 1fr;
  }

  .hero-panel {
    grid-column: 1 / -1;
  }

  .metric-card {
    min-height: 190px;
  }

  .retouch-grid,
  .voice-grid,
  .video-grid,
  .social-grid,
  .export-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .login-shell,
  .app-view {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .side-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topbar,
  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .profile-pill {
    width: 100%;
    justify-content: space-between;
  }

  .workflow-strip,
  .compare-card,
  .pricing-grid,
  .form-grid,
  .inline-voice-panel,
  .video-grid,
  .video-controls {
    grid-template-columns: 1fr;
  }

  .full {
    grid-column: auto;
  }

  .voice-upload-row {
    grid-column: auto;
    grid-template-columns: 1fr;
  }
}

/* Dark production studio skin */
:root {
  --bg: #080a0f;
  --surface: #111723;
  --surface-2: #151d2b;
  --ink: #f5f1e8;
  --muted: #a69f93;
  --line: rgba(229, 215, 191, 0.13);
  --gold: #c29a5b;
  --gold-2: #efd3a0;
  --ai: #8b6cff;
  --ai-2: #c290ff;
  --green: #87b973;
  --green-soft: rgba(135, 185, 115, 0.12);
  --danger: #ff827c;
  --shadow: 0 26px 80px rgba(0, 0, 0, 0.42);
}

body {
  background:
    radial-gradient(circle at 18% 0%, rgba(194, 154, 91, 0.13), transparent 30rem),
    radial-gradient(circle at 92% 8%, rgba(139, 108, 255, 0.15), transparent 32rem),
    linear-gradient(135deg, #07090e 0%, #0d121c 48%, #080a0f 100%);
  color: var(--ink);
}

.login-proof span,
.hero-badge,
.segmented,
.profile-pill,
.workflow-strip article,
.metric-card,
.price-card,
.empty-state,
.export-summary,
.copy-card,
.upload-card,
.compare-card,
.voice-card,
.portfolio-row,
.inline-voice-panel,
.video-stage,
.scene-card,
.video-history-card,
.video-job-card,
.video-job-status,
.credit-preview {
  border-color: var(--line);
  background: rgba(17, 23, 35, 0.76);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

.login-card,
.sidebar {
  border-color: var(--line);
  background: rgba(10, 14, 22, 0.84);
  box-shadow: var(--shadow);
}

.sidebar {
  background: rgba(8, 11, 18, 0.88);
}

.brand-name,
h1,
h2,
h3,
.profile-pill strong,
.metric-card strong,
.workflow-strip strong,
.portfolio-row strong,
.copy-card strong,
.video-job-main strong {
  color: var(--ink);
}

.lead,
.login-card p,
.metric-card p,
.workflow-strip p,
.empty-state p,
.price-card p,
.export-summary li,
.drop-zone p,
.inline-voice-panel > div:first-child p,
.video-job-main p,
.video-job-status p,
.credit-preview p {
  color: var(--muted);
}

label {
  color: #d8cbb8;
}

input,
textarea,
select {
  border-color: rgba(229, 215, 191, 0.14);
  background: #0d131f;
  color: var(--ink);
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(194, 154, 91, 0.52);
  background: #111927;
  box-shadow: 0 0 0 4px rgba(194, 154, 91, 0.12);
}

.primary-action {
  color: #0b0d12;
  background: linear-gradient(135deg, #f1d08c, #b6813e);
  box-shadow: 0 18px 42px rgba(194, 154, 91, 0.24);
}

.secondary-action,
.ghost-button,
.text-button {
  border-color: var(--line);
  background: rgba(21, 29, 43, 0.82);
  color: var(--ink);
}

.text-button {
  color: var(--gold-2);
}

.nav-item {
  color: #aaa195;
}

.nav-item:hover,
.nav-item.is-active {
  border-color: rgba(194, 154, 91, 0.24);
  background: rgba(21, 29, 43, 0.88);
  color: var(--ink);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.26);
}

.nav-item.is-active {
  color: var(--gold-2);
}

.sidebar-status {
  display: none;
}

.hero-panel,
.video-preview,
.social-preview,
.image-frame,
.video-job-media {
  background: #06080d;
}

.drop-zone {
  border-color: rgba(194, 154, 91, 0.42);
  background: rgba(13, 19, 31, 0.78);
}

.segmented button {
  color: var(--muted);
}

.segmented button.is-selected {
  background: linear-gradient(135deg, #8b6cff, #c290ff);
  color: #07090e;
}

.video-upload-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.video-upload-zone {
  position: relative;
  display: grid;
  gap: 6px;
  min-height: 118px;
  place-items: center;
  border: 1px dashed rgba(194, 154, 91, 0.46);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(194, 154, 91, 0.1), rgba(139, 108, 255, 0.08));
  color: var(--ink);
  margin: 0;
  padding: 18px;
  text-align: center;
}

.video-upload-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.video-upload-zone strong {
  font-size: 20px;
}

.video-upload-zone span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
}

.room-type-panel {
  display: grid;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(13, 19, 31, 0.72);
  padding: 14px;
}

.room-type-panel > span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.room-type-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.room-type-grid button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(21, 29, 43, 0.9);
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
}

.room-type-grid button.is-selected {
  border-color: rgba(194, 154, 91, 0.58);
  background: rgba(194, 154, 91, 0.14);
  color: var(--gold-2);
}

.scene-item {
  border-color: var(--line);
  background: rgba(13, 19, 31, 0.88);
}

.scene-item.is-selected {
  border-color: rgba(194, 154, 91, 0.58);
  background: rgba(194, 154, 91, 0.12);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.scene-item span {
  color: var(--ink);
}

.credit-preview {
  background: linear-gradient(135deg, rgba(194, 154, 91, 0.14), rgba(139, 108, 255, 0.1));
}

.credit-preview span {
  color: var(--gold-2);
}

.video-job-actions button,
.video-job-actions a {
  border-color: var(--line);
  background: rgba(21, 29, 43, 0.9);
  color: var(--ink);
}

.video-job-actions .primary-small {
  background: linear-gradient(135deg, #f1d08c, #b6813e);
  color: #0b0d12;
}

.status-chip {
  background: rgba(229, 215, 191, 0.1);
  color: var(--muted);
}

.status-chip.completed {
  background: rgba(135, 185, 115, 0.14);
  color: #a6df93;
}

.status-chip.failed {
  background: rgba(255, 130, 124, 0.13);
  color: var(--danger);
}

.status-chip.processing,
.status-chip.generating_scenes,
.status-chip.pending {
  background: rgba(139, 108, 255, 0.14);
  color: #c8baff;
}

@media (max-width: 860px) {
  .room-type-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Balanced premium advisor panel */
:root {
  --bg: #070808;
  --surface: #101216;
  --surface-2: #171a20;
  --ink: #f2eee7;
  --muted: #9f988d;
  --line: rgba(218, 208, 190, 0.14);
  --gold: #a99674;
  --gold-2: #d0c4ad;
  --ai: #a99674;
  --ai-2: #7e8978;
  --green: #8ca184;
  --green-soft: rgba(140, 161, 132, 0.14);
  --shadow: 0 20px 58px rgba(0, 0, 0, 0.34);
}

body {
  background: linear-gradient(135deg, #070808 0%, #101218 52%, #08090b 100%);
}

.app-view {
  grid-template-columns: 248px minmax(0, 1fr);
}

.workspace {
  padding: 22px clamp(18px, 3vw, 40px) 36px;
}

.topbar,
.section-head {
  gap: 16px;
  margin-bottom: 16px;
}

h2 {
  font-size: 25px;
}

h3 {
  font-size: 22px;
}

.eyebrow {
  margin-bottom: 6px;
  color: var(--gold-2);
  font-size: 10px;
}

.sidebar {
  gap: 20px;
  padding: 22px 16px;
}

.sidebar-brand .brand-name {
  font-size: 24px;
}

.brand-mark {
  width: 28px;
  height: 32px;
}

.nav-item {
  min-height: 39px;
  padding: 0 12px;
  font-size: 14px;
}

.profile-pill {
  padding: 6px 8px;
}

.profile-pill img {
  width: 38px;
  height: 38px;
}

input,
textarea,
select {
  border-radius: 7px;
  padding: 11px 12px;
  font-size: 14px;
}

textarea {
  min-height: 118px;
}

label {
  gap: 6px;
  margin: 10px 0;
  font-size: 11px;
}

.primary-action,
.secondary-action,
.ghost-button,
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  border-radius: 7px;
  padding: 0 14px;
  font-size: 13px;
}

.primary-action {
  color: #070808;
  background: linear-gradient(135deg, #d0c4ad, #8f9a8a);
  box-shadow: 0 14px 30px rgba(169, 150, 116, 0.18);
}

.primary-action.is-loading::before,
.secondary-action.is-loading::before {
  content: "";
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: estatex-spin 800ms linear infinite;
}

@keyframes estatex-spin {
  to {
    transform: rotate(360deg);
  }
}

.secondary-action,
.ghost-button,
.text-button {
  background: rgba(18, 21, 27, 0.9);
}

.dashboard-grid {
  grid-template-columns: minmax(0, 1fr) 210px 210px;
  gap: 14px;
}

.hero-panel,
.hero-panel img {
  min-height: 285px;
}

.hero-overlay {
  inset: auto auto 22px 22px;
  max-width: 360px;
}

.hero-overlay h3 {
  font-size: 36px;
}

.metric-card {
  min-height: 285px;
  padding: 18px;
}

.metric-card strong {
  font-size: 34px;
}

.workflow-strip {
  gap: 10px;
  margin: 16px 0;
}

.workflow-strip article {
  padding: 14px;
}

.workflow-strip strong {
  font-size: 15px;
}

.inline-voice-panel,
.details-matrix,
.upload-card,
.copy-card,
.export-summary,
.video-stage,
.scene-card,
.video-history-card,
.social-archive-card,
.carousel-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(16, 18, 22, 0.78);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.22);
}

.inline-voice-panel {
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
}

.inline-voice-panel > div:first-child strong {
  font-size: 18px;
}

.inline-voice-panel textarea {
  min-height: 92px;
}

.voice-upload-row {
  gap: 8px;
}

.form-grid {
  max-width: 1060px;
  gap: 2px 14px;
}

.details-matrix {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px 12px;
  margin: 10px 0 4px;
  padding: 14px;
}

.matrix-head {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
}

.matrix-head strong,
.trust-chip,
.detected-facts span {
  border: 1px solid rgba(208, 196, 173, 0.18);
  border-radius: 999px;
  background: rgba(208, 196, 173, 0.08);
  color: var(--gold-2);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 850;
}

.detected-facts {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 2px;
}

.detected-facts span {
  display: inline-flex;
  gap: 6px;
  color: var(--ink);
}

.detected-facts strong {
  color: var(--gold-2);
}

.retouch-grid {
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 16px;
}

.drop-zone {
  min-height: 178px;
  padding: 18px;
}

.drop-zone strong {
  font-size: 18px;
}

.compare-card.slider-card {
  display: grid;
  gap: 14px;
  padding: 14px;
}

.before-after-slider {
  position: relative;
  overflow: hidden;
  min-height: 430px;
  border-radius: var(--radius);
  background: #050607;
}

.before-after-slider img,
.before-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.before-after-slider img {
  object-fit: cover;
}

.before-layer {
  overflow: hidden;
  clip-path: inset(0 50% 0 0);
}

.before-layer img {
  max-width: none;
}

.before-after-slider input[type="range"] {
  position: absolute;
  inset: 0;
  z-index: 4;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: ew-resize;
}

.slider-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  z-index: 3;
  width: 2px;
  background: rgba(242, 238, 231, 0.82);
  transform: translateX(-1px);
}

.slider-handle::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(242, 238, 231, 0.72);
  border-radius: 50%;
  background: rgba(16, 18, 22, 0.78);
  transform: translate(-50%, -50%);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.34);
}

.compare-label {
  position: absolute;
  top: 14px;
  z-index: 2;
  border-radius: 999px;
  background: rgba(8, 9, 11, 0.72);
  color: var(--ink);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
}

.compare-label.before {
  left: 14px;
}

.compare-label.after {
  right: 14px;
}

.retouch-history-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.retouch-history-item,
.archive-item {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(21, 24, 30, 0.9);
  color: var(--ink);
  cursor: pointer;
  padding: 7px;
  text-align: left;
}

.retouch-history-item img,
.archive-item img {
  width: 100%;
  height: 72px;
  border-radius: 5px;
  object-fit: cover;
}

.retouch-history-item span,
.archive-item span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.video-grid {
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 16px;
}

.video-stage,
.scene-card,
.video-history-card {
  padding: 14px;
}

.video-preview {
  min-height: 255px;
}

.video-preview img {
  height: 255px;
}

.video-preview div {
  left: 18px;
  right: 18px;
  bottom: 18px;
}

.video-preview strong {
  max-width: 520px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 24px;
  line-height: 1.08;
}

.video-upload-zone {
  min-height: 92px;
  padding: 14px;
}

.video-upload-zone strong {
  font-size: 16px;
}

.room-type-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.room-type-grid button {
  min-height: 33px;
  font-size: 12px;
}

.video-controls {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.credit-preview {
  margin-top: 12px;
  padding: 12px 14px;
}

.credit-preview span {
  font-size: 19px;
}

.template-panel,
.narration-panel {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(10, 12, 15, 0.52);
  padding: 14px;
}

.template-panel span,
.narration-head span,
.carousel-card > span,
.social-archive-card span {
  color: var(--gold-2);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.template-panel strong,
.narration-head strong,
.carousel-card strong {
  display: block;
  margin-top: 4px;
  font-size: 16px;
}

.template-panel p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.template-steps,
.carousel-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.template-steps span,
.carousel-steps button {
  border: 1px solid rgba(208, 196, 173, 0.14);
  border-radius: 999px;
  background: rgba(208, 196, 173, 0.07);
  color: var(--muted);
  padding: 7px 9px;
  font-size: 11px;
  font-weight: 850;
}

.narration-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mini-segmented {
  display: inline-flex;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
}

.mini-segmented button {
  min-height: 28px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
}

.mini-segmented button.is-selected {
  background: rgba(208, 196, 173, 0.16);
  color: var(--gold-2);
}

#narrationText {
  min-height: 108px;
}

.voiceover-toggle {
  display: inline-flex;
  grid-auto-flow: column;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--ink);
}

.voiceover-toggle input {
  width: auto;
}

.voiceover-options {
  display: none;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.voiceover-options.is-active {
  display: grid;
}

.voiceover-options span {
  align-self: center;
  justify-self: start;
  border-radius: 999px;
  background: rgba(140, 161, 132, 0.14);
  color: #bfceb9;
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 900;
}

.scene-item {
  grid-template-columns: 76px 1fr;
  min-height: 64px;
  padding: 7px;
}

.scene-item img {
  width: 76px;
  height: 49px;
}

.scene-item span {
  font-size: 13px;
}

.video-status-card {
  grid-column: 1 / -1;
}

.social-grid {
  grid-template-columns: minmax(280px, 0.65fr) minmax(320px, 0.85fr) minmax(280px, 0.7fr);
  gap: 16px;
}

.social-archive-card,
.carousel-card {
  padding: 14px;
}

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

.archive-item.is-selected {
  border-color: rgba(208, 196, 173, 0.42);
  background: rgba(208, 196, 173, 0.12);
}

.social-preview {
  min-height: 410px;
}

.social-preview img {
  height: 410px;
}

.social-preview div {
  background: rgba(10, 12, 15, 0.74);
  color: var(--ink);
}

.social-preview strong {
  font-size: 18px;
}

.carousel-card {
  display: grid;
  align-content: start;
  gap: 14px;
}

.copy-card textarea {
  min-height: 190px;
}

.marketplace-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.marketplace-links a {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(21, 24, 30, 0.82);
  color: var(--ink);
  padding: 8px 11px;
  font-size: 12px;
  font-weight: 900;
}

.segmented button.is-selected,
.room-type-grid button.is-selected,
.scene-item.is-selected {
  border-color: rgba(208, 196, 173, 0.45);
  background: rgba(208, 196, 173, 0.12);
  color: var(--gold-2);
  box-shadow: none;
}

.status-chip.processing,
.status-chip.generating_scenes,
.status-chip.pending {
  background: rgba(208, 196, 173, 0.11);
  color: var(--gold-2);
}

@media (max-width: 1180px) {
  .details-matrix,
  .video-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .social-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .app-view,
  .inline-voice-panel,
  .retouch-grid,
  .video-grid,
  .details-matrix,
  .voiceover-options {
    grid-template-columns: 1fr;
  }

  .detected-facts,
  .voice-upload-row {
    grid-column: auto;
  }

  .before-after-slider {
    min-height: 300px;
  }

  .retouch-history-list,
  .archive-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Video page: modern AI studio console */
#video {
  min-height: calc(100vh - 84px);
}

.video-studio-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.video-studio-header h3 {
  margin-bottom: 0;
  font-size: 25px;
}

.video-studio-header span {
  border: 1px solid rgba(215, 255, 66, 0.18);
  border-radius: 999px;
  background: rgba(215, 255, 66, 0.08);
  color: #e4ff82;
  padding: 9px 12px;
  font-size: 12px;
  font-weight: 900;
}

.video-studio-shell {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 18px;
  min-height: calc(100vh - 158px);
}

.video-create-console {
  position: sticky;
  top: 22px;
  align-self: start;
  display: grid;
  gap: 12px;
  max-height: calc(100vh - 72px);
  overflow: auto;
  border: 1px solid rgba(218, 208, 190, 0.12);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(24, 26, 30, 0.96), rgba(14, 16, 19, 0.96)),
    #101216;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  padding: 14px;
}

.video-create-console::-webkit-scrollbar,
.video-asset-studio::-webkit-scrollbar {
  width: 8px;
}

.video-create-console::-webkit-scrollbar-thumb,
.video-asset-studio::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(218, 208, 190, 0.22);
}

.studio-tabs,
.studio-mode-tabs,
.studio-view-tabs {
  display: flex;
  gap: 8px;
}

.studio-tabs {
  border-bottom: 1px solid rgba(218, 208, 190, 0.1);
  padding-bottom: 10px;
}

.studio-tabs button,
.studio-mode-tabs button,
.studio-view-tabs button,
.prompt-tools button,
.studio-gallery-board button {
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 900;
}

.studio-tabs button {
  min-height: 34px;
  padding: 0 4px;
  font-size: 13px;
}

.studio-tabs button.is-active {
  color: var(--ink);
}

.studio-upload-zone {
  position: relative;
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 150px;
  margin: 0;
  border: 1px dashed rgba(208, 196, 173, 0.24);
  border-radius: 14px;
  background:
    radial-gradient(circle at 50% 0%, rgba(210, 255, 63, 0.08), transparent 60%),
    rgba(34, 36, 40, 0.84);
  color: var(--ink);
  text-align: center;
}

.studio-upload-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.studio-upload-icons {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #d7ff42;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 900;
}

.studio-upload-zone strong {
  font-size: 18px;
}

.studio-upload-zone small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
}

.studio-prompt-card,
.studio-model-card,
.studio-control-grid,
.studio-credit-row,
.video-job-status,
.studio-history-card {
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 12px;
  background: rgba(28, 30, 34, 0.82);
}

.studio-prompt-card,
.studio-model-card {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.studio-prompt-card label,
.studio-model-card label {
  margin: 0;
}

.studio-prompt-card textarea {
  min-height: 128px;
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--ink);
  font-size: 14px;
}

.prompt-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.prompt-tools button,
.studio-gallery-board button {
  min-height: 34px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  padding: 0 11px;
  font-size: 12px;
}

.studio-model-card > span,
.studio-credit-row span,
.studio-cover-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.studio-model-card > strong {
  color: #d7ff42;
  font-size: 20px;
}

.video-create-console .room-type-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.video-create-console .room-type-grid button {
  min-height: 33px;
  border-radius: 10px;
  background: rgba(12, 14, 18, 0.78);
}

.video-create-console .room-type-grid button.is-selected {
  border-color: rgba(215, 255, 66, 0.42);
  background: rgba(215, 255, 66, 0.1);
  color: #e7ff82;
}

.studio-control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
}

.studio-control-grid label {
  margin: 0;
}

.studio-control-grid select {
  min-height: 42px;
  border-color: transparent;
  background: rgba(12, 14, 18, 0.88);
}

.studio-credit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
}

.studio-credit-row strong {
  color: #d7ff42;
  font-size: 22px;
}

.studio-generate-button {
  min-height: 58px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #dbff35, #b8d73f);
  color: #0c0f12;
  cursor: pointer;
  font-size: 18px;
  font-weight: 950;
  box-shadow: 0 18px 46px rgba(215, 255, 66, 0.18);
}

.studio-generate-button.is-loading::before {
  content: "";
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  vertical-align: -2px;
  animation: estatex-spin 800ms linear infinite;
}

.voiceover-options {
  border-top: 1px solid rgba(218, 208, 190, 0.08);
  padding-top: 10px;
}

.video-asset-studio {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 14px;
  max-height: calc(100vh - 72px);
  overflow: auto;
  border-left: 1px solid rgba(218, 208, 190, 0.08);
  padding-left: 6px;
}

.studio-toolbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(7, 8, 8, 0.82);
  backdrop-filter: blur(18px);
  padding: 0 0 10px;
}

.studio-mode-tabs button,
.studio-view-tabs button {
  min-height: 42px;
  border: 1px solid rgba(218, 208, 190, 0.08);
  background: rgba(24, 26, 30, 0.72);
  padding: 0 18px;
}

.studio-mode-tabs button.is-active,
.studio-view-tabs button.is-active {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.07);
}

.studio-gallery-board {
  min-height: 520px;
  border: 1px solid rgba(218, 208, 190, 0.09);
  border-radius: 18px;
  background: rgba(22, 24, 26, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
  padding: 24px;
}

.studio-day-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.studio-day-row strong {
  margin-right: auto;
  color: var(--ink);
  font-size: 21px;
}

.select-box {
  width: 22px;
  height: 22px;
  border: 2px solid rgba(218, 208, 190, 0.14);
  border-radius: 7px;
}

.studio-cover-strip {
  display: grid;
  gap: 20px;
}

.studio-cover-card {
  position: relative;
  overflow: hidden;
  min-height: 250px;
  border-radius: 20px;
  background: #090a0c;
}

.studio-cover-card img {
  width: 100%;
  height: 310px;
  object-fit: cover;
}

.studio-cover-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 6, 7, 0.7), rgba(5, 6, 7, 0.05));
}

.studio-cover-card div {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 22px;
  z-index: 1;
}

.studio-cover-card strong {
  display: block;
  max-width: 740px;
  margin-top: 6px;
  color: var(--ink);
  font-size: 30px;
  line-height: 1.05;
}

.studio-scene-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(140px, 1fr));
  gap: 16px;
}

.studio-scene-grid .scene-item {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 0;
  border: 1px solid rgba(218, 208, 190, 0.09);
  border-radius: 16px;
  background: rgba(9, 10, 12, 0.8);
  padding: 0;
}

.studio-scene-grid .scene-item::after {
  content: "Play";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: #101216;
  padding: 8px 11px;
  font-size: 11px;
  font-weight: 950;
  opacity: 0.92;
}

.studio-scene-grid .scene-item img {
  width: 100%;
  height: 118px;
  border-radius: 0;
  object-fit: cover;
}

.studio-scene-grid .scene-item span {
  display: block;
  padding: 9px 10px 11px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.studio-scene-grid .scene-item.is-selected {
  border-color: rgba(215, 255, 66, 0.28);
  background: rgba(215, 255, 66, 0.07);
}

.video-asset-studio .video-job-status {
  padding: 14px;
}

.studio-history-card {
  padding: 14px;
}

@media (max-width: 1240px) {
  .video-studio-shell {
    grid-template-columns: 320px minmax(0, 1fr);
  }

  .studio-scene-grid {
    grid-template-columns: repeat(3, minmax(130px, 1fr));
  }
}

@media (max-width: 920px) {
  .video-studio-shell {
    grid-template-columns: 1fr;
  }

  .video-create-console,
  .video-asset-studio,
  .studio-toolbar {
    position: static;
    max-height: none;
  }

  .video-studio-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .video-asset-studio {
    border-left: 0;
    padding-left: 0;
  }

  .studio-scene-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Video page: single-screen production desk */
body,
.workspace,
#video,
.video-studio-shell,
.video-asset-studio {
  max-width: 100%;
  overflow-x: hidden;
}

#video {
  height: calc(100dvh - 128px);
  min-height: 650px;
  overflow: hidden;
}

#video .video-studio-header {
  min-height: 46px;
  margin-bottom: 10px;
}

#video .video-studio-header h3 {
  font-size: 21px;
}

#video .video-studio-header span {
  border-color: rgba(208, 196, 173, 0.16);
  background: rgba(208, 196, 173, 0.08);
  color: var(--gold-2);
  padding: 7px 10px;
}

#video .video-studio-shell {
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 12px;
  height: calc(100dvh - 190px);
  min-height: 585px;
  overflow: hidden;
}

#video .video-create-console {
  position: static;
  top: auto;
  align-self: stretch;
  gap: 8px;
  height: 100%;
  max-height: none;
  min-width: 0;
  overflow: hidden;
  border-color: rgba(218, 208, 190, 0.13);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(25, 28, 34, 0.96), rgba(12, 14, 18, 0.98)),
    #101216;
  padding: 12px;
}

#video .video-create-console::before,
#video .studio-gallery-board::before,
#video .video-export-panel::before,
#video .studio-scene-grid::before {
  display: block;
  margin-bottom: 8px;
  color: var(--gold-2);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}

#video .video-create-console::before {
  content: "Yükle";
}

#video .studio-gallery-board::before {
  content: "Önizle";
}

#video .video-export-panel::before {
  display: none;
  content: "";
}

#video .studio-scene-grid::before {
  content: "Kütüphane";
  grid-column: 1 / -1;
  margin-bottom: 0;
}

#video .studio-tabs {
  display: none;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  border-bottom: 0;
  padding-bottom: 0;
}

#video .studio-tabs button {
  min-height: 29px;
  border: 1px solid rgba(218, 208, 190, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 0 5px;
  font-size: 10px;
}

#video .studio-tabs button.is-active {
  background: rgba(208, 196, 173, 0.12);
  color: var(--gold-2);
}

#video .studio-upload-zone {
  min-height: 72px;
  gap: 4px;
  border-color: rgba(208, 196, 173, 0.26);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 0%, rgba(208, 196, 173, 0.11), transparent 60%),
    rgba(23, 26, 32, 0.9);
}

#video .studio-upload-icons {
  background: rgba(208, 196, 173, 0.1);
  color: var(--gold-2);
  padding: 4px 8px;
  font-size: 10px;
}

#video .studio-upload-zone strong {
  font-size: 14px;
}

#video .studio-upload-zone small {
  font-size: 10px;
}

#video .studio-prompt-card,
#video .studio-model-card,
#video .studio-control-grid,
#video .studio-credit-row,
#video .video-job-status,
#video .studio-history-card,
#video .video-export-panel {
  border-color: rgba(218, 208, 190, 0.1);
  background: rgba(18, 21, 27, 0.84);
}

#video .studio-prompt-card,
#video .studio-model-card {
  gap: 6px;
  padding: 9px;
}

#video .studio-prompt-card textarea {
  min-height: 48px;
  max-height: 56px;
  font-size: 11px;
  line-height: 1.25;
}

#video .prompt-tools {
  gap: 6px;
}

#video .prompt-tools button {
  min-height: 26px;
  border-radius: 8px;
  background: rgba(208, 196, 173, 0.08);
  padding: 0 9px;
  font-size: 10px;
}

#video .voiceover-toggle {
  gap: 6px;
  font-size: 10px;
}

#video .voiceover-options {
  gap: 6px;
  padding-top: 7px;
}

#video .voiceover-options select {
  min-height: 31px;
  padding: 7px 8px;
  font-size: 12px;
}

#video .voiceover-options span {
  padding: 7px 8px;
  font-size: 10px;
}

#video .studio-model-card > span,
#video .studio-credit-row span,
#video .studio-cover-card span {
  font-size: 10px;
}

#video .studio-model-card > strong {
  color: var(--gold-2);
  font-size: 15px;
}

#video .video-create-console .room-type-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
}

#video .video-create-console .room-type-grid button {
  min-height: 24px;
  border-radius: 8px;
  padding: 0 4px;
  font-size: 9px;
}

#video .video-create-console .room-type-grid button.is-selected {
  border-color: rgba(208, 196, 173, 0.48);
  background: rgba(208, 196, 173, 0.13);
  color: var(--gold-2);
}

#video .studio-control-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
  padding: 7px;
}

#video .studio-control-grid label {
  gap: 4px;
  font-size: 9px;
}

#video .studio-control-grid select {
  min-height: 29px;
  border-radius: 8px;
  padding: 6px 7px;
  font-size: 10px;
}

#video .studio-credit-row {
  min-height: 34px;
  padding: 7px 9px;
}

#video .studio-credit-row strong {
  color: var(--gold-2);
  font-size: 15px;
}

#video .studio-generate-button {
  min-height: 38px;
  border-radius: 11px;
  background: linear-gradient(135deg, #d0c4ad, #8f9a8a);
  color: #070808;
  font-size: 14px;
  box-shadow: 0 18px 38px rgba(169, 150, 116, 0.17);
}

#video .video-asset-studio {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  grid-template-rows: 38px minmax(0, 1fr) 128px;
  grid-template-areas:
    "toolbar toolbar"
    "preview export"
    "library library";
  align-content: stretch;
  gap: 10px;
  height: 100%;
  max-height: none;
  min-width: 0;
  overflow: hidden;
  border-left: 0;
  padding-left: 0;
}

#video .studio-toolbar {
  grid-area: toolbar;
  position: static;
  min-width: 0;
  background: transparent;
  backdrop-filter: none;
  padding: 0;
}

#video .studio-mode-tabs,
#video .studio-view-tabs {
  min-width: 0;
  gap: 6px;
}

#video .studio-mode-tabs button,
#video .studio-view-tabs button {
  min-height: 34px;
  border-color: rgba(218, 208, 190, 0.08);
  border-radius: 10px;
  background: rgba(24, 27, 33, 0.72);
  padding: 0 12px;
  font-size: 12px;
}

#video .studio-mode-tabs button.is-active,
#video .studio-view-tabs button.is-active {
  background: rgba(208, 196, 173, 0.11);
  color: var(--gold-2);
}

#video .studio-gallery-board {
  grid-area: preview;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border-radius: 14px;
  padding: 12px;
}

#video .studio-day-row {
  gap: 9px;
  margin-bottom: 10px;
}

#video .studio-day-row strong {
  font-size: 16px;
}

#video .studio-day-row button {
  min-height: 29px;
  border-radius: 8px;
  padding: 0 9px;
  font-size: 11px;
}

#video .select-box {
  width: 17px;
  height: 17px;
  border-radius: 5px;
}

#video .studio-cover-card {
  min-height: 0;
  height: 100%;
  border-radius: 14px;
}

#video .studio-cover-card img {
  height: 100%;
  min-height: 0;
}

#video .studio-cover-card div {
  left: 16px;
  right: 16px;
  bottom: 16px;
}

#video .studio-cover-card strong {
  max-width: 680px;
  font-size: clamp(18px, 2vw, 28px);
}

#video .video-export-panel {
  grid-area: export;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 9px;
  min-height: 0;
  overflow: hidden;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 14px;
  padding: 12px;
}

#video .export-panel-head strong {
  display: block;
  color: var(--ink);
  font-size: 17px;
}

#video .export-panel-head span {
  color: var(--gold-2);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 1px;
  text-transform: uppercase;
}

#video .export-panel-head p,
#video .video-job-status p,
#video .video-history-list p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

#video .video-job-status {
  padding: 10px;
}

#video .video-job-status strong {
  font-size: 13px;
}

#video .video-result {
  max-height: 180px;
  overflow: auto;
}

#video .video-result-item {
  grid-template-columns: 1fr;
}

#video .video-result video,
#video .video-result img {
  height: 110px;
}

#video .studio-history-card {
  min-height: 0;
  overflow: hidden;
  padding: 10px;
}

#video .studio-history-card .section-head {
  margin-bottom: 8px;
}

#video .studio-history-card .secondary-action {
  min-height: 30px;
  padding: 0 9px;
  font-size: 11px;
}

#video .video-history-list {
  max-height: 100%;
  overflow: auto;
}

#video .video-job-card {
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 8px;
  padding: 8px;
}

#video .video-job-media {
  width: 72px;
  height: 54px;
}

#video .video-job-media img,
#video .video-job-media video {
  height: 54px;
}

#video .video-job-actions {
  gap: 5px;
}

#video .video-job-actions button,
#video .video-job-actions a {
  min-height: 28px;
  padding: 0 8px;
  font-size: 10px;
}

#video .studio-scene-grid {
  grid-area: library;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  align-content: start;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 14px;
  background: rgba(18, 21, 27, 0.72);
  padding: 10px;
}

#video .studio-scene-grid .scene-item {
  border-radius: 10px;
  min-height: 0;
}

#video .studio-scene-grid .scene-item::after {
  content: "";
  width: 26px;
  height: 26px;
  background:
    linear-gradient(135deg, rgba(242, 238, 231, 0.92), rgba(208, 196, 173, 0.92));
  padding: 0;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.24);
}

#video .studio-scene-grid .scene-item::before {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(50% - 12px);
  z-index: 1;
  width: 0;
  height: 0;
  border-left: 7px solid #101216;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  transform: translate(-35%, -50%);
}

#video .studio-scene-grid .scene-item img {
  height: 74px;
}

#video .studio-scene-grid .scene-item span {
  overflow: hidden;
  padding: 6px 7px 8px;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#video .studio-scene-grid .scene-item.is-selected {
  border-color: rgba(208, 196, 173, 0.38);
  background: rgba(208, 196, 173, 0.1);
}

#video .compact-empty {
  padding: 10px;
}

#video .compact-empty strong {
  font-size: 12px;
}

@media (max-width: 1320px) {
  #video .video-studio-shell {
    grid-template-columns: 284px minmax(0, 1fr);
  }

  #video .video-asset-studio {
    grid-template-columns: minmax(0, 1fr) 250px;
  }

  #video .studio-scene-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  #video .studio-scene-grid .scene-item img {
    height: 64px;
  }
}

@media (max-width: 1050px) {
  #video {
    height: auto;
    min-height: auto;
    overflow: visible;
  }

  #video .video-studio-shell,
  #video .video-asset-studio {
    height: auto;
    min-height: auto;
    overflow: visible;
  }

  #video .video-studio-shell,
  #video .video-asset-studio {
    grid-template-columns: 1fr;
  }

  #video .video-asset-studio {
    grid-template-areas:
      "toolbar"
      "preview"
      "export"
      "library";
    grid-template-rows: auto auto auto auto;
  }

  #video .video-create-console {
    overflow: visible;
  }

  #video .studio-scene-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Shared production layout for photo and video studios */
#retouch,
#video {
  max-width: 100%;
  overflow-x: hidden;
}

#retouch {
  height: calc(100dvh - 128px);
  min-height: 650px;
  overflow: hidden;
}

.photo-studio-shell {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 12px;
  height: calc(100dvh - 190px);
  min-height: 585px;
  margin-top: 0;
  overflow: hidden;
}

.photo-create-console {
  position: static;
  display: grid;
  align-self: stretch;
  gap: 10px;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(218, 208, 190, 0.13);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(25, 28, 34, 0.96), rgba(12, 14, 18, 0.98)),
    #101216;
  padding: 12px;
}

.photo-create-console::before,
.photo-preview-board::before,
.photo-export-panel::before,
.photo-library-panel .library-slider-head > div span,
.video-library-panel .library-slider-head > div span {
  color: var(--gold-2);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}

.photo-create-console::before {
  content: "Yükle";
}

.photo-preview-board::before {
  content: "Önizle";
  display: block;
  margin-bottom: 8px;
}

.photo-export-panel::before {
  content: "Export";
  display: block;
  margin-bottom: 8px;
}

#retouch .drop-zone {
  min-height: 250px;
  border-color: rgba(208, 196, 173, 0.26);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 0%, rgba(208, 196, 173, 0.11), transparent 60%),
    rgba(23, 26, 32, 0.9);
  padding: 18px;
}

#retouch .drop-zone strong {
  font-size: 17px;
}

#retouch .drop-zone p {
  max-width: 230px;
  margin: 4px auto 0;
  font-size: 12px;
  line-height: 1.35;
}

#retouch .retouch-actions {
  margin-top: 0;
}

#retouch .retouch-actions .primary-action {
  min-height: 42px;
}

.photo-asset-studio {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  grid-template-rows: minmax(0, 1fr) 140px;
  grid-template-areas:
    "preview export"
    "library library";
  gap: 10px;
  min-width: 0;
  height: 100%;
  overflow: hidden;
}

.photo-preview-board {
  grid-area: preview;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(360px, 1fr);
  min-width: 0;
  min-height: 0;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 14px;
  background: rgba(18, 21, 27, 0.84);
  padding: 12px;
}

#retouch .before-after-slider {
  justify-self: stretch;
  align-self: stretch;
  width: 100%;
  min-height: 360px;
  height: auto;
  border-radius: 14px;
}

.photo-export-panel {
  grid-area: export;
  display: grid;
  grid-template-rows: auto auto auto;
  align-content: start;
  gap: 10px;
  min-width: 0;
  min-height: 0;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 14px;
  background: rgba(18, 21, 27, 0.84);
  padding: 12px;
}

.photo-export-panel .export-panel-head strong,
#video .export-panel-head strong {
  display: block;
  color: var(--ink);
}

.photo-export-panel .export-panel-head strong {
  font-size: 17px;
}

.photo-export-panel .export-panel-head span,
#video .export-panel-head span {
  color: var(--gold-2);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.photo-export-panel .export-panel-head p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

#retouch .form-message {
  min-height: 50px;
  margin: 0;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 10px;
  background: rgba(10, 12, 15, 0.38);
  padding: 10px;
}

.photo-export-panel #downloadAfter {
  width: 100%;
}

.photo-library-panel,
.video-library-panel {
  grid-area: library;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border: 1px solid rgba(218, 208, 190, 0.1);
  border-radius: 14px;
  background: rgba(18, 21, 27, 0.72);
  padding: 10px;
}

.library-slider-head {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  margin-bottom: 7px;
  padding: 0 2px;
}

.library-slider-head strong {
  display: block;
  margin-top: 2px;
  color: var(--ink);
  font-size: 14px;
}

.library-slider-shell {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: stretch;
  gap: 8px;
  min-width: 0;
  min-height: 0;
}

.library-side-button {
  width: 34px;
  min-height: 78px;
  border: 1px solid rgba(218, 208, 190, 0.12);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(208, 196, 173, 0.14), rgba(208, 196, 173, 0.04)),
    rgba(10, 12, 16, 0.52);
  color: var(--ink);
  cursor: pointer;
  font-size: 23px;
  font-weight: 900;
  line-height: 1;
  transition:
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.library-side-button:hover {
  border-color: rgba(208, 196, 173, 0.34);
  background:
    linear-gradient(180deg, rgba(208, 196, 173, 0.22), rgba(208, 196, 173, 0.08)),
    rgba(14, 17, 22, 0.74);
  transform: translateY(-1px);
}

.library-slider-track {
  display: flex !important;
  gap: 10px;
  min-width: 0;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.library-slider-track::-webkit-scrollbar {
  display: none;
}

#video .video-asset-studio {
  grid-template-rows: 38px minmax(0, 1fr) 140px;
}

#video .studio-scene-grid::before {
  display: none;
  content: "";
}

#video .studio-scene-grid {
  display: flex !important;
  gap: 8px;
  grid-area: auto;
  min-width: 0;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

#video .studio-scene-grid .scene-item {
  flex: 0 0 150px;
  scroll-snap-align: start;
}

#video .studio-scene-grid .scene-item img {
  height: 76px;
}

.retouch-history-list .retouch-history-item {
  flex: 0 0 156px;
  scroll-snap-align: start;
}

#retouch .retouch-history-item img {
  height: 76px;
}

@media (max-width: 1320px) {
  .photo-studio-shell {
    grid-template-columns: 284px minmax(0, 1fr);
  }

  .photo-asset-studio {
    grid-template-columns: minmax(0, 1fr) 250px;
  }

  #video .studio-scene-grid .scene-item,
  .retouch-history-list .retouch-history-item {
    flex-basis: 144px;
  }
}

@media (max-width: 1050px) {
  #retouch {
    height: auto;
    min-height: auto;
    overflow: visible;
  }

  .photo-studio-shell,
  .photo-asset-studio {
    height: auto;
    min-height: auto;
    overflow: visible;
    grid-template-columns: 1fr;
  }

  .photo-asset-studio {
    grid-template-areas:
      "preview"
      "export"
      "library";
    grid-template-rows: auto auto auto;
  }

  .photo-create-console {
    overflow: visible;
  }
}

/* EstateX reference light board skin */
:root {
  --bg: #f8f5ef;
  --surface: #ffffff;
  --surface-2: #f4efe8;
  --ink: #15151d;
  --muted: #77727f;
  --line: #eee8df;
  --gold: #b89468;
  --gold-2: #d8c8ad;
  --ai: #703bff;
  --ai-2: #8c63ff;
  --green: #35b86b;
  --green-soft: #eaf8ef;
  --danger: #d65353;
  --shadow: 0 22px 56px rgba(31, 24, 14, 0.08);
  --radius: 10px;
}

html,
body {
  background: #f8f5ef;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  background:
    radial-gradient(circle at 18% 0%, rgba(112, 59, 255, 0.08), transparent 25rem),
    linear-gradient(135deg, #fbfaf7 0%, #f6f1ea 58%, #fbfaf7 100%);
}

.login-view {
  background: #f8f5ef;
}

.login-shell {
  grid-template-columns: 380px minmax(360px, 480px);
  gap: 42px;
  width: min(960px, 100%);
}

.login-copy {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  border: 1px solid rgba(238, 232, 223, 0.82);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 46px 34px;
}

.login-copy::before {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 58%;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.86)),
    url("../assets/properties/estatex-day-living.png") center / cover;
}

.login-copy .brand,
.login-copy .eyebrow,
.login-copy h1,
.login-copy .lead,
.login-proof {
  position: relative;
  z-index: 1;
}

.brand-mark {
  border-color: var(--ai);
}

.brand-mark::before,
.brand-mark::after {
  border-color: var(--ai);
}

.brand-name {
  color: #101018;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 950;
  letter-spacing: -0.02em;
}

.brand-name span {
  color: var(--ai);
}

.brand-kicker {
  color: #8b8791;
  letter-spacing: 1.1px;
}

.login-copy h1 {
  max-width: 310px;
  margin-top: 34px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 24px;
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.login-copy .lead {
  max-width: 270px;
  font-size: 14px;
  line-height: 1.55;
}

.login-proof {
  gap: 8px;
}

.login-proof span {
  border-color: rgba(112, 59, 255, 0.11);
  background: rgba(112, 59, 255, 0.06);
  color: var(--ai);
  box-shadow: none;
  padding: 8px 11px;
  font-size: 11px;
}

.login-card,
.profile-pill,
.workflow-strip article,
.metric-card,
.price-card,
.empty-state,
.export-summary,
.copy-card,
.upload-card,
.compare-card,
.voice-card,
.portfolio-row,
.inline-voice-panel,
.details-matrix,
.video-stage,
.scene-card,
.video-history-card,
.video-job-card,
.video-job-status,
.credit-preview,
.photo-create-console,
.photo-preview-board,
.photo-export-panel,
.photo-library-panel,
.video-create-console,
.video-export-panel,
.video-library-panel,
.studio-gallery-board,
.studio-prompt-card,
.studio-model-card,
.studio-control-grid,
.studio-credit-row {
  border: 1px solid rgba(238, 232, 223, 0.96);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 44px rgba(31, 24, 14, 0.07);
  backdrop-filter: blur(18px);
}

.login-card {
  border-radius: 14px;
  padding: 18px;
}

.login-card h2 {
  font-size: 24px;
  letter-spacing: -0.02em;
}

.login-card p,
.lead,
.metric-card p,
.workflow-strip p,
.empty-state p,
.price-card p,
.export-summary li,
.drop-zone p,
.inline-voice-panel > div:first-child p,
.video-job-main p,
.video-job-status p,
.credit-preview p,
.export-panel-head p {
  color: var(--muted);
}

label {
  color: #6f6975;
  font-size: 11px;
  letter-spacing: 0;
}

input,
textarea,
select {
  border-color: #ece6dc;
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(112, 59, 255, 0.46);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(112, 59, 255, 0.1);
}

.primary-action,
.studio-generate-button,
.segmented button.is-selected {
  background: linear-gradient(135deg, #703bff, #8c63ff);
  color: #fff;
  box-shadow: 0 14px 30px rgba(112, 59, 255, 0.24);
}

.secondary-action,
.ghost-button,
.text-button {
  border-color: #ece6dc;
  background: #fff;
  color: var(--ink);
}

.text-button {
  color: var(--ai);
}

.app-view {
  grid-template-columns: 220px minmax(0, 1fr);
  background: #f8f5ef;
}

.sidebar {
  gap: 24px;
  border-right: 1px solid #eee8df;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 14px 0 40px rgba(31, 24, 14, 0.03);
  padding: 24px 18px;
}

.sidebar-brand .brand-name {
  font-size: 22px;
}

.side-nav {
  gap: 7px;
}

.nav-item {
  min-height: 38px;
  border-radius: 9px;
  color: #6f6975;
  font-size: 12px;
  font-weight: 850;
}

.nav-item:hover,
.nav-item.is-active {
  border-color: rgba(112, 59, 255, 0.08);
  background: #f1ebff;
  color: var(--ai);
  box-shadow: none;
}

.workspace {
  padding: 22px clamp(22px, 3vw, 42px) 36px;
}

.topbar,
.section-head {
  margin-bottom: 18px;
}

.eyebrow {
  color: #6f6975;
  font-size: 10px;
  letter-spacing: 1px;
}

h2 {
  color: var(--ink);
  font-size: 26px;
  font-weight: 950;
  letter-spacing: -0.03em;
}

h3 {
  color: var(--ink);
  font-size: 22px;
  font-weight: 950;
  letter-spacing: -0.025em;
}

.profile-pill {
  border-radius: 12px;
  padding: 7px 8px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-create {
  min-height: 36px;
  border-radius: 9px;
  padding: 0 14px;
  font-size: 12px;
}

.profile-pill img {
  width: 40px;
  height: 40px;
}

.profile-pill strong {
  color: var(--ink);
  font-size: 14px;
}

.dashboard-grid {
  grid-template-columns: minmax(0, 1fr) 180px 180px;
  gap: 14px;
}

.hero-panel {
  min-height: 286px;
  border-radius: 14px;
  background: #e9e1d5;
}

.hero-panel img {
  min-height: 286px;
}

.hero-panel::after {
  background: linear-gradient(90deg, rgba(15, 13, 12, 0.72), rgba(15, 13, 12, 0.08) 72%);
}

.hero-overlay {
  inset: auto auto 22px 24px;
}

.hero-overlay h3 {
  color: #fff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 31px;
  font-weight: 950;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.workflow-strip {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.metric-card {
  min-height: 286px;
  border-radius: 14px;
  padding: 18px;
}

.metric-card span {
  color: var(--ai);
}

.metric-card strong {
  color: var(--ink);
  font-size: 33px;
}

.workflow-strip article {
  min-height: 92px;
  border-radius: 12px;
  padding: 15px 14px;
}

.workflow-strip span {
  color: var(--ai);
}

.workflow-strip strong {
  color: var(--ink);
  font-size: 14px;
}

.portfolio-row,
.empty-state,
.inline-voice-panel,
.details-matrix,
.upload-card,
.copy-card,
.export-summary,
.price-card {
  border-radius: 12px;
}

.trust-chip,
.detected-facts span,
.matrix-head strong {
  border-color: rgba(112, 59, 255, 0.1);
  background: #f1ebff;
  color: var(--ai);
}

.drop-zone,
.studio-upload-zone {
  border-color: rgba(112, 59, 255, 0.2);
  background:
    radial-gradient(circle at 50% 0%, rgba(112, 59, 255, 0.08), transparent 55%),
    #fbfaf7;
}

.drop-zone strong,
.studio-upload-zone strong {
  color: var(--ink);
}

.segmented {
  border-radius: 12px;
  background: #fff;
}

.segmented button {
  color: var(--muted);
}

.segmented button.is-selected {
  border-radius: 9px;
}

.before-after-slider {
  border-radius: 12px;
  background: #eee8df;
}

.slider-handle {
  background: rgba(255, 255, 255, 0.92);
}

.slider-handle::after {
  border-color: rgba(255, 255, 255, 0.96);
  background: #fff;
  box-shadow: 0 10px 28px rgba(31, 24, 14, 0.18);
}

.compare-label {
  background: rgba(18, 18, 25, 0.72);
  color: #fff;
}

#retouch,
#video {
  min-height: 650px;
}

#retouch .section-head,
#video .video-studio-header {
  color: var(--ink);
}

.photo-studio-shell,
#video .video-studio-shell {
  grid-template-columns: 300px minmax(0, 1fr);
}

.photo-create-console,
#video .video-create-console {
  background: #fff;
  border-radius: 14px;
  padding: 12px;
}

.photo-create-console::before,
.photo-preview-board::before,
.photo-export-panel::before,
.photo-library-panel .library-slider-head > div span,
.video-library-panel .library-slider-head > div span,
#video .video-create-console::before,
#video .studio-gallery-board::before,
#video .export-panel-head span {
  color: var(--ai);
  letter-spacing: 0.9px;
}

.photo-asset-studio,
#video .video-asset-studio {
  gap: 10px;
}

.photo-preview-board,
.photo-export-panel,
.photo-library-panel,
#video .studio-gallery-board,
#video .video-export-panel,
#video .video-library-panel {
  background: #fff;
  border-radius: 14px;
}

.photo-export-panel .export-panel-head strong,
#video .export-panel-head strong,
.library-slider-head strong {
  color: var(--ink);
}

#video .video-studio-header span {
  border-color: rgba(112, 59, 255, 0.1);
  background: #f1ebff;
  color: var(--ai);
}

#video .studio-toolbar {
  background: transparent;
}

#video .studio-mode-tabs button,
#video .studio-view-tabs button {
  border-color: #eee8df;
  background: #fff;
  color: var(--muted);
}

#video .studio-mode-tabs button.is-active,
#video .studio-view-tabs button.is-active {
  background: #f1ebff;
  color: var(--ai);
}

#video .studio-upload-icons {
  background: #f1ebff;
  color: var(--ai);
}

#video .studio-prompt-card,
#video .studio-model-card,
#video .studio-control-grid,
#video .studio-credit-row,
#video .video-job-status,
#video .video-export-panel {
  border-color: #eee8df;
  background: #fbfaf7;
}

#video .studio-prompt-card textarea,
#video .studio-control-grid select {
  background: #fff;
  color: var(--ink);
}

#video .prompt-tools button {
  background: #f1ebff;
  color: var(--ai);
}

#video .studio-model-card > strong,
#video .studio-credit-row strong {
  color: var(--ai);
}

#video .video-create-console .room-type-grid button,
.room-type-grid button {
  border-color: #eee8df;
  background: #fff;
  color: #6f6975;
}

#video .video-create-console .room-type-grid button.is-selected,
.room-type-grid button.is-selected {
  border-color: rgba(112, 59, 255, 0.18);
  background: #f1ebff;
  color: var(--ai);
}

#video .studio-gallery-board {
  box-shadow: 0 18px 44px rgba(31, 24, 14, 0.07);
}

#video .studio-cover-card {
  border-radius: 12px;
  background: #ede7dc;
}

#video .studio-cover-card::after {
  background: linear-gradient(90deg, rgba(17, 17, 24, 0.6), rgba(17, 17, 24, 0.03) 68%);
}

#video .studio-cover-card strong {
  color: #fff;
}

.library-slider-shell {
  grid-template-columns: 32px minmax(0, 1fr) 32px;
}

.library-side-button {
  min-height: 74px;
  border-color: #eee8df;
  border-radius: 10px;
  background: #fff;
  color: var(--ai);
  box-shadow: 0 10px 24px rgba(31, 24, 14, 0.06);
}

.library-side-button:hover {
  border-color: rgba(112, 59, 255, 0.18);
  background: #f1ebff;
}

.retouch-history-item,
.archive-item,
#video .studio-scene-grid .scene-item,
.scene-item {
  border-color: #eee8df;
  background: #fff;
  color: var(--ink);
}

#video .studio-scene-grid .scene-item.is-selected,
.scene-item.is-selected,
.retouch-history-item:hover {
  border-color: rgba(112, 59, 255, 0.26);
  background: #f7f3ff;
  box-shadow: 0 12px 24px rgba(112, 59, 255, 0.08);
}

#video .studio-scene-grid .scene-item::after {
  background: #fff;
  box-shadow: 0 8px 18px rgba(31, 24, 14, 0.16);
}

#video .studio-scene-grid .scene-item::before {
  border-left-color: var(--ai);
}

.scene-item span,
#video .studio-scene-grid .scene-item span {
  color: var(--ink);
}

.video-job-actions button,
.video-job-actions a,
.marketplace-links a {
  border-color: #eee8df;
  background: #fff;
  color: var(--ink);
}

.status-chip.completed,
.portfolio-row .status-pill {
  background: var(--green-soft);
  color: #239656;
}

.status-chip.processing,
.status-chip.generating_scenes,
.status-chip.pending {
  background: #f1ebff;
  color: var(--ai);
}

@media (max-width: 1320px) {
  .photo-studio-shell,
  #video .video-studio-shell {
    grid-template-columns: 284px minmax(0, 1fr);
  }
}

@media (max-width: 1050px) {
  .login-shell,
  .photo-studio-shell,
  #video .video-studio-shell,
  .app-view {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .workflow-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Property Tour Studio */
#video {
  overflow: visible;
}

#video .video-studio-header {
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 18px;
}

#video .video-studio-header h3 {
  font-size: clamp(30px, 3vw, 46px);
  line-height: 1;
}

#video .video-studio-header small {
  display: block;
  margin-top: 8px;
  color: #77716a;
  font-weight: 700;
}

.video-generation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 18px;
  align-items: start;
}

.video-generation-main,
.tour-settings-rail {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.tour-preview-card,
.tour-upload-card,
.tour-settings-card,
.tour-voice-card,
.tour-credit-card,
.tour-export-card {
  border: 1px solid #e7e1d8;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(251, 249, 244, 0.98)),
    #fff;
  box-shadow: 0 24px 70px rgba(31, 24, 14, 0.08);
}

.tour-preview-card,
.tour-upload-card {
  padding: 18px;
}

.tour-settings-card,
.tour-voice-card,
.tour-credit-card,
.tour-export-card {
  padding: 18px;
}

.tour-preview-copy,
.tour-card-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.tour-preview-copy h4,
.tour-card-head h4,
.tour-settings-card h4,
.tour-voice-card h4,
.tour-export-card h4 {
  margin: 0;
  color: #171512;
  font-size: 22px;
  line-height: 1.1;
}

.tour-preview-copy p:not(.eyebrow),
.tour-card-head p:not(.eyebrow),
.tour-export-card p {
  margin: 8px 0 0;
  color: #77716a;
  font-size: 14px;
  line-height: 1.45;
}

.tour-preview-copy button,
.tour-bulk-upload {
  flex: 0 0 auto;
  border: 1px solid rgba(112, 59, 255, 0.18);
  border-radius: 13px;
  background: #f1ebff;
  color: var(--ai);
  cursor: pointer;
  font-weight: 900;
  padding: 12px 14px;
}

.tour-bulk-upload input {
  display: none;
}

.tour-preview-stage {
  position: relative;
  min-height: 360px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 18px;
  background: #15130f;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.tour-preview-stage > img,
.tour-preview-stage > video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tour-preview-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(12, 10, 8, 0.04), rgba(12, 10, 8, 0.62));
}

.tour-play-badge {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #171512;
  font-size: 13px;
  font-weight: 900;
  padding: 9px 13px;
}

.tour-preview-overlay {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 18px;
  z-index: 2;
  display: grid;
  gap: 8px;
  color: #fff;
}

.tour-preview-overlay span {
  width: fit-content;
  max-width: 100%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.88);
  font-size: 13px;
  font-weight: 800;
  padding: 8px 12px;
  backdrop-filter: blur(14px);
}

.tour-preview-overlay strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 4vw, 58px);
  font-weight: 500;
  line-height: 0.96;
  max-width: 720px;
}

.property-photo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.property-photo-slot {
  position: relative;
  display: grid;
  grid-template-rows: 150px auto auto;
  gap: 10px;
  min-height: 255px;
  padding: 10px;
  overflow: hidden;
  border: 1px solid #e9e2d8;
  border-radius: 16px;
  background: #fff;
  cursor: grab;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.property-photo-slot:hover,
.property-photo-slot.is-selected {
  border-color: rgba(112, 59, 255, 0.32);
  box-shadow: 0 16px 34px rgba(112, 59, 255, 0.1);
}

.property-photo-slot.is-dragging {
  opacity: 0.55;
  transform: scale(0.98);
}

.property-photo-slot > img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3efe8;
}

.property-photo-slot.is-empty > img {
  display: none;
}

.slot-order {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #171512;
  font-size: 12px;
  font-weight: 900;
  padding: 7px 9px;
}

.slot-empty {
  display: none;
  min-height: 150px;
  place-items: center;
  text-align: center;
  border: 1px dashed #cfc7bb;
  border-radius: 12px;
  background: #fbfaf7;
  color: #77716a;
}

.property-photo-slot.is-empty .slot-empty {
  display: grid;
}

.slot-empty strong {
  color: var(--ai);
}

.slot-meta {
  display: grid;
  gap: 3px;
}

.slot-meta strong {
  color: #171512;
  font-size: 15px;
}

.slot-meta span {
  color: #817a72;
  font-size: 12px;
  font-weight: 700;
}

.slot-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.slot-actions button {
  min-height: 36px;
  border: 1px solid #e9e2d8;
  border-radius: 10px;
  background: #fbfaf7;
  color: #4f4943;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.slot-actions button:hover {
  border-color: rgba(112, 59, 255, 0.22);
  color: var(--ai);
}

.tour-settings-grid {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.tour-settings-grid label,
.tour-voice-card label {
  display: grid;
  gap: 7px;
  color: #77716a;
  font-size: 12px;
  font-weight: 900;
}

.tour-settings-grid select,
.tour-voice-card select,
.tour-voice-card textarea {
  width: 100%;
  border: 1px solid #e7e1d8;
  border-radius: 12px;
  background: #fff;
  color: #171512;
  font: inherit;
  font-weight: 800;
  padding: 12px 13px;
}

.tour-voice-card textarea {
  min-height: 118px;
  margin-top: 12px;
  resize: vertical;
  line-height: 1.45;
}

.tour-voice-card .prompt-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

.tour-voice-card .prompt-tools button {
  border: 0;
  border-radius: 12px;
  background: #f1ebff;
  color: var(--ai);
  cursor: pointer;
  font-weight: 900;
  padding: 11px 13px;
}

.tour-voice-card .voiceover-toggle {
  display: flex;
  grid-auto-flow: column;
  align-items: center;
  justify-content: end;
  color: #171512;
}

.tour-voice-card .voiceover-options {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.tour-voice-card .voiceover-options.is-active {
  display: grid;
}

.tour-voice-card #voiceoverCost {
  grid-column: 1 / -1;
  border-radius: 12px;
  background: #eef8ee;
  color: #239656;
  font-weight: 900;
  padding: 10px 12px;
}

.tour-credit-card .studio-credit-row {
  margin: 0 0 12px;
  border: 1px solid #e7e1d8;
  border-radius: 15px;
  background: #fbfaf7;
}

.tour-credit-card .studio-credit-row strong {
  color: #171512;
  font-size: 28px;
}

.tour-credit-card .studio-credit-row span {
  color: #77716a;
  font-weight: 800;
}

.tour-credit-card .studio-generate-button {
  width: 100%;
  min-height: 58px;
  border-radius: 15px;
  background: linear-gradient(135deg, #703bff, #3f28d8);
  color: #fff;
  box-shadow: 0 16px 34px rgba(112, 59, 255, 0.26);
}

.tour-credit-card .video-job-status {
  margin-top: 12px;
  border-radius: 14px;
  background: #fff;
}

.tour-preview-stage .video-result {
  position: absolute;
  inset: 0;
  z-index: 5;
  background: #111;
}

.tour-preview-stage .video-result-item,
.tour-generated-output {
  width: 100%;
  height: 100%;
}

.tour-preview-stage .video-result video,
.tour-preview-stage .video-result img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tour-result-buttons,
.video-result-actions {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 8;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tour-result-buttons a,
.tour-result-buttons button,
.video-result-actions a,
.video-result-actions button {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #171512;
  cursor: pointer;
  font-weight: 900;
  padding: 11px 13px;
}

.tour-export-card {
  color: #77716a;
}

@media (max-width: 1280px) {
  .video-generation-layout {
    grid-template-columns: 1fr;
  }

  .tour-settings-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .tour-settings-rail,
  .property-photo-grid {
    grid-template-columns: 1fr;
  }

  .tour-preview-copy,
  .tour-card-head {
    display: grid;
  }

  .tour-preview-stage {
    min-height: 280px;
  }
}
