/* legacy-layer */
@layer legacy {
/* Рилсы and extended news editor in the content manager */
.reels-admin { display: grid; grid-template-columns: minmax(260px, 320px) minmax(0, 1fr); gap: 18px; align-items: start; }
.reels-admin__side { display: flex; flex-direction: column; gap: 12px; }
.reels-admin__list { display: flex; flex-direction: column; gap: 8px; max-height: 60vh; overflow-y: auto; }
.reels-admin__row { display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 10px; align-items: center; padding: 8px; border: 1px solid #e3e6e8; border-radius: 10px; background: #fff; text-align: left; cursor: pointer; font: inherit; }
.reels-admin__row.is-active { border-color: #c64b2e; box-shadow: 0 0 0 2px rgba(198, 75, 46, .15); }
.reels-admin__row strong { display: block; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reels-admin__row small { font-size: 12px; }
.reels-admin__thumb { width: 46px; height: 82px; border-radius: 6px; overflow: hidden; background: #1f2527; display: grid; place-items: center; color: #8d989b; font-size: 11px; }
.reels-admin__thumb img { width: 100%; height: 100%; object-fit: cover; }
.reels-admin__settings { padding: 10px 12px; border: 1px solid #e3e6e8; border-radius: 10px; background: #fafbfb; }
.reels-admin__settings summary { cursor: pointer; font-weight: 700; }
.reels-admin__settings .form-grid { margin-top: 10px; }
.tone-success { color: #217a43; }
.tone-warning { color: #b0571d; }
.tone-info { color: #2d5f9a; }
.tone-muted { color: #7b868a; }
.reel-editor__grid { display: grid; grid-template-columns: minmax(220px, 280px) minmax(0, 1fr); gap: 22px; align-items: start; }
.reel-editor__media { display: flex; flex-direction: column; gap: 10px; }
.reel-phone { position: relative; aspect-ratio: 9 / 16; border-radius: 18px; overflow: hidden; background: #111618; border: 6px solid #1f2527; }
.reel-phone video { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; }
.reel-phone__empty { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: #8d989b; font-size: 13px; text-align: center; padding: 20px; }
.reel-phone__empty b { font-size: 24px; color: #c8d0d2; }
.reel-phone__overlay { position: absolute; left: 0; right: 0; bottom: 44px; padding: 12px; display: flex; flex-direction: column; gap: 6px; pointer-events: none; color: #fff; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); }
.reel-phone__overlay strong { font-size: 14px; }
.reel-phone__overlay span { align-self: flex-start; max-width: 100%; padding: 4px 8px; border-radius: 6px; background: rgba(255, 255, 255, .92); color: #1b1d1e; font-size: 11px; text-shadow: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reel-editor__upload { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.reel-editor__status { flex-basis: 100%; color: #5d676b; font-size: 12px; word-break: break-all; }
.nit-product-picker { display: flex; flex-direction: column; gap: 8px; }
.nit-product-picker__head { display: flex; justify-content: space-between; font-weight: 700; }
.nit-product-picker__head small { color: #5d676b; font-weight: 600; }
.nit-product-picker__list { display: flex; flex-direction: column; gap: 6px; max-height: 320px; overflow-y: auto; padding-right: 4px; }
.nit-product-picker__item { display: grid; grid-template-columns: auto 40px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 6px 8px; border: 1px solid #e3e6e8; border-radius: 8px; cursor: pointer; }
.nit-product-picker__item[hidden] { display: none; }
.nit-product-picker__item.is-selected { border-color: #c64b2e; background: #fff6f2; }
.nit-product-picker__item input:disabled + .nit-product-picker__thumb { opacity: .5; }
.nit-product-picker__thumb { width: 40px; height: 40px; border-radius: 6px; overflow: hidden; background: #f2f4f4; }
.nit-product-picker__thumb img { width: 100%; height: 100%; object-fit: cover; }
.nit-product-picker__item strong { display: block; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nit-product-picker__item small { color: #6b777b; font-size: 12px; }
.nit-product-picker__item em { font-style: normal; font-weight: 700; font-size: 13px; white-space: nowrap; }
.news-ribbon-settings { margin: 0 0 12px; padding: 10px 12px; border: 1px solid #f0d4c8; border-radius: 10px; background: #fff8f4; }
.news-ribbon-settings summary { display: flex; justify-content: space-between; gap: 8px; cursor: pointer; font-weight: 700; }
.news-ribbon-settings summary small { color: #b0571d; font-weight: 600; }
.news-ribbon-settings label { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; font-size: 13px; }
.news-body-textarea { min-height: 220px; }
.news-gallery-editor { display: flex; flex-direction: column; gap: 10px; padding: 12px; border: 1px solid #e3e6e8; border-radius: 10px; }
.news-gallery-editor__list { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.news-gallery-editor__item { display: flex; flex-direction: column; gap: 6px; }
.news-gallery-editor__thumb { aspect-ratio: 4 / 3; border-radius: 8px; overflow: hidden; background: #f2f4f4; display: grid; place-items: center; color: #8d989b; font-size: 12px; }
.news-gallery-editor__thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-gallery-editor__actions { display: flex; gap: 6px; }
.news-video-field { display: flex; flex-direction: column; gap: 8px; }
.news-video-field__upload { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.news-video-field__upload small { color: #5d676b; }
@media (max-width: 980px) {
  .reels-admin, .reel-editor__grid { grid-template-columns: minmax(0, 1fr); }
  .reel-editor__media { max-width: 320px; }
}
}
