:root {
  --bg-1: #120e0d;
  --bg-2: #261916;
  --bg-3: #40231e;
  --panel: rgba(255, 255, 255, 0.08);
  --panel-strong: rgba(56, 37, 32, 0.88);
  --card: rgba(255, 255, 255, 0.05);
  --line: rgba(255, 255, 255, 0.08);
  --text: #f9efe8;
  --muted: #dcc4b9;
  --accent: #ffab92;
  --accent-strong: #ee7a53;
  --accent-soft: rgba(238, 122, 83, 0.12);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.25);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background: linear-gradient(135deg, var(--bg-1), var(--bg-2) 56%, var(--bg-3));
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(255, 171, 146, 0.1), transparent 28%),
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: auto, 52px 52px, 52px 52px;
  pointer-events: none;
}

.page-shell {
  position: relative;
  z-index: 1;
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.hero-card,
.glass-panel {
  border: 1px solid var(--line);
  border-radius: 30px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.hero-card {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 24px;
  padding: 28px;
  background: linear-gradient(180deg, rgba(42, 26, 23, 0.92), rgba(23, 17, 17, 0.94));
}

.eyebrow,
.section-kicker,
.card-label,
.status-label {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.76rem;
  color: #f0b89a;
}

.hero-copy h1,
.hero-status h2,
.section-head h2,
.info-card h3 {
  margin: 0;
}

.hero-copy h1 {
  margin-top: 12px;
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.hero-text,
.hero-status p,
.section-head h2,
.info-card p,
.dropzone small,
.custom-grid span {
  color: var(--muted);
}

.hero-text {
  margin: 18px 0 0;
  max-width: 36rem;
  font-size: 1rem;
  line-height: 1.8;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.hero-tags span {
  padding: 12px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.hero-status {
  padding: 24px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.05);
}

.hero-status h2 {
  margin-top: 12px;
  font-size: clamp(2.1rem, 4vw, 3rem);
}

.hero-status h3 {
  margin: 24px 0 12px;
  font-size: 1.12rem;
}

.hero-status p {
  margin: 0;
  line-height: 1.7;
}

.workspace {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.glass-panel {
  padding: 24px;
  background: var(--panel);
}

.section-head h2 {
  margin-top: 8px;
  font-size: 1rem;
  line-height: 1.7;
  font-weight: 500;
}

.step-banner {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 171, 146, 0.08);
  color: var(--text);
}

.step-banner strong,
.step-banner span {
  display: inline-flex;
  align-items: center;
}

.step-banner span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.92rem;
}

.upload-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
  padding: 16px 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffb7a1, #ff9d82);
  color: #4f2418;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.upload-button--full {
  width: 100%;
}

.native-file-input {
  width: 100%;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font: inherit;
}

.upload-button input,
.dropzone input {
  display: none;
}

.dropzone {
  display: grid;
  place-items: center;
  gap: 8px;
  margin-top: 18px;
  min-height: 200px;
  padding: 24px;
  text-align: center;
  border: 1.5px dashed rgba(255, 171, 146, 0.45);
  border-radius: 28px;
  background:
    radial-gradient(circle at top, rgba(255, 171, 146, 0.1), transparent 50%),
    rgba(255, 255, 255, 0.02);
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.dropzone:hover,
.dropzone.dragover {
  transform: translateY(-2px);
  border-color: var(--accent);
  background:
    radial-gradient(circle at top, rgba(255, 171, 146, 0.16), transparent 55%),
    rgba(255, 255, 255, 0.04);
}

.drop-icon {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: #fff6f0;
  font-size: 2rem;
}

.info-card {
  margin-top: 18px;
  padding: 18px;
  border-radius: 24px;
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.info-card.warm {
  background: rgba(238, 122, 83, 0.08);
}

.file-feedback--active {
  border-color: rgba(82, 176, 125, 0.35);
  background: rgba(82, 176, 125, 0.09);
}

.info-card h3 {
  margin-top: 10px;
  font-size: 1.12rem;
}

.info-card p {
  margin: 10px 0 0;
  line-height: 1.65;
}

.helper-line {
  margin: 14px 2px 0;
  color: var(--muted);
  line-height: 1.6;
}

.helper-line--strong {
  color: #f0b89a;
}

.preview-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 18px;
}

.preview-column {
  display: grid;
  gap: 10px;
}

.preview-player {
  width: 100%;
  min-height: 220px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #140f0e;
}

.hidden-media {
  position: fixed;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
  left: -9999px;
  top: -9999px;
}

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

.preset,
.primary-button,
.download-button {
  border: 0;
  font: inherit;
}

.preset {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 180ms ease;
}

.preset:hover,
.preset.active {
  background: rgba(255, 171, 146, 0.12);
  border-color: rgba(255, 171, 146, 0.3);
}

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

.custom-grid label {
  display: grid;
  gap: 8px;
}

.custom-grid input {
  width: 100%;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.primary-button,
.download-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  margin-top: 18px;
  padding: 18px 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: #fff8f2;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 18px 40px rgba(238, 122, 83, 0.24);
}

.primary-button:disabled {
  opacity: 0.65;
  cursor: progress;
}

.download-button.disabled {
  opacity: 0.4;
  pointer-events: none;
}

span.download-button.disabled {
  display: inline-flex;
}

.progress-block {
  margin-top: 18px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.92rem;
}

.progress-bar {
  overflow: hidden;
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
}

.progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-strong), var(--accent));
  transition: width 140ms linear;
}

.video-preview-shell {
  margin-top: 18px;
}

#previewVideo,
.empty-preview {
  width: 100%;
  min-height: 220px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #140f0e;
}

#previewVideo {
  object-fit: cover;
}

.empty-preview {
  display: grid;
  place-items: center;
  padding: 20px;
  color: var(--muted);
  text-align: center;
}

.empty-preview--small {
  min-height: 180px;
  margin-top: 18px;
}

.hero-status--success {
  background: rgba(82, 176, 125, 0.14);
}

.hero-status--danger {
  background: rgba(206, 83, 83, 0.16);
}

@media (max-width: 1080px) {
  .hero-card,
  .workspace {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 1200px);
    padding-top: 20px;
  }

  .hero-card,
  .glass-panel {
    padding: 20px;
    border-radius: 26px;
  }

  .hero-copy h1 {
    font-size: 2.7rem;
  }

  .preset-grid,
  .custom-grid {
    grid-template-columns: 1fr;
  }
}
