/* ===== Карточка произведения ===== */

.work-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0,0,0,.08);
    transition: transform .25s ease, box-shadow .25s ease;
}

.work-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,.12);
}

:is(.work-card__link, .work-card__shell) {
    display: block;
    color: inherit;
    text-decoration: none;
}

/* Изображение (арты) */

.work-card__media > img {
    width: 100%;
    display: block;
}

/* Контент */

.work-card__content {
    padding: 14px 16px 18px;
}

.work-card__title {
    font-size: 16px;
    line-height: 1.3;
    margin-bottom: 6px;
}

.work-card__excerpt {
    font-size: 14px;
    line-height: 1.5;
    color: #555;
}

/* Жанры */

.work-card__genres {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.work-card__genre {
    font-size: 12px;
    padding: 4px 8px;
    background: #f0f2f5;
    border-radius: 20px;
    color: #444;
    white-space: nowrap;
}

/* Мета */

.work-card__meta {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-top:10px;
}

.work-card__author {
  display:inline-flex;
  align-items:center;
  gap:10px;
  min-width:0;
}

.work-card__date {
  white-space:nowrap;
  opacity:.75;
  font-size:13px;
  line-height:1
}

.work-like {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 14px;
}

.work-like.is-liked {
  color: crimson;
}

.work-like[disabled] {
  opacity: .5;
  cursor: default;
}

.work-card__author-avatar{
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  display:block;
  flex: 0 0 32px;
}

.work-card__author-name{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  line-height:1.1;
}

.work-author-link{
  display:inline-flex;
  align-items:center;
  gap:10px;
  text-decoration:none;
}

/* =========================
   Single work header (popup + single)
   ========================= */

.work-head{
  margin: 18px 0 18px;
  padding: 0 0 14px;
  border-bottom: 1px solid #eee;
}

.work-head__chips{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin: 0 0 10px;
}

.work-chip{
  display:inline-flex;
  align-items:center;
  padding: 6px 10px;
  border: 1px solid #e7e7e7;
  border-radius: 999px;
  text-decoration:none;
  background:#fff;
  font-size: 13px;
  color: inherit;
}

.work-head__title{
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1.15;
}

.work-head__bar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
}

.work-head__author-link{
  display:flex;
  align-items:center;
  gap: 12px;
  text-decoration:none;
  color: inherit;
  min-width: 0;
}

.work-head__avatar{
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  display:block;
  flex: 0 0 44px;
}

.work-head__who{
  min-width:0;
}

.work-head__name{
  font-size: 15px;
  line-height: 1.2;
  font-weight: 600;
  white-space: nowrap;
  overflow:hidden;
  text-overflow: ellipsis;
  max-width: 260px;
}

.work-head__date{
  font-size: 13px;
  opacity: .7;
  line-height: 1.2;
  margin-top: 2px;
}

.work-head__actions{
  display:flex;
  align-items:center;
  gap: 10px;
  flex: 0 0 auto;
}

/* Унифицируем кнопку подписки (на случай если UM выводит свою разметку) */
.work-head__follow button,
.work-head__follow .button,
.work-head__follow a{
  border: 1px solid #e7e7e7;
  border-radius: 12px;
  background: #fff;
  padding: 8px 12px;
  text-decoration:none;
  color: inherit;
  display:inline-flex;
  align-items:center;
  gap: 8px;
  cursor:pointer;
}

.work-like-count{
  display:inline-flex;
  align-items:center;
  padding: 8px 12px;
  border: 1px solid #e7e7e7;
  border-radius: 12px;
  background:#fff;
  font-size: 14px;
}

