:root {
  --ink: #141414;
  --muted: #5f6168;
  --line: #d8d9dd;
  --panel: #ffffff;
  --field: #f6f7f9;
  --accent: #0f8b8d;
  --accent-strong: #0a5c5e;
  --sun: #f5b942;
  --rose: #d9556f;
  --blue: #3478f6;
  --shadow: 0 22px 70px rgba(20, 20, 20, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(15, 139, 141, 0.13), transparent 34%),
    linear-gradient(315deg, rgba(245, 185, 66, 0.2), transparent 38%),
    #f4f2ed;
}

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

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

.studio {
  display: grid;
  gap: 24px;
}

.intro {
  max-width: 760px;
}

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

h1 {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 5rem);
  line-height: 0.96;
}

.intro p:last-child {
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.6;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(300px, 0.92fr) minmax(360px, 1.28fr);
  gap: 22px;
  align-items: start;
}

.composer,
.result-panel {
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(216, 217, 221, 0.9);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.composer {
  display: grid;
  gap: 18px;
  padding: 22px;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 800;
}

textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--field);
  padding: 13px 14px;
  outline: none;
}

textarea:focus,
select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(15, 139, 141, 0.14);
}

textarea {
  resize: vertical;
  line-height: 1.5;
}

.control-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

input[type="range"] {
  accent-color: var(--accent);
}

.actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

button {
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  padding: 12px 16px;
  cursor: pointer;
  min-height: 46px;
}

button:hover {
  background: var(--accent-strong);
}

.secondary {
  color: var(--ink);
  background: #ece7dc;
}

.secondary:hover {
  background: #ded6c7;
}

.result-panel {
  display: grid;
  gap: 16px;
  padding: 16px;
}

.poster {
  min-height: 310px;
  border-radius: 8px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(20, 20, 20, 0.2), rgba(20, 20, 20, 0.55)),
    radial-gradient(circle at 18% 26%, var(--sun), transparent 26%),
    linear-gradient(135deg, var(--rose), var(--accent), var(--blue));
  overflow: hidden;
}

.poster-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  font-weight: 800;
}

.poster h2 {
  margin: auto 0 14px;
  font-size: clamp(2rem, 4vw, 4.3rem);
  line-height: 0.98;
  max-width: 12ch;
}

.poster p {
  margin: 0;
  max-width: 54ch;
  line-height: 1.48;
  font-weight: 700;
}

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

article {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fbfbfc;
  min-height: 150px;
}

article h3 {
  margin: 0 0 8px;
  font-size: 0.92rem;
}

article p {
  margin: 0;
  color: var(--muted);
  line-height: 1.48;
}

.compact {
  justify-content: flex-end;
}

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

  .poster {
    min-height: 270px;
  }
}

@media (max-width: 520px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding: 18px 0;
  }

  .composer,
  .result-panel {
    padding: 14px;
  }

  button {
    width: 100%;
  }

  .poster-top {
    flex-direction: column;
  }
}
