/* Студия креативов v2: путь шагами, градиенты, библиотека идей. Подключена после calm.css. */
.stw { --g-hot: linear-gradient(120deg, #ff7a3d 0%, #e2552b 30%, #e2457a 65%, #8b5cf6 100%);
  --g-soft: linear-gradient(135deg, #fff1e8 0%, #ffe8f0 55%, #f1eaff 100%);
  --st-card: var(--surface); --st-glow: rgba(226, 85, 43, .18);
  display: flex; flex-direction: column; gap: 18px; min-width: 0; }
:root[data-theme="dark"] .stw { --g-soft: linear-gradient(135deg, #2a1810 0%, #2a1420 55%, #1d1630 100%); --st-glow: rgba(255, 122, 80, .22); }

/* герой */
.stw-hero { position: relative; overflow: hidden; border-radius: 26px; padding: 30px 30px 28px; color: #fff; background: var(--g-hot);
  display: flex; gap: 24px; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; box-shadow: 0 20px 50px -20px rgba(226, 69, 122, .55); }
.stw-hero::before, .stw-hero::after { content: ""; position: absolute; border-radius: 50%; filter: blur(2px); pointer-events: none; }
.stw-hero::before { width: 320px; height: 320px; right: -80px; top: -140px; background: radial-gradient(circle, rgba(255,255,255,.35), transparent 65%); }
.stw-hero::after { width: 220px; height: 220px; left: 30%; bottom: -150px; background: radial-gradient(circle, rgba(255,214,102,.45), transparent 65%); }
.stw-hero > * { position: relative; z-index: 1; }
.stw-hero h1 { font-size: clamp(24px, 3.4vw, 36px); line-height: 1.08; letter-spacing: -.03em; margin: 10px 0 8px; max-width: 560px; }
.stw-hero p { margin: 0; font-size: 15.5px; opacity: .92; max-width: 520px; line-height: 1.45; }
.stw-kicker { display: inline-block; background: rgba(255,255,255,.2); border: 1px solid rgba(255,255,255,.35); backdrop-filter: blur(6px); padding: 5px 12px; border-radius: 99px; font-size: 13px; font-weight: 650; }
.stw-prog { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.3); backdrop-filter: blur(8px); border-radius: 18px; padding: 14px 18px; min-width: 150px; }
.stw-prog b { font-size: 34px; letter-spacing: -.03em; line-height: 1; } .stw-prog b small { font-size: 18px; opacity: .75; }
.stw-prog span { display: block; font-size: 13px; opacity: .9; margin: 2px 0 8px; }
.stw-bar { height: 6px; border-radius: 99px; background: rgba(255,255,255,.3); overflow: hidden; } .stw-bar i { display: block; height: 100%; background: #fff; border-radius: 99px; }

/* плашка «шаг 0 — бриф» и «заказать» */
.stw-brief, .stw-order { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 18px; text-decoration: none; color: var(--ink);
  background: var(--st-card); border: 1.5px dashed var(--accent); transition: transform .15s, box-shadow .15s; }
.stw-brief.soft { border-style: solid; border-color: var(--line); background: var(--g-soft); }
.stw-brief > span, .stw-order > span { font-size: 30px; flex: none; }
.stw-brief div, .stw-order div { flex: 1; min-width: 0; } .stw-brief p, .stw-order p { margin: 2px 0 0; font-size: 13.5px; color: var(--ink-2); }
.stw-brief em, .stw-order em { font-style: normal; font-weight: 700; color: var(--accent); white-space: nowrap; }
.stw-brief:hover, .stw-order:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -16px var(--st-glow); }
.stw-order { border: 1px solid var(--line); background: var(--g-soft); }

/* 4 шага */
.stw-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.stw-step { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 18px; border-radius: 22px; background: var(--st-card); border: 1px solid var(--line);
  text-decoration: none; color: var(--ink); transition: transform .18s, box-shadow .18s, border-color .18s; min-width: 0; }
.stw-step:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -22px var(--st-glow); border-color: transparent; }
.stw-step.next { border: 2px solid transparent; background: linear-gradient(var(--st-card), var(--st-card)) padding-box, var(--g-hot) border-box; box-shadow: 0 22px 44px -24px rgba(226, 69, 122, .6); }
.stw-step h3 { font-size: 18px; margin: 4px 0 0; letter-spacing: -.01em; } .stw-step p { margin: 0; font-size: 13.5px; color: var(--ink-2); line-height: 1.45; flex: 1; }
.stw-step-top { display: flex; justify-content: space-between; align-items: center; }
.stw-n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; background: var(--surface-2); color: var(--ink-2); }
.stw-step.next .stw-n, .stw-step.done .stw-n { background: var(--g-hot); color: #fff; }
.stw-chip { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 99px; }
.stw-chip.ok { background: var(--good-soft); color: var(--good); } .stw-chip.go { background: var(--accent-soft); color: var(--accent); }
.stw-blob { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; font-size: 32px; margin: 8px 0 4px; }
.stw-step.s1 .stw-blob { background: linear-gradient(135deg, #ffe1d1, #ffc6a8); }
.stw-step.s2 .stw-blob { background: linear-gradient(135deg, #ffd9e6, #ffb3cc); }
.stw-step.s3 .stw-blob { background: linear-gradient(135deg, #e9dcff, #cfb8ff); }
.stw-step.s4 .stw-blob { background: linear-gradient(135deg, #fff1c2, #ffd97a); }
:root[data-theme="dark"] .stw-blob { filter: saturate(.9) brightness(.8); }
.stw-meta { font-size: 12.5px; color: var(--ink-3); }
.stw-btn { margin-top: 8px; justify-content: center; pointer-events: none; }

/* полоса идей */
.stw-strip-h { display: flex; justify-content: space-between; align-items: baseline; margin-top: 6px; }
.stw-strip-h h2 { font-size: 19px; margin: 0; } .stw-strip-h a { font-weight: 650; color: var(--accent); text-decoration: none; }
.stw-strip { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; }
.stw-mini { position: relative; flex: none; width: 150px; aspect-ratio: 9 / 14; border-radius: 16px; overflow: hidden; scroll-snap-align: start; background: var(--surface-2); }
.stw-mini img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .3s; }
.stw-mini:hover img { transform: scale(1.05); }
.stw-mini span { position: absolute; left: 8px; right: 8px; bottom: 8px; background: rgba(12, 12, 20, .72); backdrop-filter: blur(6px); color: #fff; font-size: 11.5px; font-weight: 650; padding: 5px 8px; border-radius: 10px; }

/* страница шага: путь сверху */
.stw-path { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.stw-back { font-weight: 650; color: var(--ink-2); text-decoration: none; font-size: 14px; }
.stw-back:hover { color: var(--accent); }
.stw-dots { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; overflow-x: auto; }
.stw-dots b { flex: 0 0 18px; height: 2px; background: var(--line); border-radius: 2px; }
.stw-dots a { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px 5px 5px; border-radius: 99px; text-decoration: none; color: var(--ink-2); font-size: 13.5px; font-weight: 600; white-space: nowrap; background: var(--surface); border: 1px solid var(--line); }
.stw-dots a i { font-style: normal; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); font-size: 12px; font-weight: 800; }
.stw-dots a.on { background: var(--g-hot); color: #fff; border-color: transparent; box-shadow: 0 8px 20px -10px rgba(226, 69, 122, .7); }
.stw-dots a.on i { background: rgba(255,255,255,.25); color: #fff; }
.stw-title { display: flex; gap: 16px; align-items: center; padding: 20px 22px; border-radius: 22px; background: var(--g-soft); border: 1px solid var(--line); }
.stw-ic { width: 60px; height: 60px; flex: none; border-radius: 18px; display: grid; place-items: center; font-size: 30px; background: var(--g-hot); box-shadow: 0 12px 24px -12px rgba(226, 69, 122, .7); }
.stw-title small { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--accent); }
.stw-title h1 { font-size: clamp(22px, 3vw, 28px); margin: 2px 0 2px; letter-spacing: -.02em; } .stw-title p { margin: 0; color: var(--ink-2); font-size: 14.5px; }
.stw-act { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.stw-act p { margin: 0; flex: 1; min-width: 220px; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.stw-act .btn.primary, .stw .btn.primary { background: var(--g-hot); border-color: transparent; color: #fff; box-shadow: 0 10px 22px -12px rgba(226, 69, 122, .8); }
.stw .btn.primary:hover { filter: brightness(1.05); }
.stw-next { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; align-self: flex-end; padding: 14px 20px; border-radius: 18px; text-decoration: none; background: var(--st-card); border: 1px solid var(--line); color: var(--ink); transition: transform .15s, box-shadow .15s; }
.stw-next span { font-size: 12.5px; color: var(--ink-3); } .stw-next b { font-size: 16px; }
.stw-next:hover { transform: translateX(3px); box-shadow: 0 14px 30px -16px var(--st-glow); }
.stw-empty { text-align: center; padding: 36px 20px; border-radius: 22px; background: var(--g-soft); border: 1px dashed var(--line); }
.stw-empty > div { font-size: 44px; } .stw-empty h3 { margin: 8px 0 4px; } .stw-empty p { margin: 0 auto 12px; max-width: 460px; color: var(--ink-2); font-size: 14px; }

/* стратегия и тексты — живее */
.stw-strat .card, .stw-texts .card, .stw .stw-form { border-radius: 22px; }
.stw-strat .seg-card { border-radius: 18px; transition: transform .15s, box-shadow .15s; }
.stw-strat .seg-card:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -18px var(--st-glow); }
.stw-strat .seg-card .rank { background: var(--g-hot); color: #fff; }
.stw-strat .badge.accent, .stw-texts .badge.accent { background: var(--accent-soft); color: var(--accent); }
.stw-texts .ad { border-radius: 18px; box-shadow: 0 16px 34px -24px rgba(24, 24, 27, .35); }
.stw-texts .ad .pg { background: var(--g-hot); }

/* библиотека идей */
.ideas-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.ideas-type { display: inline-flex; padding: 4px; border-radius: 14px; background: var(--surface-2); gap: 2px; }
.ideas-type button { border: 0; background: none; padding: 8px 14px; border-radius: 10px; font: 650 14px var(--font); color: var(--ink-2); cursor: pointer; white-space: nowrap; }
.ideas-type button.on { background: var(--surface); color: var(--ink); box-shadow: 0 2px 8px rgba(24,24,27,.08); }
.ideas-search { flex: 1; min-width: 200px; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; color: var(--ink-3); }
.ideas-search input { border: 0; outline: 0; background: none; flex: 1; min-width: 0; height: 40px; font: 15px var(--font); color: var(--ink); }
.ideas-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.ideas-bar .ideas-sort { width: auto; flex: none; min-width: 0; }
.ideas-niches { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 4px; margin-top: 10px; }
.ideas-niches .chip { white-space: nowrap; }
.ideas-niches .chip.on { background: var(--g-hot); border-color: transparent; }
.ideas-count { font-size: 13px; color: var(--ink-3); margin: 14px 0 8px; }
.ideas { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.idea { display: flex; flex-direction: column; text-align: left; padding: 0; border: 1px solid var(--line); border-radius: 20px; overflow: hidden; background: var(--st-card); cursor: pointer; font: inherit; color: var(--ink); transition: transform .18s, box-shadow .18s; min-width: 0; }
.idea:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -22px var(--st-glow); }
.idea-img { position: relative; aspect-ratio: 9 / 13; background: var(--surface-2); overflow: hidden; }
.idea.landing .idea-img { aspect-ratio: 9 / 11; }
.idea-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; transition: transform .35s; }
.idea:hover .idea-img img { transform: scale(1.04); }
.idea-noimg { display: grid; place-items: center; height: 100%; font-size: 44px; background: var(--g-soft); }
.idea-kind, .idea-own { position: absolute; top: 10px; left: 10px; background: rgba(12, 12, 20, .7); backdrop-filter: blur(6px); color: #fff; font-size: 11.5px; font-weight: 700; padding: 4px 9px; border-radius: 99px; }
.idea-own { left: auto; right: 10px; background: var(--accent); }
.idea-live { position: absolute; left: 10px; right: 10px; bottom: 10px; font-size: 12px; font-weight: 700; padding: 6px 9px; border-radius: 11px; background: rgba(12, 12, 20, .72); backdrop-filter: blur(6px); color: #fff; }
.idea-live.hot { background: var(--g-hot); }
.idea-live.soft { font-weight: 600; color: rgba(255,255,255,.85); }
.idea-b { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.idea-b b { font-size: 14px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.idea-sub { font-size: 12.5px; color: var(--ink-3); }
.idea-tag { align-self: flex-start; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); }
.ideas-note { margin: 12px 0 0; padding: 12px 14px; border-radius: 14px; background: var(--g-soft); font-size: 13.5px; color: var(--ink-2); line-height: 1.5; }
.ideas-tool { margin-top: 14px; border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; background: var(--st-card); }
.ideas-tool summary { cursor: pointer; font-weight: 700; font-size: 15px; }
.ideas-myl { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 10px 12px; cursor: pointer; font: inherit; color: var(--ink); }
.ideas-myl span { flex: 1; min-width: 0; font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ideas-myl em { font-style: normal; font-size: 12.5px; white-space: nowrap; }

@media (max-width: 1100px) { .stw-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .stw-hero { padding: 22px 20px; border-radius: 22px; } .stw-prog { width: 100%; }
  .stw-steps { grid-template-columns: 1fr; gap: 10px; }
  .stw-step { flex-direction: column; } .stw-blob { width: 52px; height: 52px; font-size: 26px; }
  .stw-dots a span { display: none; } .stw-dots a { padding: 4px; } .stw-dots a.on span { display: inline; } .stw-dots a.on { padding-right: 12px; }
  .stw-title { padding: 16px; } .stw-ic { width: 48px; height: 48px; font-size: 24px; border-radius: 14px; }
  .stw-brief, .stw-order { flex-wrap: wrap; } .stw-brief em, .stw-order em { width: 100%; }
  .stw-next { align-self: stretch; align-items: flex-start; }
  .ideas { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .idea-b { padding: 10px; } .idea-live { font-size: 11px; left: 6px; right: 6px; bottom: 6px; }
  .ideas-bar .ideas-sort { flex: 1; } .ideas-type { width: 100%; } .ideas-type button { flex: 1; padding: 8px 6px; }
}
