:root {
  --bg: #f3ede3;
  --bg-accent: #d7e2e1;
  --surface: rgba(255, 251, 245, 0.78);
  --surface-strong: rgba(255, 251, 245, 0.92);
  --ink: #1d2a2f;
  --muted: #516267;
  --line: rgba(29, 42, 47, 0.14);
  --line-strong: rgba(29, 42, 47, 0.28);
  --accent: #b56a34;
  --accent-soft: rgba(181, 106, 52, 0.14);
  --success: #246b55;
  --warning: #a35b1f;
  --danger: #9d2f2a;
  --shadow: 0 24px 60px rgba(37, 34, 28, 0.12);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(181, 106, 52, 0.16), transparent 32%),
    radial-gradient(circle at right 20%, rgba(78, 122, 131, 0.18), transparent 24%),
    linear-gradient(180deg, var(--bg) 0%, #efe6d9 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(29, 42, 47, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(29, 42, 47, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 90%);
}

.page-shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 56px;
}

.topbar,
.card,
.hero-panel,
.summary-card,
.manifest-block {
  backdrop-filter: blur(18px);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 252, 247, 0.7);
  box-shadow: var(--shadow);
}

.brand,
.card-title,
.editor-heading h3,
.publish-card h3 {
  font-weight: 700;
}

.topbar-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

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

.hero {
  padding: 10px 0 28px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 22px;
}

.hero-copy,
.hero-panel,
.card,
.summary-card,
.manifest-block {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 42px;
  max-width: 920px;
  margin: 0 auto;
  text-align: center;
}

.hero-panel {
  padding: 28px;
}

.example-output-panel {
  margin-top: 18px;
  max-width: 980px;
  margin-left: auto;
  margin-right: auto;
}

.summary-strip {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 18px;
  margin-top: 18px;
}

.summary-card {
  padding: 22px;
}

.summary-title {
  display: inline-block;
  font-weight: 700;
}

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

h1,
h2,
h3 {
  margin: 0;
  font-family: "Fraunces", serif;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.8rem, 5vw, 4.9rem);
  line-height: 0.96;
}

h2 {
  font-size: clamp(2rem, 3vw, 3rem);
}

h3 {
  font-size: 1.28rem;
}

.hero-text,
.section-heading p,
.manifest-copy,
li,
td,
th,
label,
select,
textarea,
.button,
.file-chip,
.status-pill,
.badge {
  font-size: 0.98rem;
  line-height: 1.6;
}

.hero-text,
.section-heading p,
.manifest-copy,
.artifact-meta,
.pipeline-meta,
.info-lines,
.command-note,
li,
td {
  color: var(--muted);
}

.button:hover,
.step-button:hover,
.artifact-button:hover {
  transform: translateY(-1px);
}

.panel-header,
.editor-heading,
.control-row,
.artifact-header,
.detail-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.badge,
.file-chip,
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 251, 245, 0.9);
}

.workflow-list,
.requirements-card ul,
.mini-list {
  margin: 0;
  padding-left: 20px;
}

.workflow-list {
  margin-top: 18px;
}

.requirements-card {
  padding: 18px;
  border-radius: var(--radius-md);
  background: var(--surface-strong);
  border: 1px solid var(--line);
}

.section {
  margin-top: 42px;
}

.section-heading {
  margin-bottom: 18px;
}

.command-note {
  margin: 10px 0 0;
}

.lab-grid,
.pipeline-grid,
.output-grid {
  display: grid;
  gap: 18px;
}

.lab-grid {
  grid-template-columns: minmax(230px, 0.72fr) minmax(0, 1fr) minmax(0, 1fr);
  align-items: start;
}

.card,
.summary-card,
.manifest-block {
  padding: 22px;
}

.stacked {
  align-items: flex-start;
  flex-direction: column;
}

select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.62);
  color: var(--ink);
  font-family: inherit;
}

select {
  padding: 12px 14px;
}

textarea {
  min-height: 320px;
  padding: 16px;
  resize: vertical;
  font-family: Consolas, "Courier New", monospace;
  line-height: 1.55;
}

.pipeline-grid,
.output-grid {
  grid-template-columns: minmax(280px, 0.75fr) minmax(0, 1.25fr);
}

.pipeline-detail,
.artifact-detail {
  min-height: 720px;
}

.artifact-detail {
  height: 720px;
  overflow-y: auto;
}

.pipeline-steps,
.artifact-list {
  display: grid;
  gap: 10px;
}

.step-button,
.artifact-button {
  width: 100%;
  text-align: left;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: rgba(255, 251, 245, 0.72);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, background-color 180ms ease;
}

.step-button.active,
.artifact-button.active {
  border-color: rgba(181, 106, 52, 0.45);
  background: var(--accent-soft);
}

.step-label,
.artifact-label {
  display: block;
  font-weight: 700;
}

.step-meta,
.artifact-meta {
  display: block;
  margin-top: 4px;
  font-size: 0.92rem;
}

.pipeline-detail code,
.artifact-detail code {
  display: block;
  margin-top: 12px;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: rgba(28, 40, 45, 0.94);
  color: #fdf5e8;
  overflow-x: auto;
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.92rem;
  line-height: 1.6;
}

.detail-label {
  display: inline-block;
  margin-top: 14px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.info-lines {
  margin-top: 14px;
}

.info-line {
  margin-top: 8px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.chip {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 251, 245, 0.92);
  font-size: 0.92rem;
}

.media-stack {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.media-stack.compact {
  margin-top: 18px;
}

.media-card,
.manifest-block {
  margin-top: 16px;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: rgba(255, 252, 247, 0.88);
}

.media-card:first-child,
.manifest-block:first-child {
  margin-top: 0;
}

.media-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.media-label {
  font-weight: 700;
}

.media-frame {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(18, 24, 27, 0.96);
}

.artifact-detail .media-frame {
  aspect-ratio: 16 / 9;
  max-height: 280px;
}

.hero-video-frame {
  aspect-ratio: 16 / 9;
  max-width: 360px;
  max-height: 200px;
  margin-left: auto;
}

.two-column-media {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

audio,
video {
  width: 100%;
  display: block;
}

video {
  height: 100%;
  object-fit: contain;
  background: rgba(18, 24, 27, 0.96);
}

.manifest-table-wrap {
  margin-top: 14px;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

.folder-tree {
  margin: 0;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(28, 40, 45, 0.94);
  color: #fdf5e8;
  overflow-x: auto;
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.9rem;
  line-height: 1.6;
}

th,
td {
  padding: 14px 12px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

thead th {
  color: var(--ink);
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

tbody tr:hover {
  background: rgba(181, 106, 52, 0.05);
}

@media (max-width: 1024px) {
  .hero-grid,
  .summary-strip,
  .lab-grid,
  .pipeline-grid,
  .output-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 20px, 1220px);
  }

  .topbar {
    border-radius: 28px;
    align-items: flex-start;
    flex-direction: column;
  }

  .topbar-links,
  .topbar-links {
    width: 100%;
  }

  .hero-copy,
  .hero-panel,
  .card,
  .summary-card,
  .manifest-block {
    padding: 18px;
  }

  textarea {
    min-height: 260px;
  }

  .pipeline-detail,
  .artifact-detail {
    min-height: auto;
  }

  .media-label-row,
  .detail-top,
  .panel-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .two-column-media {
    grid-template-columns: 1fr;
  }
}