/* Magazines list + shared "mc-" pieces (article picker, make-a-magazine dialog, drag & drop marks) */

/* ---------- grid of issue cards ---------- */
.mg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(236px, 1fr)); gap: 22px; }
.mg-card { position: relative; display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .2s; }
.mg-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: var(--line-2); }
.mg-card.skel-card:hover { transform: none; box-shadow: var(--shadow-1); }
.mg-cover { position: relative; display: block; aspect-ratio: 794 / 1123; background: var(--panel-3); overflow: hidden; }
.mg-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.mg-card:hover .mg-cover img { transform: scale(1.03); }
.mg-cover:focus-visible { outline-offset: -3px; }
.mg-strip { position: absolute; left: 0; right: 0; bottom: 0; height: 7px; background: var(--acc-i, var(--acc)); }
.mg-nocover { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; background: var(--acc-i, var(--acc)); color: #fff; font: 600 22px/1.2 var(--display); }
.mg-pdf { position: absolute; top: 10px; left: 10px; display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: 99px; background: var(--ink); color: var(--bg); font: 700 10.5px/1.4 var(--sans); letter-spacing: .06em; }
.mg-pdf svg { width: 13px; height: 13px; }
.mg-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.mg-top { display: flex; align-items: center; gap: 8px; min-height: 28px; }
.mg-no { font: 700 11px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--acc-i, var(--acc)); }
.mg-date { font-size: 12.5px; color: var(--mute); flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mg-more { margin-right: -6px; }
.mg-title { margin: 0; font: 500 21px/1.15 var(--display); letter-spacing: -.01em; }
.mg-title a { color: var(--ink); text-decoration: none; }
.mg-title a:hover { text-decoration: none; color: var(--acc-2); }
.mg-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.mg-edit { margin-top: auto; padding-top: 6px; }

/* ---------- avatars/thumbs used by pickers ---------- */
.mc-thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex: none; background: var(--panel-3); }
.mc-thumb.none { display: grid; place-items: center; color: var(--mute); border: 1px dashed var(--line-2); background: transparent; }
.mc-thumb.none svg { width: 18px; height: 18px; }
.mc-st { font-size: 11px; padding: 2px 8px; }

/* ---------- article picker ---------- */
.mc-pick { display: flex; flex-direction: column; gap: 10px; }
.mc-pick-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mc-search { position: relative; flex: 1; min-width: 200px; }
.mc-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--mute); pointer-events: none; }
.mc-search .input { padding-left: 36px; }
.mc-pick-list { border: 1px solid var(--line); border-radius: var(--r); max-height: min(50vh, 460px); min-height: 160px; overflow-y: auto; background: var(--panel-2); }
.mc-pick-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.mc-pick-row:last-child { border-bottom: 0; }
.mc-pick-row:hover { background: var(--panel-3); }
.mc-pick-row.on { background: var(--acc-soft); }
.mc-pick-row:focus-visible { outline-offset: -2px; }
.mc-box { width: 20px; height: 20px; flex: none; border-radius: 6px; border: 1.5px solid var(--line-2); display: grid; place-items: center; background: var(--panel); color: var(--acc-ink); transition: background .15s, border-color .15s; }
.mc-box svg { width: 13px; height: 13px; opacity: 0; stroke-width: 3; }
.mc-pick-row.on .mc-box { background: var(--acc); border-color: var(--acc); }
.mc-pick-row.on .mc-box svg { opacity: 1; }
.mc-pick-t { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.35; }
.mc-pick-t b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-pick-t small { color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-order { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: var(--acc); color: var(--acc-ink); font: 700 11.5px/22px var(--sans); text-align: center; }
.mc-pick-empty { padding: 36px; text-align: center; color: var(--mute); }
.mc-pick-foot { font-size: 13px; color: var(--ink-2); font-weight: 600; }

/* ---------- make a magazine dialog ---------- */
.mc-mk { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(260px, 1fr); gap: 22px; align-items: start; }
.mc-mk-meta { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; margin-bottom: 16px; }
.mc-mk-meta .wide { grid-column: 1 / -1; }
.mc-mk-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.mc-mk-list { border: 1px solid var(--line); border-radius: var(--r); background: var(--panel-2); max-height: 44vh; overflow-y: auto; }
.mc-mk-row { position: relative; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-bottom: 1px solid var(--line); background: var(--panel); cursor: grab; }
.mc-mk-row:last-child { border-bottom: 0; }
.mc-mk-row.off { opacity: .5; background: var(--panel-2); }
.mc-mk-row.lead { box-shadow: inset 3px 0 0 var(--acc); }
.mc-mk-t { display: flex; flex-direction: column; flex: 1; min-width: 0; line-height: 1.3; }
.mc-mk-t b { font-weight: 600; font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mc-mk-t small { color: var(--mute); }
.mc-grip { color: var(--mute); display: grid; place-items: center; flex: none; opacity: .7; }
.mc-grip svg { width: 16px; height: 16px; }
.mc-chk { position: relative; display: inline-grid; place-items: center; flex: none; cursor: pointer; }
.mc-chk input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.mc-chk input:checked + .mc-box { background: var(--acc); border-color: var(--acc); }
.mc-chk input:checked + .mc-box svg { opacity: 1; }
.mc-chk input:focus-visible + .mc-box { outline: 2px solid var(--acc); outline-offset: 2px; }
.mc-radio { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--ink-2); cursor: pointer; flex: none; }
.mc-radio input { accent-color: var(--acc); margin: 0; }
.mc-radio input:disabled { opacity: .4; }
.mc-mv { display: inline-flex; flex: none; }
.mc-mk-right { position: sticky; top: 0; display: flex; flex-direction: column; gap: 12px; }
.mc-mk-sum { display: flex; flex-direction: column; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--panel-2); }
.mc-sum-l { display: flex; align-items: center; gap: 8px; font: 700 11px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); margin-bottom: 6px; }
.mc-sum-l em { font-style: normal; background: var(--panel-3); border-radius: 99px; padding: 2px 7px; letter-spacing: 0; color: var(--ink-2); }
.mc-sum-g ol { margin: 0; padding-left: 20px; font-size: 13px; color: var(--ink-2); display: flex; flex-direction: column; gap: 3px; }
.mc-sum-g p { margin: 0; }
.mc-sum-lead { display: flex; gap: 10px; align-items: center; }
.mc-sum-lead b { font: 500 16px/1.25 var(--display); }
.mc-mk-warn { display: flex; flex-direction: column; gap: 8px; }
.mc-mk-warn .banner { font-size: 13px; align-items: flex-start; padding: 10px 12px; }
.mc-mk-warn .banner svg { margin-top: 2px; }
@media (max-width: 760px) {
  .mc-mk { grid-template-columns: 1fr; }
  .mc-mk-right { position: static; }
  .mc-mk-meta { grid-template-columns: 1fr; }
  .mc-mk-row .mc-radio span { display: none; }
  .mc-mk-row { gap: 8px; }
}

/* ---------- drag & drop marks (shared) ---------- */
.dnd-drag { opacity: .4; }
.dnd-before { box-shadow: 0 -3px 0 0 var(--acc); }
.dnd-after { box-shadow: 0 3px 0 0 var(--acc); }
.dnd-over { outline: 2px dashed var(--acc); outline-offset: -3px; background: var(--acc-soft); }