/* Mobile */
@media (max-width: 768px){
  .work-head__title{ font-size: 26px; }

  .work-head__bar{
    flex-direction: column;
    align-items: stretch;
  }

  .work-head__actions{
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .work-head__name{ max-width: 100%; }
}

.work-head__edit{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border:1px solid #e7e7e7;
  border-radius:12px;
  background:#fff;
  text-decoration:none;
  color:inherit;
}
.work-head__edit:hover{ transform: translateY(-1px); }

.my-works__workshop{
  display:flex;
  gap:18px;
  align-items:center;
  justify-content:space-between;
  margin:0 0 18px;
  padding:18px 20px;
  color:#25213e;
  background:linear-gradient(135deg,#f2f0ff,#fff 70%);
  border:1px solid rgba(108,77,255,.18);
  border-radius:16px;
}
.my-works__workshop-copy{
  display:flex;
  min-width:0;
  flex-direction:column;
}
.my-works__workshop-copy span{
  margin-bottom:4px;
  color:#5b4bd8;
  font-size:10px;
  font-weight:800;
  letter-spacing:.07em;
  text-transform:uppercase;
}
.my-works__workshop-copy strong{font-size:14px; line-height:1.4}
.my-works__workshop-links{display:flex; gap:8px; flex:0 0 auto; flex-wrap:wrap; justify-content:flex-end}
.my-works__workshop-links a{
  display:inline-flex;
  min-height:36px;
  padding:8px 12px;
  color:#4b3fc4;
  background:#fff;
  border:1px solid rgba(91,75,216,.2);
  border-radius:999px;
  align-items:center;
  font-size:12px;
  font-weight:700;
  text-decoration:none;
}
.my-works__workshop-links a:hover{border-color:rgba(91,75,216,.45); color:#3529a8}

@media (max-width:760px){
  .my-works__workshop{align-items:flex-start; flex-direction:column}
  .my-works__workshop-links{justify-content:flex-start}
}

.my-works__tabs{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin: 10px 0 14px;
}

.my-works__tab{
  padding:8px 12px;
  border:1px solid #e7e7e7;
  border-radius:999px;
  text-decoration:none;
  background:#fff;
  color:inherit;
}

.my-works__tab.is-active{
  background:#000;
  border-color:#000;
  color:#fff;
}

.my-works__search{
  display:flex;
  gap:10px;
  align-items:center;
  margin: 0 0 18px;
  flex-wrap:wrap;
}

.my-works__search-input{
  flex: 1 1 320px;
  padding:10px 12px;
  border:1px solid #e7e7e7;
  border-radius:12px;
}

.my-works__search-btn{
  padding:10px 14px;
  border:1px solid #e7e7e7;
  border-radius:12px;
  background:#fff;
  cursor:pointer;
}

.my-works__search-reset{
  padding:10px 12px;
  border-radius:12px;
  text-decoration:none;
  color:inherit;
  opacity:.75;
}

.my-works__search-hint{
  margin: -10px 0 16px;
  opacity: .8;
}

.my-works.is-loading{
  opacity: .6;
  pointer-events: none;
  filter: grayscale(.1);
}

.user-works.is-loading{
  opacity: .6;
  pointer-events: none;
}

.work-card__status,
.work-status{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  border:1px solid #e7e7e7;
  background:#f7f7f7;
  margin:8px 0 0;
}

.work-status__badge{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border:1px solid #e7e7e7;
  border-radius:999px;
  font-size:13px;
  line-height:1;
  background:#fff;
  opacity:.9;
}




/* =========================
   ART GRID — PINTEREST MASONRY
========================= */

/* ВАЖНО: применять только для арт-сеток */
.art-grid.art-grid--masonry{
  column-count: 4;
  column-gap: 18px;
}

@media (max-width: 1200px){
  .art-grid.art-grid--masonry{ column-count: 3; }
}
@media (max-width: 900px){
  .art-grid.art-grid--masonry{ column-count: 2; }
}
@media (max-width: 560px){
  .art-grid.art-grid--masonry{ column-count: 1; }
}

/* Каждая карточка должна быть "column item" */
.art-grid.art-grid--masonry .work-card--art{
  display: inline-block;
  width: 100%;
  margin: 0 0 18px;
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  page-break-inside: avoid;
}

/* Media контейнер БЕЗ фиксированной высоты */
.art-grid.art-grid--masonry .work-card--art .work-card__media{
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 14px;
  background: #f3f3f3;
}

/* Ключ: НЕ обрезаем горизонтальные.
   Высота = auto, картинка целиком по ширине */
.art-grid.art-grid--masonry .work-card--art .work-card__media > img{
  width: 100%;
  height: auto;
  display: block;
}

/* Hover overlay */
.art-grid.art-grid--masonry .work-card--art .work-card__hover{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  gap:8px;
  padding:14px;
  color:#fff;
  opacity:0;
  pointer-events:none;
  transition: opacity .18s ease;
  background: linear-gradient(180deg, rgba(0,0,0,0) 45%, rgba(0,0,0,.55) 100%);
}

.art-grid.art-grid--masonry .work-card--art:hover .work-card__hover{
  opacity:1;
}

.art-grid.art-grid--masonry .work-card__hover-genre{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
}

.art-grid.art-grid--masonry .work-card__hover-title{
  font-weight: 700;
  font-size: 16px;
  line-height: 1.15;
  text-shadow: 0 1px 8px rgba(0,0,0,.35);
  overflow:hidden;
  text-overflow:ellipsis;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
}

.art-grid.art-grid--masonry .work-card__hover-meta{
  display:flex;
  gap:12px;
  font-size: 13px;
  opacity: .95;
}

/* mobile/touch: hover нет — показываем оверлей всегда */
@media (hover: none) {
  .art-grid.art-grid--masonry .work-card--art .work-card__hover{
    opacity:1;
  }
}


/* hover meta (avatar+name) внутри overlay */
.art-grid.art-grid--masonry .work-card__hover-author{
  display:inline-flex;
  align-items:center;
  gap:8px;
  min-width:0;
}

.art-grid.art-grid--masonry .work-card__hover-avatar{
  width:22px;
  height:22px;
  border-radius:50%;
  object-fit:cover;
  flex:0 0 22px;
}

.art-grid.art-grid--masonry .work-card__hover-name{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:180px;
}

/* важное: чтобы вся карточка была "одним куском" и не давала белых хвостов */
.art-grid.art-grid--masonry .work-card--art{
  background: transparent;
  box-shadow: none;
}

.art-grid.art-grid--masonry .work-card--art:hover{
  transform: none;
  box-shadow: none;
}

/* кликабельность + корректный overlay */
.art-grid.art-grid--masonry .work-card--art :is(.work-card__link, .work-card__shell){
  display:block;
}

/* =========================
   ART GRID — HOVER (FIX CLASSES)
========================= */

/* контейнер с инфо */
.art-grid.art-grid--masonry .work-card--art .work-card__hover{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  gap:10px;
  padding:14px;
  color:#fff;
  opacity:0;
  pointer-events:none;
  transition: opacity .18s ease;
  z-index: 2; /* важно */
  background: linear-gradient(180deg, rgba(0,0,0,0) 45%, rgba(0,0,0,.60) 100%);
}

.art-grid.art-grid--masonry .work-card--art:hover .work-card__hover{
  opacity:1;
}

/* обёртка для жанра (у тебя work-card__hover-genres) */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-genres{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
}

/* сам жанр (у тебя work-card__hover-genre) */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-genre{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  line-height:1;
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* заголовок */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-title{
  font-weight: 700;
  font-size: 16px;
  line-height: 1.15;
  text-shadow: 0 1px 8px rgba(0,0,0,.35);
  overflow:hidden;
  text-overflow:ellipsis;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
}

/* мета-ряд (лайки/комменты) */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-meta{
  display:flex;
  gap:12px;
  font-size: 13px;
  opacity: .95;
  align-items:center;
}

/* элементы меты (у тебя work-card__hover-item) */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-item{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  background: rgba(0,0,0,.25);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* touch: hover нет — показываем инфо всегда */
@media (hover: none) {
  .art-grid.art-grid--masonry .work-card--art .work-card__hover{
    opacity:1;
  }
}


/* =========================
   ART CARD HOVER (общие стили — НЕ зависят от masonry)
========================= */

.work-card--art .work-card__media{
  position: relative; /* ключевое: чтобы absolute overlay работал везде */
  overflow: hidden;
  border-radius: 14px;
  background: #f3f3f3;
}

.work-card--art .work-card__media > img{
  width: 100%;
  height: auto;
  display: block;
}

.work-card--art .work-card__hover{
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px;
  color: #fff;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
  background: linear-gradient(180deg, rgba(0,0,0,0) 45%, rgba(0,0,0,.55) 100%);
}

.work-card--art:hover .work-card__hover{
  opacity: 1;
}

.work-card__hover-genre{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
}

.work-card__hover-title{
  font-weight: 700;
  font-size: 16px;
  line-height: 1.15;
  text-shadow: 0 1px 8px rgba(0,0,0,.35);
  overflow:hidden;
  text-overflow:ellipsis;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
}

.work-card__hover-meta{
  display:flex;
  gap:12px;
  font-size: 13px;
  opacity: .95;
}

/* touch/mobile */
@media (hover: none) {
  .work-card--art .work-card__hover{ opacity: 1; }
}


/* FIX: hover avatar size in Chromium (Chrome/Yandex) */
.art-grid.art-grid--masonry .work-card--art .work-card__hover-author {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.art-grid.art-grid--masonry .work-card--art .work-card__hover-avatar {
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  min-height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
  flex: 0 0 22px !important;
}

/* На всякий случай — если тема пытается растянуть img в ховере */
.art-grid.art-grid--masonry .work-card--art .work-card__hover img {
  width: auto;
  height: auto;
  max-width: 100%;
}

/* =========================
   MASONRY OVERRIDE (важно!)
   ========================= */

.art-grid.art-grid--masonry{
  /* выключаем grid из style.css */
  display: block !important;

  column-count: 4;
  column-gap: 18px;
}

@media (max-width: 1200px){
  .art-grid.art-grid--masonry{ column-count: 3; }
}
@media (max-width: 900px){
  .art-grid.art-grid--masonry{ column-count: 2; }
}
@media (max-width: 560px){
  .art-grid.art-grid--masonry{ column-count: 1; }
}

/* элементы внутри columns */
.art-grid.art-grid--masonry .work-card--art{
  display: inline-block;
  width: 100%;
  margin: 0 0 18px;

  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  page-break-inside: avoid;

  /* чтобы не было “хвостов” */
  background: transparent;
  box-shadow: none;
}

.art-grid.art-grid--masonry .work-card--art:hover{
  transform: none;
  box-shadow: none;
}

/* картинка НЕ обрезается */
.art-grid.art-grid--masonry .work-card--art .work-card__media{
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 14px;
  background: #f3f3f3;
}

.art-grid.art-grid--masonry .work-card--art .work-card__media > img{
  width: 100%;
  height: auto;
  display: block;
}

/* SEARCH: принудительно включаем masonry как на остальных страницах */
.search .art-grid.art-grid--masonry,
.search-results .art-grid.art-grid--masonry{
  display: block !important;         /* если где-то задан display:grid */
  column-count: 4;
  column-gap: 18px;
}

@media (max-width: 1200px){
  .search .art-grid.art-grid--masonry,
  .search-results .art-grid.art-grid--masonry{ column-count: 3; }
}
@media (max-width: 900px){
  .search .art-grid.art-grid--masonry,
  .search-results .art-grid.art-grid--masonry{ column-count: 2; }
}
@media (max-width: 560px){
  .search .art-grid.art-grid--masonry,
  .search-results .art-grid.art-grid--masonry{ column-count: 1; }
}

/* элемент колонки */
.search .art-grid.art-grid--masonry .work-card--art,
.search-results .art-grid.art-grid--masonry .work-card--art{
  display: inline-block !important;
  width: 100% !important;
  margin: 0 0 18px !important;
  break-inside: avoid;
}


.portal-work-delete-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;

  padding:10px 14px;
  border-radius:10px;

  border:1px solid rgba(220, 50, 50, .35);
  background: rgba(220, 50, 50, .08);

  cursor:pointer;
  transition: .15s ease;
}

.portal-work-delete-btn:hover{
  background: rgba(220, 50, 50, .14);
  border-color: rgba(220, 50, 50, .5);
}

.portal-work-delete-btn:disabled{
  opacity:.6;
  cursor:not-allowed;
}

/* =========================
   WORK CONTENT NORMALIZE
   Контент произведения (текст)
   ========================= */

.work-text-content{
  font-family: var(--smysly-font-family, "Manrope", system-ui, sans-serif);
  font-size: 16px;
  line-height: 1.7;
  word-break: break-word;
  overflow-wrap: anywhere;
}

/* Обычный текст всегда наследует базовую типографику произведения. */
.work-text-content p,
.work-text-content div,
.work-text-content span,
.work-text-content font,
.work-text-content a,
.work-text-content li,
.work-text-content blockquote,
.work-text-content strong,
.work-text-content b,
.work-text-content em,
.work-text-content i,
.work-text-content u,
.work-text-content s,
.work-text-content del,
.work-text-content mark,
.work-text-content sub,
.work-text-content sup{
  font-family: inherit !important;
  font-size: inherit !important;
  line-height: inherit !important;
  color: inherit !important;
}

/* Пустые презентационные обёртки из старых вставок не должны сохранять начертание. */
.work-text-content span,
.work-text-content font{
  font-weight: inherit !important;
  font-style: inherit !important;
}

/* Базовые отступы */
.work-text-content p{
  margin: 0 0 14px;
}

/* Смысловые заголовки остаются заголовками, но их размеры едины для всех работ. */
.work-text-content h1,
.work-text-content h2,
.work-text-content h3,
.work-text-content h4,
.work-text-content h5,
.work-text-content h6{
  font-family: inherit !important;
  color: inherit !important;
  line-height: 1.3 !important;
  margin: 18px 0 10px;
}

.work-text-content h1{ font-size: 28px !important; }
.work-text-content h2{ font-size: 22px !important; }
.work-text-content h3{ font-size: 18px !important; }
.work-text-content h4{ font-size: 16px !important; }
.work-text-content h5{ font-size: 16px !important; }
.work-text-content h6{ font-size: 16px !important; }

/* Списки */
.work-text-content ul,
.work-text-content ol{
  margin: 0 0 14px 22px;
  padding: 0;
}

.work-text-content li{
  margin: 0 0 6px;
}

/* Цитаты */
.work-text-content blockquote{
  margin: 0 0 14px;
  padding: 10px 14px;
  border-left: 3px solid rgba(0,0,0,.2);
}

/* Ссылки */
.work-text-content a{
  text-decoration: underline;
}

/* Пользовательское смысловое форматирование сохраняем. */
.work-text-content strong,
.work-text-content b{
  font-weight: 700 !important;
}

.work-text-content em,
.work-text-content i{
  font-style: italic !important;
}

.work-text-content u{
  text-decoration: underline !important;
}


/* === Work groups / series / cycles / collections === */
.work-group-block,
.work-group-page__article{
  background:#fff;
  border:1px solid #e7e7e7;
  border-radius:18px;
  padding:20px;
  margin:22px 0;
}

.work-group-block__head,
.work-group-page__header{
  display:flex;
  gap:20px;
  justify-content:space-between;
  align-items:flex-start;
}

.work-group-block__eyebrow,
.work-group-page__eyebrow{
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.08em;
  opacity:.6;
  margin-bottom:6px;
}

.work-group-block__title,
.work-group-page__title{
  margin:0;
  font-size:28px;
  line-height:1.15;
}

.work-group-block__title a{ text-decoration:none; color:inherit; }
.work-group-block__excerpt,
.work-group-page__description{ margin-top:12px; color:#374151; }
.work-group-block__meta,
.work-group-page__meta{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin-top:14px;
  font-size:14px;
  color:#4b5563;
}

.work-group-block__status{
  display:inline-flex;
  padding:7px 12px;
  border-radius:999px;
  font-size:13px;
  white-space:nowrap;
  background:#f3f4f6;
}
.work-group-block__status.is-completed{ background:#ecfdf5; }

.work-group-block__nav{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:16px;
}
.work-group-block__nav-link{
  text-decoration:none;
  border:1px solid #e5e7eb;
  border-radius:12px;
  padding:8px 12px;
  color:inherit;
}

.work-group-block__list,
.work-group-page__list{
  margin:16px 0 0;
  padding-left:20px;
}
.work-group-block__list li,
.work-group-page__item{
  margin:8px 0;
}
.work-group-block__list li.is-current a{ font-weight:700; }
.work-group-block__part,
.work-group-page__item-part{ opacity:.6; margin-right:4px; }

.work-group-page__cover{
  width:min(280px, 34%);
  flex:0 0 auto;
}
.work-group-page__cover img{
  width:100%;
  height:auto;
  display:block;
  border-radius:16px;
}
.work-group-page__intro{ flex:1 1 auto; }
.work-group-page__item-link{
  display:flex;
  gap:14px;
  align-items:center;
  text-decoration:none;
  color:inherit;
  border:1px solid #f0f0f0;
  border-radius:14px;
  padding:12px;
}
.work-group-page__item-thumb img{
  width:64px;
  height:64px;
  object-fit:cover;
  border-radius:10px;
  display:block;
}
.work-group-page__item-main{
  display:flex;
  flex-direction:column;
  gap:4px;
}
.work-group-page__item-sub{
  font-size:13px;
  color:#6b7280;
}

.work-edit__grid{
  display:grid;
  gap:14px;
}
.work-edit__grid--2{
  grid-template-columns:repeat(2, minmax(0, 1fr));
}
.work-edit__textarea{
  width:100%;
  min-height:110px;
  border:1px solid #d1d5db;
  border-radius:12px;
  padding:12px 14px;
  resize:vertical;
}
.work-edit__row--group,
.work-edit__row--group-create{
  padding:18px;
  border:1px solid #e5e7eb;
  border-radius:16px;
  background:#fafafa;
}

@media (max-width: 768px){
  .work-group-block__head,
  .work-group-page__header{
    flex-direction:column;
  }

  .work-group-page__cover{
    width:100%;
  }

  .work-edit__grid--2{
    grid-template-columns:1fr;
  }
}

/* Front work groups management */
.smysly-groups-page{
  margin:24px 0 40px;
}
.smysly-groups-layout{
  display:grid;
  grid-template-columns:minmax(320px, 390px) minmax(0, 1fr);
  gap:24px;
  align-items:start;
}
.smysly-groups-panel{
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:20px;
  padding:20px;
  box-shadow:0 8px 24px rgba(15,23,42,.04);
}
.smysly-groups-panel + .smysly-groups-panel{ margin-top:20px; }
.smysly-groups-panel__head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin-bottom:16px;
}
.smysly-groups-panel__head h2{
  margin:0;
  font-size:22px;
}
.smysly-groups-counter,
.smysly-groups-summary,
.smysly-groups-badge{
  display:inline-flex;
  align-items:center;
  border-radius:999px;
  padding:6px 10px;
  font-size:13px;
  line-height:1;
  background:#f3f4f6;
  color:#111827;
}
.smysly-groups-badge--muted{ color:#6b7280; }
.smysly-groups-alert{
  border-radius:16px;
  padding:14px 16px;
  margin-bottom:16px;
  font-weight:600;
}
.smysly-groups-alert--success{ background:#ecfdf5; color:#166534; border:1px solid #bbf7d0; }
.smysly-groups-alert--error{ background:#fef2f2; color:#991b1b; border:1px solid #fecaca; }
.smysly-groups-empty{ color:#6b7280; margin:0; }
.smysly-groups-list{ display:grid; gap:14px; }
.smysly-groups-card{
  border:1px solid #e5e7eb;
  border-radius:16px;
  padding:16px;
  background:#fafafa;
}
.smysly-groups-card.is-active{ border-color:#111827; background:#fff; }
.smysly-groups-card__meta,
.smysly-groups-card__actions,
.smysly-group-form__actions,
.smysly-group-items-tools,
.smysly-group-items-tools__actions,
.smysly-row-sort-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
}
.smysly-groups-card__title{ margin:10px 0 6px; font-size:18px; }
.smysly-groups-card__sub{ color:#6b7280; font-size:14px; margin-bottom:12px; }
.smysly-group-form__label{
  display:block;
  margin:0 0 8px;
  font-weight:600;
}
.smysly-group-form__input,
.smysly-group-form__select,
.smysly-group-form__textarea,
.smysly-group-order-input{
  width:100%;
  border:1px solid #d1d5db;
  border-radius:12px;
  padding:12px 14px;
  background:#fff;
  box-sizing:border-box;
}
.smysly-group-form__textarea{ min-height:130px; resize:vertical; }
.smysly-group-form__grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:12px;
  margin:14px 0;
}
.smysly-group-form__actions{ margin-top:16px; }
.smysly-group-form__actions--spaced{ justify-content:space-between; }
.smysly-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:0 14px;
  border-radius:12px;
  text-decoration:none;
  border:1px solid transparent;
  cursor:pointer;
}
.smysly-btn--primary{ background:#111827; color:#fff; }
.smysly-btn--ghost{ background:#fff; color:#111827; border-color:#d1d5db; }
.smysly-btn--danger{ background:#7f1d1d; color:#fff; }
.smysly-btn--small{ min-height:34px; padding:0 12px; font-size:14px; }
.smysly-groups-link{ color:#111827; text-decoration:none; font-weight:600; }
.smysly-group-items-tools{ justify-content:space-between; margin-bottom:16px; }
.smysly-group-items-tools__hint{ color:#6b7280; max-width:720px; }
.smysly-group-items-table-wrap{
  overflow-x:auto;
  overflow-y:hidden;
  -webkit-overflow-scrolling:touch;
  border:1px solid #e5e7eb;
  border-radius:16px;
}
.smysly-group-items-table{
  width:100%;
  min-width:980px;
  border-collapse:collapse;
  table-layout:fixed;
}
.smysly-group-items-table th,
.smysly-group-items-table td{
  padding:14px 16px;
  border-bottom:1px solid #f1f5f9;
  vertical-align:middle;
  font-size:14px;
}
.smysly-group-items-table thead th{
  background:#f8fafc;
  text-align:left;
  font-size:13px;
  white-space:nowrap;
}
.smysly-group-items-table tr.is-selected{ background:#fafafa; }
.smysly-group-items-table th:nth-child(1),
.smysly-group-items-table td:nth-child(1){ width:56px; }
.smysly-group-items-table th:nth-child(2),
.smysly-group-items-table td:nth-child(2){ width:320px; }
.smysly-group-items-table th:nth-child(3),
.smysly-group-items-table td:nth-child(3){ width:130px; }
.smysly-group-items-table th:nth-child(4),
.smysly-group-items-table td:nth-child(4){ width:150px; }
.smysly-group-items-table th:nth-child(5),
.smysly-group-items-table td:nth-child(5),
.smysly-group-items-table th:nth-child(6),
.smysly-group-items-table td:nth-child(6){ width:96px; }
.smysly-group-items-table th:nth-child(7),
.smysly-group-items-table td:nth-child(7){ width:88px; }
.smysly-work-row-title{
  white-space:normal;
  word-break:break-word;
  font-weight:600;
  margin-bottom:4px;
}
.smysly-work-row-link{ font-size:13px; color:#6b7280; text-decoration:none; }
.smysly-group-order-input{
  width:100%;
  min-width:0;
  max-width:88px;
}

@media (max-width: 900px){
  .smysly-group-items-table-wrap{ overflow-x:auto; }
  .smysly-group-items-table{ min-width:980px; table-layout:fixed; }
}
.smysly-sort-btn{
  width:34px;
  height:34px;
  border-radius:10px;
  border:1px solid #d1d5db;
  background:#fff;
  cursor:pointer;
}
.smysly-group-danger-zone{
  margin-top:16px;
  padding-top:16px;
  border-top:1px solid #e5e7eb;
}

@media (max-width: 980px){
  .smysly-groups-layout{ grid-template-columns:1fr; }
}

@media (max-width: 768px){
  .smysly-group-form__grid{ grid-template-columns:1fr; }
  .smysly-group-items-tools{ align-items:flex-start; }
  .smysly-group-form__actions--spaced{ justify-content:flex-start; }
}

.work-group-block__details,
.work-group-page__details{
  margin-top:16px;
}
.work-group-block__summary,
.work-group-page__summary{
  display:inline-flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  list-style:none;
  border:1px solid #e5e7eb;
  border-radius:12px;
  padding:10px 14px;
  background:#f9fafb;
  font-weight:600;
}
.work-group-block__summary::-webkit-details-marker,
.work-group-page__summary::-webkit-details-marker{
  display:none;
}
.work-group-block__summary::after,
.work-group-page__summary::after{
  content:'▾';
  font-size:12px;
  opacity:.7;
}
.work-group-block__details[open] .work-group-block__summary::after,
.work-group-page__details[open] .work-group-page__summary::after{
  transform:rotate(180deg);
}
.work-group-block__related{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:14px;
  align-items:center;
}
.work-group-block__related-label{
  font-size:14px;
  color:#6b7280;
}
.work-group-block__related-link{
  text-decoration:none;
  border:1px solid #e5e7eb;
  border-radius:999px;
  padding:6px 10px;
  color:inherit;
  background:#fff;
}

.smysly-group-items-table-wrap::-webkit-scrollbar{
  height:8px;
}
.smysly-group-items-table-wrap::-webkit-scrollbar-thumb{
  background:#d1d5db;
  border-radius:999px;
}

.smysly-row-sort-actions{
  flex-direction:column;
  gap:6px;
  align-items:center;
}


/* User profile collections */
.work-groups-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(240px,1fr));
  gap:18px;
}
.work-group-card{
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:18px;
  overflow:hidden;
  box-shadow:0 8px 24px rgba(15,23,42,.04);
}
.work-group-card__link{
  display:block;
  text-decoration:none;
  color:inherit;
  height:100%;
}
.work-group-card__media{
  aspect-ratio: 4 / 3;
  background:#f3f4f6;
  overflow:hidden;
}
.work-groups-grid__image{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.work-group-card__placeholder{
  width:100%;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:20px;
  font-weight:700;
  color:#6b7280;
}
.work-group-card__content{
  padding:16px;
}
.work-group-card__meta{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:center;
  margin-bottom:10px;
}
.work-group-card__count{
  font-size:13px;
  color:#6b7280;
}
.work-group-card__title{
  margin:0 0 8px;
  font-size:18px;
  line-height:1.25;
}
.work-group-card__excerpt{
  color:#4b5563;
  font-size:14px;
  line-height:1.5;
}


/* User profile groups compact block */
.my-works__block--collections{
  margin-top: 26px;
}

.work-groups-grid--compact{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(220px,1fr));
  gap:16px;
}

.work-group-card--compact{
  border:1px solid #ececec;
  border-radius:14px;
  overflow:hidden;
  background:#fff;
  box-shadow:0 2px 10px rgba(0,0,0,.04);
}

.work-group-card--compact .work-group-card__link{
  display:flex;
  flex-direction:column;
  min-height:100%;
}

.work-group-card--compact .work-group-card__media{
  aspect-ratio: 16 / 10;
  background:#f5f5f5;
  overflow:hidden;
}

.work-group-card--compact .work-groups-grid__image{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.work-group-card--compact .work-group-card__placeholder{
  width:100%;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:16px;
  text-align:center;
  font-size:14px;
}

.work-group-card--compact .work-group-card__content{
  padding:12px 14px 14px;
}

.work-group-card--compact .work-group-card__meta{
  margin-bottom:8px;
  gap:8px;
}

.work-group-card--compact .work-group-card__title{
  font-size:16px;
  line-height:1.3;
  margin:0 0 8px;
}

.work-group-card--compact .work-group-card__excerpt{
  font-size:13px;
  line-height:1.45;
  color:#666;
  display:-webkit-box;
  -webkit-line-clamp:3;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

@media (max-width: 640px){
  .work-groups-grid--compact{
    grid-template-columns:1fr;
  }
}

/* Listing performance: lazy recommendation placeholders */
.listing-reco--context{
  clear:both;
  margin:32px 0;
}
.listing-reco--lazy .listing-lazy-placeholder{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:16px;
  min-height:150px;
}
.listing-reco--lazy .listing-lazy-placeholder span{
  display:block;
  min-height:132px;
  border-radius:18px;
  background:linear-gradient(90deg,rgba(0,0,0,.045),rgba(0,0,0,.075),rgba(0,0,0,.045));
}
@media (max-width:767px){
  .listing-reco--lazy .listing-lazy-placeholder{grid-template-columns:1fr;min-height:120px;}
  .listing-reco--lazy .listing-lazy-placeholder span:nth-child(n+2){display:none;}
}

/* Lazy placeholders for single work recommendations */
.portal-reco--lazy .listing-lazy-placeholder{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:16px;
  min-height:150px;
}
.portal-reco--lazy .listing-lazy-placeholder span{
  display:block;
  min-height:130px;
  border-radius:16px;
  background:linear-gradient(90deg,rgba(0,0,0,.04),rgba(0,0,0,.075),rgba(0,0,0,.04));
  background-size:220% 100%;
  animation:smysly-lazy-pulse 1.4s ease-in-out infinite;
}
@media (max-width:767px){
  .portal-reco--lazy .listing-lazy-placeholder{grid-template-columns:1fr;min-height:120px;}
  .portal-reco--lazy .listing-lazy-placeholder span:nth-child(n+2){display:none;}
}
@keyframes smysly-lazy-pulse{
  0%{background-position:0 0;}
  100%{background-position:220% 0;}
}

/* Edit work form: publication-page visual parity */
.work-edit{
  max-width:1120px;
  margin:0 auto 56px;
  padding:0 42px;
  color:#3f4652;
}
.work-edit__head{
  margin:0 0 28px;
}
.work-edit__title{
  margin:0 0 26px;
  font-size:32px;
  line-height:1.2;
  font-weight:500;
  color:#343b46;
}
.work-edit__form{
  display:block;
  max-width:100%;
}
.work-edit__row{
  margin:0 0 28px;
}
.work-edit__label{
  display:block;
  margin:0 0 10px;
  font-size:15px;
  line-height:1.4;
  color:#626b77;
  font-weight:500;
}
.work-edit .req,
.work-edit__label .req{
  color:#d63638;
}
.work-edit__input,
.work-edit__select,
.work-edit textarea{
  width:100%;
  max-width:100%;
  min-height:42px;
  border:1px solid #dcdfe4;
  border-radius:0;
  background:#fff;
  color:#343b46;
  font-size:15px;
  box-shadow:none;
}
.work-edit__select{
  max-width:420px;
}
.work-edit__hint{
  margin-top:7px;
  color:#747d89;
  font-size:13px;
  line-height:1.45;
}
.work-edit .wp-editor-wrap{
  width:100%;
}
.work-edit .wp-editor-container{
  border:1px solid #dcdfe4;
  box-shadow:none;
}
.work-edit .mce-toolbar-grp,
.work-edit .quicktags-toolbar{
  background:#f5f6f7;
  border-bottom:1px solid #dcdfe4;
}
.work-edit__thumb{
  margin:0 0 12px;
}
.work-edit__thumb img{
  display:block;
  max-width:220px;
  height:auto;
  border-radius:8px;
  border:1px solid #e6e8eb;
}
.work-edit__notice{
  margin:0 0 22px;
  padding:14px 16px;
  border-radius:10px;
  font-size:14px;
  line-height:1.45;
}
.work-edit__notice--ok{
  background:#edf8ef;
  border:1px solid #cdebd3;
  color:#236530;
}
.work-edit__notice--err{
  background:#fff1f1;
  border:1px solid #f1cccc;
  color:#9f1d1d;
}
.work-edit__notice--moderation{
  background:#f7f8fa;
  border:1px solid #e5e7eb;
  color:#68717d;
}
.work-edit__actions{
  display:flex;
  align-items:center;
  gap:14px;
  margin-top:34px;
}
.work-edit__btn{
  min-height:44px;
  padding:0 24px;
  border:0;
  border-radius:0;
  background:#f5d51b;
  color:#3a3a3a;
  font-size:15px;
  font-weight:500;
  cursor:pointer;
}
.work-edit__cancel{
  color:#3483aa;
  text-decoration:none;
  font-size:15px;
}
button.work-edit__cancel{
  padding:0;
  border:0;
  background:none;
  font:inherit;
  cursor:pointer;
}
.work-edit__cancel:hover{
  text-decoration:underline;
}

/* Audio upload field */
.smysly-audio-field,
.smysly-audio-upload-box{
  padding:22px 24px;
  border:1px solid #e6e8eb;
  border-radius:14px;
  background:#fff;
}
.smysly-audio-field__label,
.smysly-audio-upload-box h3{
  display:block;
  margin:0 0 10px;
  font-size:17px;
  line-height:1.35;
  color:#4b5563;
  font-weight:500;
}
.smysly-audio-field__hint,
.smysly-audio-upload-box p{
  margin:0 0 18px;
  color:#818995;
  font-size:14px;
  line-height:1.45;
}
.smysly-audio-file{
  display:block;
  margin:0 0 12px;
  color:#5b6470;
}
.smysly-audio-status{
  min-height:20px;
  margin-top:10px;
  font-size:14px;
  color:#68717d;
}
.smysly-audio-status.is-error{
  color:#b42318;
}
.smysly-audio-status.is-success{
  color:#247a3d;
}
.smysly-audio-current,
.smysly-audio-preview{
  margin:14px 0 16px;
}
.smysly-audio-current__label{
  margin:0 0 8px;
  color:#626b77;
  font-size:14px;
  font-weight:500;
}
.smysly-audio-current audio,
.smysly-audio-preview audio,
.smysly-work-audio audio{
  width:100%;
  max-width:100%;
}
.smysly-audio-filename{
  margin-top:8px;
  color:#8a929d;
  font-size:13px;
  word-break:break-word;
}
.smysly-audio-remove-btn{
  margin-top:10px;
  min-height:38px;
  padding:0 16px;
  border:0;
  background:#eef1f5;
  color:#4b5563;
  cursor:pointer;
}
.smysly-audio-upload-btn,
#smysly_audio_upload_button{
  display:none !important;
}
.smysly-work-audio{
  margin:30px 0;
  padding:22px 24px;
  border:1px solid #e6e8eb;
  border-radius:16px;
  background:#fff;
}
.smysly-work-audio__title{
  margin:0 0 14px;
  font-size:20px;
  line-height:1.3;
  color:#343b46;
  font-weight:500;
}
@media (max-width: 767px){
  .work-edit{
    padding:0 18px;
  }
  .work-edit__title{
    font-size:26px;
  }
  .work-edit__actions{
    align-items:flex-start;
    flex-direction:column;
  }
  .smysly-audio-field,
  .smysly-audio-upload-box,
  .smysly-work-audio{
    padding:18px;
  }
}

/* Smysly work groups: polished personal page */
.smysly-page--my-groups .site-container{
  max-width:1180px;
}
.smysly-page--my-groups .entry-content{
  max-width:none;
}
.smysly-groups-page{
  margin:32px 0 56px;
  color:#1f2937;
}
.smysly-groups-hero{
  display:flex;
  justify-content:space-between;
  align-items:flex-end;
  gap:24px;
  padding:28px 30px;
  margin-bottom:24px;
  border:1px solid #ece7df;
  border-radius:28px;
  background:linear-gradient(135deg,#fffaf2 0%,#ffffff 58%,#f8fafc 100%);
  box-shadow:0 18px 45px rgba(15,23,42,.06);
}
.smysly-groups-hero__eyebrow{
  margin-bottom:8px;
  color:#9a6b00;
  font-size:13px;
  font-weight:700;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.smysly-groups-hero h2{
  margin:0 0 10px;
  font-size:32px;
  line-height:1.15;
  color:#111827;
}
.smysly-groups-hero p{
  max-width:720px;
  margin:0;
  color:#6b7280;
  font-size:16px;
  line-height:1.6;
}
.smysly-groups-source-work{
  min-width:260px;
  padding:14px 16px;
  border:1px solid #f2d28a;
  border-radius:18px;
  background:#fff8e6;
}
.smysly-groups-source-work span{
  display:block;
  margin-bottom:4px;
  color:#8a6100;
  font-size:13px;
  font-weight:700;
}
.smysly-groups-source-work strong{
  display:block;
  color:#111827;
  font-size:15px;
  line-height:1.35;
}
.smysly-groups-layout{
  grid-template-columns:minmax(300px, 380px) minmax(0,1fr);
  gap:26px;
}
.smysly-groups-panel{
  border-color:#eceff3;
  border-radius:24px;
  padding:24px;
  box-shadow:0 16px 40px rgba(15,23,42,.055);
}
.smysly-groups-panel__head{
  padding-bottom:14px;
  margin-bottom:18px;
  border-bottom:1px solid #f1f5f9;
}
.smysly-groups-panel__head h2{
  font-size:21px;
  line-height:1.25;
  color:#111827;
}
.smysly-group-form{
  display:grid;
  gap:15px;
}
.smysly-group-form__label{
  margin-bottom:7px;
  color:#374151;
  font-size:14px;
}
.smysly-group-form__input,
.smysly-group-form__select,
.smysly-group-form__textarea,
.smysly-group-order-input{
  min-height:46px;
  border-color:#e2e8f0;
  border-radius:14px;
  color:#111827;
  font-size:15px;
  transition:border-color .18s ease, box-shadow .18s ease;
}
.smysly-group-form__input:focus,
.smysly-group-form__select:focus,
.smysly-group-form__textarea:focus,
.smysly-group-order-input:focus{
  outline:none;
  border-color:#f0b429;
  box-shadow:0 0 0 4px rgba(240,180,41,.16);
}
.smysly-group-form__cover-block{
  padding:16px;
  border:1px dashed #d8dee7;
  border-radius:18px;
  background:#fbfcfe;
}
.smysly-group-form__input--file{
  padding:10px 12px;
  cursor:pointer;
}
.smysly-group-form__hint{
  margin-top:7px;
  color:#6b7280;
  font-size:13px;
}
.smysly-group-form__check{
  display:flex;
  align-items:center;
  gap:8px;
  margin-top:10px;
  color:#4b5563;
  font-size:14px;
}
.smysly-group-cover-preview{
  width:100%;
  max-width:220px;
  margin:0 0 12px;
  overflow:hidden;
  border-radius:16px;
  background:#f3f4f6;
}
.smysly-group-cover-preview img{
  display:block;
  width:100%;
  height:auto;
}
.smysly-btn,
.work-head__edit.smysly-work-group-manage-button{
  font-weight:700;
  transition:transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
}
.smysly-btn:hover,
.work-head__edit.smysly-work-group-manage-button:hover{
  transform:translateY(-1px);
  text-decoration:none;
}
.smysly-btn--primary{
  background:#f5b91f;
  border-color:#f5b91f;
  color:#111827;
  box-shadow:0 10px 22px rgba(245,185,31,.24);
}
.smysly-btn--primary:hover{
  background:#e9ad14;
  border-color:#e9ad14;
}
.smysly-btn--ghost:hover{
  border-color:#9ca3af;
  box-shadow:0 8px 18px rgba(15,23,42,.07);
}
.smysly-groups-card{
  border-color:#edf0f4;
  border-radius:18px;
  background:#fff;
  box-shadow:0 8px 24px rgba(15,23,42,.035);
}
.smysly-groups-card.is-active{
  border-color:#f5b91f;
  box-shadow:0 10px 28px rgba(245,185,31,.16);
}
.smysly-groups-empty{
  padding:16px;
  border:1px solid #edf0f4;
  border-radius:16px;
  background:#fbfcfe;
  line-height:1.55;
}
.smysly-group-items-tools{
  padding:14px 16px;
  border:1px solid #edf0f4;
  border-radius:18px;
  background:#fbfcfe;
}
.smysly-group-items-table-wrap{
  border-radius:18px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.75);
}
.smysly-group-items-table thead th{
  background:#f9fafb;
  color:#4b5563;
  font-weight:700;
}
.smysly-group-items-table tr.is-selected{
  background:#fffaf0;
}
.smysly-sort-btn:hover{
  border-color:#f5b91f;
  background:#fff8e6;
}
.work-head__edit.smysly-work-group-manage-button{
  background:#fff8e6;
  border-color:#f5b91f;
  color:#111827;
}

@media (max-width: 980px){
  .smysly-groups-hero{
    align-items:flex-start;
    flex-direction:column;
  }
  .smysly-groups-source-work{
    width:100%;
    min-width:0;
  }
}

@media (max-width: 640px){
  .smysly-groups-hero,
  .smysly-groups-panel{
    padding:18px;
    border-radius:20px;
  }
  .smysly-groups-hero h2{
    font-size:26px;
  }
  .smysly-groups-card__actions,
  .smysly-group-form__actions{
    align-items:stretch;
    flex-direction:column;
  }
  .smysly-groups-card__actions .smysly-btn,
  .smysly-group-form__actions .smysly-btn{
    width:100%;
  }
}

/* === Public series / cycle / collection page, v2 === */
.smysly-series-page{
  background:#f7f8fa;
  padding:32px 0 56px;
}
.smysly-series-page__wrap{
  width:min(1120px, calc(100% - 32px));
  margin:0 auto;
}
.smysly-series-hero{
  display:grid;
  grid-template-columns:minmax(220px, 340px) minmax(0, 1fr);
  gap:30px;
  align-items:stretch;
  background:#fff;
  border:1px solid #e8ecf1;
  border-radius:28px;
  padding:28px;
  box-shadow:0 18px 45px rgba(15,23,42,.06);
}
.smysly-series-hero__cover{
  border-radius:22px;
  overflow:hidden;
  background:linear-gradient(135deg,#f3f4f6,#fff);
  min-height:260px;
}
.smysly-series-hero__image{
  width:100%;
  height:100%;
  min-height:260px;
  object-fit:cover;
  display:block;
}
.smysly-series-hero__body{
  min-width:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.smysly-series-hero__top{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-bottom:14px;
}
.smysly-series-badge,
.smysly-series-status{
  display:inline-flex;
  align-items:center;
  border-radius:999px;
  padding:7px 12px;
  font-size:13px;
  line-height:1;
}
.smysly-series-badge{
  background:#fff7d6;
  color:#7a5a00;
  font-weight:700;
}
.smysly-series-status{
  background:#f1f5f9;
  color:#475569;
}
.smysly-series-hero__title{
  margin:0;
  font-size:clamp(32px,4vw,56px);
  line-height:1.05;
  letter-spacing:-.035em;
  color:#1f2937;
}
.smysly-series-hero__meta{
  display:flex;
  flex-wrap:wrap;
  gap:10px 18px;
  margin-top:18px;
  color:#64748b;
  font-size:15px;
}
.smysly-series-hero__meta a{
  color:#1683b8;
  text-decoration:none;
}
.smysly-series-hero__description{
  margin-top:18px;
  max-width:720px;
  color:#475569;
  font-size:17px;
  line-height:1.65;
}
.smysly-series-hero__description p{
  margin:0 0 10px;
}
.smysly-series-hero__actions{
  margin-top:22px;
}
.smysly-series-edit{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:10px 16px;
  border-radius:14px;
  background:#f4c430;
  color:#1f2937;
  font-weight:700;
  text-decoration:none;
  box-shadow:0 8px 20px rgba(244,196,48,.22);
}
.smysly-series-edit:hover{
  color:#111827;
  transform:translateY(-1px);
}
.smysly-series-content{
  margin-top:24px;
  background:#fff;
  border:1px solid #e8ecf1;
  border-radius:28px;
  padding:26px;
  box-shadow:0 14px 35px rgba(15,23,42,.045);
}
.smysly-series-content__head{
  display:flex;
  justify-content:space-between;
  align-items:flex-end;
  gap:18px;
  margin-bottom:20px;
  padding-bottom:18px;
  border-bottom:1px solid #eef2f7;
}
.smysly-series-content__title{
  margin:0;
  font-size:30px;
  line-height:1.15;
  color:#1f2937;
}
.smysly-series-content__note{
  margin:0;
  color:#64748b;
  font-size:14px;
}
.smysly-series-list{
  list-style:none;
  counter-reset:series-item;
  margin:0;
  padding:0;
  display:grid;
  gap:18px;
}
.smysly-series-item{
  counter-increment:series-item;
  display:grid;
  grid-template-columns:220px minmax(0, 1fr);
  gap:22px;
  align-items:stretch;
  position:relative;
  border:1px solid #edf0f4;
  border-radius:24px;
  background:#fff;
  padding:16px;
  overflow:hidden;
  transition:box-shadow .18s ease, transform .18s ease, border-color .18s ease;
}
.smysly-series-item:hover{
  transform:translateY(-2px);
  border-color:#dfe5ee;
  box-shadow:0 18px 38px rgba(15,23,42,.07);
}
.smysly-series-item::before{
  content:counter(series-item);
  position:absolute;
  left:14px;
  top:14px;
  z-index:2;
  width:34px;
  height:34px;
  border-radius:999px;
  background:rgba(255,255,255,.92);
  color:#334155;
  font-size:14px;
  font-weight:700;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 8px 20px rgba(15,23,42,.12);
}
.smysly-series-item__media{
  display:block;
  border-radius:18px;
  overflow:hidden;
  background:#f3f4f6;
  min-height:170px;
  text-decoration:none;
}
.smysly-series-item__image{
  width:100%;
  height:100%;
  min-height:170px;
  object-fit:cover;
  display:block;
  transition:transform .25s ease;
}
.smysly-series-item:hover .smysly-series-item__image{
  transform:scale(1.025);
}
.smysly-series-item__placeholder{
  width:100%;
  height:100%;
  min-height:170px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#94a3b8;
  font-size:44px;
  font-weight:700;
}
.smysly-series-item__body{
  min-width:0;
  padding:4px 4px 4px 0;
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.smysly-series-item__meta{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-bottom:9px;
}
.smysly-series-item__meta span{
  display:inline-flex;
  border-radius:999px;
  background:#f8fafc;
  color:#64748b;
  padding:5px 9px;
  font-size:12px;
  line-height:1;
}
.smysly-series-item__title{
  margin:0;
  font-size:24px;
  line-height:1.22;
  color:#1f2937;
}
.smysly-series-item__title a{
  color:inherit;
  text-decoration:none;
}
.smysly-series-item__title a:hover{
  color:#1683b8;
}
.smysly-series-item__excerpt{
  margin-top:12px;
  color:#475569;
  font-size:16px;
  line-height:1.65;
  max-width:760px;
}
.smysly-series-item__excerpt--poem{
  white-space:normal;
}
.smysly-series-item__more{
  margin-top:16px;
  align-self:flex-start;
  color:#1683b8;
  text-decoration:none;
  font-weight:700;
  font-size:14px;
}
.smysly-series-item__more::after{
  content:' →';
}
.smysly-series-empty{
  border:1px dashed #cbd5e1;
  border-radius:20px;
  padding:28px;
  color:#64748b;
  background:#f8fafc;
}
@media (max-width: 860px){
  .smysly-series-hero{
    grid-template-columns:1fr;
    padding:18px;
    border-radius:22px;
  }
  .smysly-series-hero__cover,
  .smysly-series-hero__image{
    min-height:220px;
  }
  .smysly-series-content{
    padding:18px;
    border-radius:22px;
  }
  .smysly-series-content__head{
    display:block;
  }
  .smysly-series-content__note{
    margin-top:8px;
  }
  .smysly-series-item{
    grid-template-columns:150px minmax(0, 1fr);
    gap:16px;
  }
  .smysly-series-item__media,
  .smysly-series-item__image,
  .smysly-series-item__placeholder{
    min-height:150px;
  }
  .smysly-series-item__title{
    font-size:20px;
  }
}
@media (max-width: 620px){
  .smysly-series-page{
    padding:18px 0 36px;
  }
  .smysly-series-page__wrap{
    width:min(100% - 20px, 1120px);
  }
  .smysly-series-item{
    grid-template-columns:1fr;
    padding:12px;
    border-radius:20px;
  }
  .smysly-series-item__media,
  .smysly-series-item__image,
  .smysly-series-item__placeholder{
    min-height:220px;
  }
  .smysly-series-item__body{
    padding:0 4px 4px;
  }
  .smysly-series-content__title{
    font-size:25px;
  }
}


/* Public work meta: views + age rating */
.smysly-work-public-meta{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
  margin:18px 0 8px;
  color:#6b7280;
  font-size:14px;
  line-height:1.4;
}
.smysly-work-public-meta__item{
  display:inline-flex;
  align-items:center;
  gap:6px;
  border:1px solid rgba(17,24,39,.10);
  background:rgba(17,24,39,.03);
  border-radius:999px;
  padding:4px 9px;
}
.smysly-work-public-meta__item--age{
  font-size:13px;
  color:#9ca3af;
  background:transparent;
}
.smysly-age-rating-field{
  margin:16px 0;
}
.smysly-age-rating-field__label{
  display:block;
  margin:0 0 7px;
  font-weight:600;
}
.smysly-age-rating-field__select{
  width:100%;
  max-width:260px;
}
.smysly-age-rating-field__hint{
  margin-top:6px;
  color:#6b7280;
  font-size:13px;
  line-height:1.4;
}

/* Work single/overlay header polish */
.single-work .work-head{
  width:100%;
  max-width:100%;
  box-sizing:border-box;
}
.single-work .work-head__title{
  max-width:920px;
  margin-bottom:14px;
  overflow-wrap:anywhere;
}
.single-work .work-head__bar{
  display:flex;
  align-items:flex-start;
  flex-direction:column;
  justify-content:flex-start;
  gap:14px;
  width:100%;
  min-width:0;
}
.single-work .work-head__author{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:12px 16px;
  width:100%;
  min-width:0;
}
.single-work .work-head__author-link{
  flex:0 1 auto;
  min-width:0;
  max-width:100%;
}
.single-work .work-head__actions{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  flex-wrap:wrap;
  gap:10px;
  width:100%;
  min-width:0;
}
.single-work .work-actions{
  display:inline-flex;
  align-items:center;
  flex:0 0 auto;
}
.single-work .work-head__edit,
.single-work .work-head__edit.smysly-work-group-manage-button,
.single-work .portal-work-delete-btn,
.single-work .author-subscribe__btn,
.single-work .work-head__report,
.single-work .smysly-donate-btn,
.single-work .work-like,
.single-work .smysly-btn.smysly-btn-message{
  min-height:42px;
  box-sizing:border-box;
  border-radius:14px;
  padding:10px 16px;
  font-size:15px;
  line-height:1.15;
  white-space:nowrap;
}
.single-work .smysly-btn.smysly-btn-message{
  margin-top:0;
  border:0;
  color:#fff;
}
.single-work .work-head__edit,
.single-work .portal-work-delete-btn,
.single-work .author-subscribe__btn,
.single-work .work-head__report,
.single-work .work-like{
  display:inline-flex;
  align-items:center;
  justify-content:center;
}
.single-work .author-subscribe{
  display:inline-flex;
  align-items:center;
  gap:8px;
  flex:0 0 auto;
  min-width:0;
}
.single-work .author-subscribe__count{
  color:#6b7280;
  font-size:15px;
  line-height:1;
}
.single-work .work-head__report{
  width:auto;
  max-width:max-content;
  background:#fff;
}
.single-work .work-like{
  border:1px solid rgba(0,0,0,.08);
  background:#fff;
  min-width:42px;
}
.single-work .work-like[disabled]{
  opacity:.45;
}
.single-work .smysly-donate-btn:disabled{
  background:#6f6f6f;
  color:#fff;
  opacity:.7;
}
.single-work .work-text-image,
.single-work .work-art-image{
  max-width:100%;
}
.single-work .work-text-image img,
.single-work .work-art-image img{
  max-width:100%;
  height:auto;
}
.portal-reco--single{
  clear:both;
  margin-top:30px;
}
.portal-reco--single .portal-reco__title{
  margin:0 0 16px;
  font-size:32px;
  line-height:1.15;
}
.portal-reco--curated .portal-reco__block + .portal-reco__block{
  margin-top:34px;
}

.work-overlay .single-work .work-head{
  margin-top:0;
  padding-right:34px;
}
.work-overlay .single-work .work-head__title{
  font-size:32px;
}
.work-overlay .single-work .work-head__actions{
  gap:9px;
}
.work-overlay .single-work .work-head__edit,
.work-overlay .single-work .work-head__edit.smysly-work-group-manage-button,
.work-overlay .single-work .portal-work-delete-btn,
.work-overlay .single-work .author-subscribe__btn,
.work-overlay .single-work .work-head__report,
.work-overlay .single-work .smysly-donate-btn,
.work-overlay .single-work .work-like,
.work-overlay .single-work .smysly-btn.smysly-btn-message{
  min-height:40px;
  padding:9px 14px;
  font-size:14px;
}

@media (max-width: 640px){
  .single-work .work-head{
    margin-top:10px;
    padding-bottom:16px;
  }
  .single-work .work-head__chips{
    margin-bottom:12px;
  }
  .single-work .work-head__title,
  .work-overlay .single-work .work-head__title{
    font-size:28px;
    line-height:1.18;
    margin-bottom:16px;
  }
  .single-work .work-head__author{
    align-items:flex-start;
    flex-direction:column;
    gap:12px;
  }
  .single-work .work-head__author-link{
    width:100%;
  }
  .single-work .smysly-btn.smysly-btn-message{
    width:auto;
    max-width:100%;
  }
  .single-work .work-head__actions{
    gap:8px;
  }
  .single-work .work-head__edit,
  .single-work .work-head__edit.smysly-work-group-manage-button,
  .single-work .portal-work-delete-btn,
  .single-work .author-subscribe__btn,
  .single-work .work-head__report,
  .single-work .smysly-donate-btn,
  .single-work .work-like{
    min-height:38px;
    padding:8px 12px;
    border-radius:13px;
    font-size:14px;
  }
  .single-work .smysly-donate-btn{
    max-width:100%;
  }
  .single-work .work-head__name{
    max-width:calc(100vw - 120px);
  }
  .work-overlay .single-work .work-head{
    padding-right:30px;
  }
  .portal-reco--single .portal-reco__title{
    font-size:30px;
  }
}

@media (max-width: 420px){
  .single-work .work-head__title,
  .work-overlay .single-work .work-head__title{
    font-size:25px;
  }
  .single-work .work-head__actions > *,
  .single-work .work-actions,
  .single-work .author-subscribe{
    max-width:100%;
  }
  .single-work .work-head__edit.smysly-work-group-manage-button{
    flex:1 1 auto;
  }
  .single-work .smysly-donate-btn{
    white-space:normal;
  }
}


.work-overlay .single-work .smysly-share,
.single-work .smysly-share{
  clear:both;
  display:block;
  width:100%;
  max-width:100%;
  box-sizing:border-box;
  margin:20px 0 28px;
  padding:14px 0 16px;
  border-top:1px solid rgba(0,0,0,.08);
  border-bottom:1px solid rgba(0,0,0,.08);
}
.work-overlay .single-work .smysly-share__label,
.single-work .smysly-share__label{
  display:block;
  margin:0 0 10px;
  font-size:17px;
  line-height:1.25;
  font-weight:600;
  color:#222;
}
.work-overlay .single-work .smysly-share__buttons,
.single-work .smysly-share__buttons{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:8px;
  max-width:100%;
  min-width:0;
}
.work-overlay .single-work .smysly-share__btn,
.single-work .smysly-share__btn,
.work-overlay .single-work .smysly-share__copy,
.single-work .smysly-share__copy{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-sizing:border-box;
  min-width:38px;
  width:38px;
  height:38px;
  min-height:38px;
  padding:0;
  border:1px solid rgba(0,0,0,.08);
  border-radius:11px;
  box-shadow:0 2px 8px rgba(0,0,0,.06);
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
  cursor:pointer;
  appearance:none;
  -webkit-appearance:none;
}
.work-overlay .single-work .smysly-share__btn--vk,
.single-work .smysly-share__btn--vk{ background:#0077ff !important; color:#fff !important; }
.work-overlay .single-work .smysly-share__btn--telegram,
.single-work .smysly-share__btn--telegram{ background:#2aabee !important; color:#fff !important; }
.work-overlay .single-work .smysly-share__btn--whatsapp,
.single-work .smysly-share__btn--whatsapp{ background:#25d366 !important; color:#fff !important; }
.work-overlay .single-work .smysly-share__btn--max,
.single-work .smysly-share__btn--max{ background:linear-gradient(135deg,#8b5cf6 0%,#4f46e5 55%,#06b6d4 100%) !important; color:#fff !important; }
.work-overlay .single-work .smysly-share__copy,
.single-work .smysly-share__copy{
  width:auto;
  min-width:38px;
  padding:0 12px;
  background:#fff !important;
  color:#222 !important;
  font-size:13px;
  line-height:1.15;
  font-weight:600;
  font-family:inherit;
}
.work-overlay .single-work .smysly-share__copy-text,
.single-work .smysly-share__copy-text{
  display:inline-block;
  margin-left:7px;
  white-space:nowrap;
}
.work-overlay .single-work .smysly-share__icon,
.single-work .smysly-share__icon{
  display:block;
  width:19px;
  height:19px;
  flex:0 0 auto;
}
.work-overlay .single-work .smysly-share__btn svg,
.single-work .smysly-share__btn svg,
.work-overlay .single-work .smysly-share__copy svg,
.single-work .smysly-share__copy svg{
  display:block;
  width:19px;
  height:19px;
}
.work-overlay .single-work .smysly-share__btn svg *,
.single-work .smysly-share__btn svg *,
.work-overlay .single-work .smysly-share__copy svg *,
.single-work .smysly-share__copy svg *{
  fill:currentColor !important;
  stroke:currentColor !important;
}
.work-overlay .single-work .smysly-share__max-mark,
.single-work .smysly-share__max-mark{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:24px;
  height:24px;
  color:#fff;
  font:800 9px/1 Arial, Helvetica, sans-serif;
  letter-spacing:-.5px;
  text-transform:uppercase;
}

@media (max-width:520px){
  .work-overlay .single-work .smysly-share,
  .single-work .smysly-share{
    margin:18px 0 26px;
    padding:12px 0 14px;
  }
  .work-overlay .single-work .smysly-share__buttons,
  .single-work .smysly-share__buttons{
    gap:7px;
  }
  .work-overlay .single-work .smysly-share__btn,
  .single-work .smysly-share__btn,
  .work-overlay .single-work .smysly-share__copy,
  .single-work .smysly-share__copy{
    width:36px;
    min-width:36px;
    height:36px;
    min-height:36px;
    border-radius:10px;
  }
  .work-overlay .single-work .smysly-share__copy,
  .single-work .smysly-share__copy{
    padding:0;
  }
  .work-overlay .single-work .smysly-share__copy-text,
  .single-work .smysly-share__copy-text{
    display:none;
  }
}

/* Work header/meta final mobile layout */
.smysly-work-public-meta__item--report{
  appearance:none;
  -webkit-appearance:none;
  cursor:pointer;
  font:inherit;
  color:#6b7280;
  background:#fff;
}
.smysly-work-public-meta__item--report:hover,
.smysly-work-public-meta__item--report:focus{
  color:#374151;
  border-color:rgba(17,24,39,.18);
  background:rgba(17,24,39,.04);
}

@media (max-width:640px){
  .work-overlay .single-work .work-head__author{
    flex-direction:row;
    align-items:center;
    flex-wrap:nowrap;
    gap:10px;
  }
  .work-overlay .single-work .work-head__author-link{
    width:auto;
    flex:1 1 auto;
    min-width:0;
  }
  .work-overlay .single-work .smysly-btn.smysly-btn-message{
    flex:0 0 auto;
    min-height:36px;
    padding:8px 12px;
    border-radius:12px;
    font-size:13px;
    line-height:1.1;
  }
  .work-overlay .single-work .work-head__name{
    max-width:100%;
  }
}

@media (max-width:380px){
  .work-overlay .single-work .smysly-btn.smysly-btn-message{
    padding:8px 10px;
    font-size:12px;
  }
}

/* Work header mobile layout fix: author/contact/social actions */
.single-work .work-head__social{
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  flex-wrap:nowrap;
  gap:8px;
  min-width:0;
  max-width:100%;
}
.single-work .work-head__social .author-subscribe,
.single-work .work-head__social .work-like{
  flex:0 0 auto;
}
.single-work .work-head__social .work-like{
  gap:5px;
}

@media (max-width:640px){
  .single-work .work-head__bar{
    gap:12px;
  }
  .single-work .work-head__author,
  .work-overlay .single-work .work-head__author{
    flex-direction:row;
    align-items:center;
    flex-wrap:nowrap;
    gap:10px;
  }
  .single-work .work-head__author-link,
  .work-overlay .single-work .work-head__author-link{
    width:auto;
    flex:1 1 auto;
    min-width:0;
    max-width:none;
  }
  .single-work .work-head__who{
    min-width:0;
  }
  .single-work .work-head__name,
  .work-overlay .single-work .work-head__name{
    max-width:100%;
  }
  .single-work .smysly-btn.smysly-btn-message,
  .work-overlay .single-work .smysly-btn.smysly-btn-message{
    flex:0 0 auto;
    min-height:36px;
    padding:8px 11px;
    border-radius:12px;
    font-size:13px;
    line-height:1.1;
    white-space:nowrap;
  }
  .single-work .work-head__actions,
  .work-overlay .single-work .work-head__actions{
    align-items:center;
    gap:8px;
  }
  .single-work .work-head__social,
  .work-overlay .single-work .work-head__social{
    order:10;
    display:inline-flex;
    align-items:center;
    flex-wrap:nowrap;
    gap:7px;
    flex:0 0 auto;
    max-width:100%;
  }
  .single-work .work-head__social .author-subscribe,
  .work-overlay .single-work .work-head__social .author-subscribe{
    display:inline-flex;
    align-items:center;
    gap:6px;
  }
  .single-work .work-head__social .author-subscribe__btn,
  .work-overlay .single-work .work-head__social .author-subscribe__btn,
  .single-work .work-head__social .work-like,
  .work-overlay .single-work .work-head__social .work-like{
    min-height:36px;
    padding:7px 10px;
    border-radius:12px;
    font-size:14px;
    line-height:1.1;
  }
  .single-work .work-head__social .work-like,
  .work-overlay .single-work .work-head__social .work-like{
    padding-left:8px;
    padding-right:8px;
    border-color:transparent;
  }
  .single-work .work-head__social .author-subscribe__count,
  .work-overlay .single-work .work-head__social .author-subscribe__count,
  .single-work .work-head__social .like-count,
  .work-overlay .single-work .work-head__social .like-count{
    font-size:14px;
    color:#6b7280;
  }
  .single-work .work-head__actions > .smysly-donate-btn,
  .work-overlay .single-work .work-head__actions > .smysly-donate-btn{
    order:20;
  }
  .single-work .work-head__edit,
  .single-work .work-head__edit.smysly-work-group-manage-button,
  .single-work .work-actions,
  .work-overlay .single-work .work-head__edit,
  .work-overlay .single-work .work-head__edit.smysly-work-group-manage-button,
  .work-overlay .single-work .work-actions{
    order:1;
  }
  .smysly-work-public-meta{
    align-items:center;
    gap:8px;
    margin:16px 0 10px;
  }
  .smysly-work-public-meta__item,
  .smysly-work-public-meta__item--report{
    min-height:34px;
    padding:6px 11px;
    font-size:14px;
    line-height:1.1;
  }
}

@media (max-width:370px){
  .single-work .smysly-btn.smysly-btn-message,
  .work-overlay .single-work .smysly-btn.smysly-btn-message{
    padding-left:9px;
    padding-right:9px;
    font-size:12px;
  }
  .single-work .work-head__social .author-subscribe__btn,
  .work-overlay .single-work .work-head__social .author-subscribe__btn{
    padding-left:9px;
    padding-right:9px;
  }
}

/* Invisible 1px marker used only for reliable end-of-work reading goals. */
.smysly-read-end-marker{
  display:block;
  width:100%;
  height:1px;
  margin:0;
  padding:0;
  pointer-events:none;
}

/* Structured metadata for visual works + taxonomy fields in /edit-work/. */
.work-edit .smysly-art-tax-select{
  width:100%;
  max-width:640px;
  min-height:190px;
  padding:8px 10px;
  border:1px solid #dcdfe4;
  background:#fff;
  color:#343b46;
}
.work-edit .smysly-art-tax-select option{
  padding:4px 6px;
}
.work-edit .smysly-art-tax-counter{
  margin-top:6px;
  color:#66717d;
  font-size:12px;
  line-height:1.4;
}
.single-work .work-art-image{
  margin:0 0 18px;
}
.single-work .work-art-image__caption{
  margin-top:9px;
  color:#6d7580;
  font-size:13px;
  line-height:1.5;
}
.single-work .work-art-meta{
  display:grid;
  gap:8px;
  margin:16px 0 24px;
  padding:14px 16px;
  border:1px solid #e7e9ed;
  background:#fafbfc;
}
.single-work .work-art-meta__row{
  display:grid;
  grid-template-columns:minmax(130px, 180px) 1fr;
  gap:12px;
  margin:0;
}
.single-work .work-art-meta__label,
.single-work .work-art-meta__values{
  margin:0;
}
.single-work .work-art-meta__label{
  color:#69727e;
  font-weight:500;
}
.single-work .work-art-meta__values a{
  color:inherit;
  text-decoration:underline;
  text-underline-offset:2px;
}
@media (max-width:640px){
  .single-work .work-art-meta__row{
    grid-template-columns:1fr;
    gap:3px;
  }
}

.work-edit .smysly-art-tax-search{
  display:block;
  width:100%;
  max-width:640px;
  margin:0 0 7px;
  padding:8px 10px;
  border:1px solid #d9dde3;
  border-radius:4px;
  background:#fff;
  color:#343b46;
  box-sizing:border-box;
}

/* Valid sibling links: the work opens across the card, author opens separately. */
.work-card__shell{position:relative;min-width:0;}
.work-card .work-card__shell > .work-card__primary-link{position:absolute;inset:0;z-index:1;display:block;width:auto;height:auto;}
.work-card__primary-link:focus-visible{outline:2px solid #6c4cff;outline-offset:-3px;border-radius:14px;}
.work-card__author-name,.work-card__hover-name{position:relative;z-index:3;pointer-events:auto;}
.work-card .work-card__author{flex:1 1 auto;min-width:0;gap:8px;}
.work-card .work-card__date{flex:0 0 auto;}
.work-card .work-card__meta{gap:10px;}
.work-card__author-name-text{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

/* Adapt to the actual card width, including desktop promotion columns. */
.work-card__shell{container-name:smysly-work-card;container-type:inline-size;}
@container smysly-work-card (max-width:310px){
  .work-card .work-card__shell .work-card__meta{
    flex-direction:column;
    align-items:stretch;
    gap:5px;
  }
  .work-card .work-card__shell .work-card__meta .work-card__author{
    flex:0 1 auto;
    width:100%;
    overflow:visible;
  }
  .work-card .work-card__shell .work-card__meta .work-card__author-name{
    display:flex;
    align-items:center;
    min-width:0;
    max-width:100%;
    white-space:normal;
  }
  .work-card .work-card__shell .work-card__meta .work-card__author-name-text{
    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:2;
    min-width:0;
    white-space:normal;
    overflow-wrap:anywhere;
    line-height:1.25;
    overflow:hidden;
  }
  .work-card .work-card__shell .work-card__meta .work-card__date{
    align-self:flex-start;
    margin-left:40px;
    font-size:12px;
    line-height:1.2;
  }
  .work-card .work-card__shell .work-card__author-pro{flex-shrink:0;}
}
