/* Editor dashboard: plain and functional, in the magazine's fonts, black and white. */
:root {
  --serif: "Times New Roman", Times, serif;
  --sans: "DM Sans", "Helvetica Neue", Arial, sans-serif;
  --line: #d9d9d9;
  --muted: #666;
}
* { box-sizing: border-box; }
html { background: #fff; color: #000; }
body { margin: 0; font-family: var(--sans); font-size: 15px; line-height: 1.4; }
a { color: inherit; }
h1, h2 { font-family: var(--serif); font-weight: 400; margin: 0 0 12px; }
h1 { font-size: 32px; line-height: 1.1; }
h2 { font-size: 22px; line-height: 1.2; }
p { margin: 0 0 12px; }
.label { font-family: var(--sans); font-size: 12px; font-weight: 500; letter-spacing: 0.02em; text-transform: uppercase; }
.muted { color: var(--muted); }

.top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 20px; border-bottom: 1px solid #000; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { height: 22px; width: auto; }
.account { display: flex; align-items: center; gap: 20px; margin: 0; }
.account a { text-decoration: none; }
.account a:hover { text-decoration: underline; }
.account form { margin: 0; }

main { padding: 32px 20px 64px; } /* full window width (owner's request) */
.narrow { max-width: 420px; }
.stack { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }
input[type=email] { font: inherit; padding: 10px 12px; border: 1px solid #000; border-radius: 0; }
button { font: inherit; cursor: pointer; background: none; border: 1px solid #000; padding: 6px 12px; }
.button { display: inline-block; background: #000; color: #fff; padding: 12px 16px; text-decoration: none; }
.button:hover { background: #333; }
.error { color: #b00020; }
.notice { border: 1px solid #000; padding: 12px 16px; margin-bottom: 24px; }


.bar { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 24px; }
.bar h1 { margin: 0; }
.topic { color: var(--muted); }
.crumbs { margin-bottom: 8px; color: var(--muted); }
.meta { margin: -12px 0 24px; color: var(--muted); }
.sub { margin-top: 48px; }
.nowrap { white-space: nowrap; }

.status { font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.02em; }
.status--published { color: #000; }
.status--draft, .status--coming { color: var(--muted); }
.status--scheduled { color: #000; }
[hidden] { display: none !important; }

.actions { text-align: right; white-space: nowrap; }
.num { width: 48px; white-space: nowrap; }
.handle { cursor: grab; color: var(--muted); margin-right: 8px; letter-spacing: -2px; }
tr[draggable] { cursor: grab; }
tr.dragging { opacity: 0.4; }
.small-link { font-size: 13px; margin-right: 4px; }
.inline-form { display: flex; gap: 8px; margin: 8px 0 32px; max-width: 520px; }
.inline-form input { flex: 1; font: inherit; padding: 10px 12px; border: 1px solid #000; border-radius: 0; }

/* Issues list: each issue opens to show its articles. */
.issue__row { display: grid; grid-template-columns: 28px 56px 1fr 140px 90px 80px; align-items: center; gap: 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.issue__row--head { font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.02em; border-bottom-color: #000; padding: 8px 0; }
.issue summary { cursor: pointer; list-style: none; }
.issue summary::-webkit-details-marker { display: none; }
.issue__arrow::before { content: ""; display: inline-block; width: 8px; height: 8px; border-right: 1.5px solid #000; border-bottom: 1.5px solid #000; transform: rotate(-45deg); transition: transform 0.15s; margin-left: 4px; }
.issue[open] .issue__arrow::before { transform: rotate(45deg); }
.issue summary:hover { background: #f6f6f6; }
.issue__articles { padding: 4px 0 24px 36px; border-bottom: 1px solid #000; }
.issue__articles th { border-bottom-color: var(--line); }
.actions form { display: inline; margin-left: 8px; }
.actions button { font-size: 13px; padding: 4px 10px; }
.actions button:disabled { color: var(--muted); border-color: var(--line); cursor: not-allowed; }
.actions .danger { color: #c4001a; border-color: #c4001a; }
.actions .danger:hover { background: #c4001a; color: #fff; }

.upload { border: 1px dashed #000; padding: 20px; margin-bottom: 32px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.upload__pick { flex: 1; display: flex; flex-direction: column; gap: 8px; cursor: pointer; min-width: 260px; }
.upload__pick input { font: inherit; }
.upload__results { flex-basis: 100%; margin: 0; padding-left: 20px; }
.upload__results li { padding: 4px 0; }
.upload__results .error { color: #b00020; }
.upload__results ul { margin: 4px 0; color: var(--muted); }
.notes { margin-top: 4px; font-size: 13px; }
.notes summary { cursor: pointer; color: #9a5b00; }
.notes ul { margin: 4px 0 0; padding-left: 18px; color: var(--muted); }

.form { display: flex; flex-direction: column; gap: 20px; max-width: 420px; margin-top: 24px; }
.form label { display: flex; flex-direction: column; gap: 6px; }
.form textarea { font: inherit; padding: 10px 12px; border: 1px solid #000; border-radius: 0; resize: vertical; }
.form input, .form select { font: inherit; padding: 10px 12px; border: 1px solid #000; border-radius: 0; background: #fff; }
.field { display: flex; flex-direction: column; gap: 6px; }
.cover-field { display: flex; gap: 16px; align-items: flex-start; }
.cover-field__preview { flex: none; width: 110px; aspect-ratio: 220 / 264; background: #e6e6e6; }
.cover-field__preview img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cover-field__controls { display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.cover-field__controls input[type=file] { font: inherit; border: 0; padding: 0; }
.form .check { flex-direction: row; align-items: center; gap: 8px; }
.form__buttons { display: flex; align-items: center; gap: 20px; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 8px 12px 8px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.02em; border-bottom-color: #000; }

@media (max-width: 599px) {
  .top { flex-wrap: wrap; }
  .account .muted { display: none; }
  table { font-size: 14px; }
  .bar { flex-wrap: wrap; }
  .issue__row { grid-template-columns: 20px 32px 1fr 80px 40px; }
  .issue__row > :nth-child(6) { display: none; }
  .issue__articles { padding-left: 0; overflow-x: auto; }
}
