/* ============================================================
   Newsletter Admin — Fort Weekly Dark Theme
   Industrial editorial: dark base, amber accents, Oswald + JetBrains Mono + Source Serif 4
   ============================================================ */

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Restore list indentation stripped by CSS reset */
ul, ol {
  padding-left: 1.5rem;
}

li {
  padding-left: 0.25rem;
}

:root {
  /* Palette */
  --bg: #111214;
  --bg-deep: #0a0b0d;
  --bg-card: #181a1e;
  --bg-card-alt: #1e2025;
  --bg-input: #15171a;

  --amber: #d4a03c;
  --amber-bright: #e8b94a;
  --amber-dim: #8a6a2a;
  --amber-glow: rgba(212, 160, 60, 0.08);

  --steel: #3a3d44;
  --steel-light: #555860;

  --text: #d8d6d0;
  --text-dim: #8a8a82;
  --text-bright: #f0ece4;

  --rust: #a0522d;
  --green: #5a7a4a;

  --border: #2a2c30;
  --border-light: #222428;

  /* Typography */
  --mono: 'JetBrains Mono', monospace;
  --display: 'Oswald', sans-serif;
  --body: 'Source Serif 4', Georgia, serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2.5rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;

  /* Borders & Shadows */
  --radius-sm: 3px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --radius-xl: 14px;

  --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 16px 50px rgba(0, 0, 0, 0.6);

  /* Transitions */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* Links */
a {
  color: var(--amber);
  text-decoration: none;
  transition: color 0.2s;
}
a:hover {
  color: var(--amber-bright);
}

/* Container */
.container {
  position: relative;
  z-index: 1;
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 24px;
}

.container--wide {
  max-width: 1020px;
}

/* ============================================================
   Page Header
   ============================================================ */
.page-header {
  text-align: center;
  margin-bottom: var(--space-2xl);
  padding-bottom: var(--space-xl);
  position: relative;
}

.page-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: var(--amber);
  margin: 0 auto 32px;
}

.page-header__eyebrow {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber-dim);
  margin-bottom: var(--space-sm);
  display: block;
}

.page-header__title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-bright);
  line-height: 1;
  margin-bottom: var(--space-sm);
}

.page-header__subtitle {
  font-family: var(--body);
  font-style: italic;
  font-size: 1rem;
  color: var(--text-dim);
  max-width: 500px;
  margin: 0 auto;
}

/* ============================================================
   Card
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s var(--ease-out);
}

.card:hover {
  box-shadow: var(--shadow-md);
}

/* ============================================================
   Form Elements
   ============================================================ */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: var(--space-sm);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
input[type="time"],
input[type="datetime-local"],
input[type="url"],
textarea {
  width: 100%;
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem var(--space-md);
  transition: border-color 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out);
  appearance: none;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px var(--amber-glow);
}

input::placeholder,
textarea::placeholder {
  color: var(--steel-light);
  font-style: italic;
}

textarea {
  resize: vertical;
  min-height: 120px;
}

select {
  width: 100%;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--text);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.6rem 2.2rem 0.6rem var(--space-md);
  transition: border-color 0.25s var(--ease-out), box-shadow 0.25s var(--ease-out);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%238a8a82' d='M1.47 1.47a.5.5 0 0 1 .7 0L6 5.29l3.83-3.82a.5.5 0 1 1 .7.7l-4.18 4.18a.5.5 0 0 1-.7 0L1.47 2.17a.5.5 0 0 1 0-.7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
}

select:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px var(--amber-glow);
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 0.75rem 1.8rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.25s var(--ease-out);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn--primary {
  color: var(--bg-deep);
  background: var(--amber);
  border-color: var(--amber);
}

.btn--primary:hover {
  background: var(--amber-bright);
  border-color: var(--amber-bright);
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(212, 160, 60, 0.25);
}

.btn--primary:active {
  transform: translateY(0);
  box-shadow: none;
}

.btn--primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.btn--secondary {
  color: var(--amber);
  background: transparent;
  border-color: var(--amber);
}

.btn--secondary:hover {
  background: rgba(212, 160, 60, 0.08);
}

.btn--ghost {
  color: var(--text-dim);
  background: transparent;
  border-color: transparent;
  padding: 0.5rem 1rem;
}

.btn--ghost:hover {
  color: var(--text);
  background: var(--bg-card-alt);
}

.btn--danger {
  color: var(--text);
  background: var(--rust);
  border-color: var(--rust);
}

.btn--danger:hover {
  background: #b5623d;
  border-color: #b5623d;
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(160, 82, 45, 0.25);
}

.btn--sm {
  padding: 0.45rem 0.9rem;
  font-size: 0.6rem;
}

.btn--lg {
  padding: 0.9rem 2rem;
  font-size: 0.8rem;
}

/* ============================================================
   Form Actions
   ============================================================ */
.form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-top: var(--space-xl);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--border);
}

.form-actions__left,
.form-actions__right {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* ============================================================
   Alerts
   ============================================================ */
.alert {
  font-family: var(--mono);
  font-size: 0.75rem;
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-lg);
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  animation: slideDown 0.3s var(--ease-out);
}

.alert--success {
  color: var(--green);
  background: rgba(90, 122, 74, 0.12);
  border: 1px solid rgba(90, 122, 74, 0.3);
}

.alert--error {
  color: var(--rust);
  background: rgba(160, 82, 45, 0.12);
  border: 1px solid rgba(160, 82, 45, 0.3);
}

.alert__icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
}

/* ============================================================
   Admin Nav
   ============================================================ */
.admin-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) 0;
  margin-bottom: var(--space-xl);
  border-bottom: 1px solid var(--border);
}

.admin-nav__brand {
  font-family: var(--display);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-bright);
}

.admin-nav__links {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.admin-nav__link {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.admin-nav__link:hover {
  color: var(--amber);
  background: rgba(212, 160, 60, 0.06);
  border-color: var(--border);
}

/* ============================================================
   Changelog Output
   ============================================================ */
.changelog-output {
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
  background: var(--bg-base, #0d0d0d);
  color: var(--text, #e8e2d9);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  max-height: 60vh;
  overflow-y: auto;
  margin: 0;
}

/* ============================================================
   Admin Tabs
   ============================================================ */
.admin-tabs {
  display: flex;
  gap: 0;
  margin-bottom: var(--space-xl);
  border-bottom: 1px solid var(--border);
}

.admin-tab {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.65rem 1.4rem;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  margin-bottom: -1px;
}

.admin-tab:hover {
  color: var(--text);
}

.admin-tab--active {
  color: var(--amber);
  border-bottom-color: var(--amber);
}

/* ============================================================
   Login Form
   ============================================================ */
.login-container {
  max-width: 400px;
  margin: var(--space-3xl) auto;
  text-align: center;
}

.login-container .card {
  padding: var(--space-2xl);
}


.vq-modal-fngs {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text);
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  min-height: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  justify-content: center;
}

/* ============================================================
   Section Groups
   ============================================================ */
.entry-list {
  display: flex;
  flex-direction: column;
}

.section-group {
  margin-bottom: var(--space-xl);
}

.section-group--collapsed .section-entries {
  display: none;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px var(--space-lg);
  margin-bottom: var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--amber);
  cursor: pointer;
  user-select: none;
  transition: all 0.2s var(--ease-out);
  position: relative;
}

.section-header:hover {
  background: var(--bg-card-alt);
  box-shadow: var(--shadow-sm);
}

.section-header__chevron {
  font-family: var(--mono);
  font-size: 0.65rem;
  color: var(--text-dim);
  transition: transform 0.2s var(--ease-out);
  display: inline-block;
  width: 14px;
  text-align: center;
}

.section-header__title {
  font-family: var(--display);
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-bright);
  flex: 1;
}

.section-header__count {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  min-width: 28px;
  text-align: center;
}

.section-entries {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  padding-left: var(--space-md);
}

/* ============================================================
   Entry Card
   ============================================================ */
.entry-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-lg);
  transition: all 0.25s var(--ease-out);
  position: relative;
  overflow: hidden;
}

.entry-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--section-accent, var(--amber));
  opacity: 0;
  transition: opacity 0.25s var(--ease-out);
}

.entry-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--amber-dim);
}

.entry-card:hover::before {
  opacity: 1;
}

.entry-card--sectioned::before {
  opacity: 0.8;
}

.entry-card--archived {
  opacity: 0.72;
  filter: saturate(0.5);
  border-style: dashed;
}

.entry-card--archived:hover {
  opacity: 0.92;
  filter: saturate(0.8);
}

.entry-card__meta-item--archived {
  color: var(--amber);
  font-style: italic;
  opacity: 0.7;
}

.entry-card__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-sm);
}

.entry-card__title {
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.3;
  margin-bottom: var(--space-xs);
}

.entry-card__title a {
  color: var(--text-bright);
}

.entry-card__title a:hover {
  color: var(--amber);
}

.entry-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: var(--text-dim);
  margin-bottom: var(--space-sm);
}

.entry-card__meta-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.entry-card__excerpt {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.entry-card__hero {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  filter: brightness(0.85) saturate(0.9);
  transition: filter 0.3s ease;
}

.entry-card:hover .entry-card__hero {
  filter: brightness(0.95) saturate(1);
}

.entry-card__actions {
  display: flex;
  gap: var(--space-sm);
  flex-shrink: 0;
  align-items: center;
}

/* ============================================================
   Section Badge
   ============================================================ */
.section-badge {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-sm);
  border: 1px solid;
  display: inline-block;
}

/* ============================================================
   Section Dropdown
   ============================================================ */
.section-dropdown {
  width: auto;
  min-width: 160px;
  font-size: 0.65rem;
  padding: 0.4rem 2rem 0.4rem 0.5rem;
}

.section-dropdown--modal {
  width: 220px;
  min-width: 220px;
  font-size: 0.7rem;
  padding: 0.5rem 2.3rem 0.5rem 0.6rem;
}

/* ============================================================
   Pagination
   ============================================================ */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
}

.pagination__info {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-right: var(--space-md);
}

.pagination__btn {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 500;
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
}

.pagination__btn:hover:not(.disabled):not(.active) {
  border-color: var(--amber);
  color: var(--amber);
  background: var(--amber-glow);
}

.pagination__btn.active {
  background: var(--amber);
  color: var(--bg-deep);
  border-color: var(--amber);
}

.pagination__btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ============================================================
   Modal
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 13, 0.85);
  backdrop-filter: blur(6px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s var(--ease-out);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  max-width: 620px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  transform: translateY(20px) scale(0.97);
  transition: transform 0.3s var(--ease-spring);
}

.modal-overlay.active .modal {
  transform: translateY(0) scale(1);
}

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--border);
}

.modal__title {
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-bright);
}

.modal__close {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
}

.modal__close:hover {
  color: var(--text);
  background: var(--bg-card-alt);
}

.modal__body {
  padding: var(--space-xl);
}

.modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-sm);
  padding: var(--space-lg) var(--space-xl);
  border-top: 1px solid var(--border);
}

/* ============================================================
   Modal wide variant
   ============================================================ */
.modal--wide {
  max-width: 780px;
}

/* ============================================================
   Edit Entry Form (inside modal)
   ============================================================ */
.edit-form__row {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.edit-form__field {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
}

.edit-form__field--grow {
  flex: 1;
}

.edit-form__field label,
#edit-entry-form label {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* Rich editor inside the edit modal — reuse submit form structure */
#modal-rich-editor .rich-editor__toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: var(--space-sm);
  background: var(--bg-card-alt);
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

#modal-rich-editor .rich-editor__toolbar button {
  font-size: 0.78rem;
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s;
  display: inline-flex;
  align-items: center;
}

#modal-rich-editor .rich-editor__toolbar button:hover,
#modal-rich-editor .rich-editor__toolbar button.active {
  background: var(--border);
}

#modal-rich-editor .rich-editor__toolbar .separator {
  width: 1px;
  background: var(--border);
  margin: 2px 4px;
  align-self: stretch;
}

#modal-rich-editor .rich-editor__content {
  min-height: 140px;
  max-height: 300px;
  overflow-y: auto;
  padding: var(--space-md);
  border: 1px solid var(--border);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  background: var(--bg-input, var(--bg-card-alt));
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
  outline: none;
}

#modal-rich-editor .rich-editor__content:focus {
  border-color: var(--amber);
}

/* Hero upload inside edit modal */
#modal-hero-upload {
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.2s;
}

#modal-hero-upload:hover {
  border-color: var(--amber);
}

#modal-hero-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-xl);
  color: var(--text-dim);
  font-size: 0.85rem;
  text-align: center;
}

.hero-upload__hint {
  font-size: 0.75rem;
  color: var(--text-dim);
  opacity: 0.7;
}

#modal-hero-preview {
  position: relative;
}

#modal-hero-preview img {
  width: 100%;
  aspect-ratio: 5 / 2;
  object-fit: cover;
  display: block;
}

#modal-hero-remove {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: rgba(0,0,0,0.6);
  border: none;
  border-radius: var(--radius-sm);
  color: white;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
}

.edit-submitter-info {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  margin-top: var(--space-sm);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--border);
}

/* ============================================================
   Detail View (legacy, kept for reference)
   ============================================================ */
.detail-view {
  margin-top: var(--space-xl);
}

.detail-view__header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.detail-view__title {
  font-family: var(--display);
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-bright);
  margin-bottom: var(--space-md);
}

.detail-view__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm) var(--space-xl);
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-dim);
}

.detail-view__hero {
  margin-bottom: var(--space-lg);
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
}

.detail-view__hero img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  display: block;
  filter: brightness(0.85) saturate(0.9);
  transition: filter 0.3s ease;
}

.detail-view__hero img:hover {
  filter: brightness(0.95) saturate(1);
}

.detail-view__content {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-xl);
  line-height: 1.8;
  font-size: 1rem;
}

.detail-view__content p {
  margin-bottom: var(--space-md);
}

.detail-view__content img {
  max-width: 100%;
  border-radius: var(--radius-md);
  margin: var(--space-lg) 0;
  filter: brightness(0.9);
}

.detail-view__content a {
  color: var(--amber);
  text-decoration: underline;
  text-decoration-color: rgba(212, 160, 60, 0.3);
  text-underline-offset: 2px;
}

.detail-view__content ol,
.detail-view__content ul {
  padding-left: 2rem !important;
  margin-left: 0 !important;
}

.detail-view__content li {
  margin-left: 0;
  padding-left: 0.5rem;
}

.detail-view__link {
  margin-top: var(--space-lg);
  padding: var(--space-md);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--mono);
  font-size: 0.75rem;
  word-break: break-all;
}

.detail-view__link a {
  color: var(--amber);
}

.detail-view__submitter {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  text-align: center;
}

/* ============================================================
   Empty State
   ============================================================ */
.empty-state {
  text-align: center;
  padding: var(--space-3xl) var(--space-lg);
}

.empty-state__icon {
  font-size: 3rem;
  margin-bottom: var(--space-md);
  opacity: 0.3;
}

.empty-state__title {
  font-family: var(--display);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: var(--space-sm);
}

.empty-state__text {
  font-family: var(--body);
  font-size: 0.95rem;
  color: var(--steel-light);
  font-style: italic;
}

/* ============================================================
   Spinner
   ============================================================ */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--amber);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
}

/* ============================================================
   Animations
   ============================================================ */
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.stagger-children > * {
  opacity: 0;
  animation: slideUp 0.4s var(--ease-out) forwards;
}

.stagger-children > *:nth-child(1) { animation-delay: 0.05s; }
.stagger-children > *:nth-child(2) { animation-delay: 0.1s; }
.stagger-children > *:nth-child(3) { animation-delay: 0.15s; }
.stagger-children > *:nth-child(4) { animation-delay: 0.2s; }
.stagger-children > *:nth-child(5) { animation-delay: 0.25s; }
.stagger-children > *:nth-child(6) { animation-delay: 0.3s; }
.stagger-children > *:nth-child(7) { animation-delay: 0.35s; }
.stagger-children > *:nth-child(8) { animation-delay: 0.4s; }
.stagger-children > *:nth-child(9) { animation-delay: 0.45s; }
.stagger-children > *:nth-child(10) { animation-delay: 0.5s; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .form-row { grid-template-columns: 1fr; }
  .card { padding: var(--space-lg); }
  .form-actions { flex-direction: column; }
  .form-actions__left,
  .form-actions__right {
    width: 100%;
    justify-content: center;
  }
  .entry-card__header {
    flex-direction: column;
  }
  .entry-card__actions {
    align-self: flex-end;
    flex-wrap: wrap;
  }
  .section-dropdown,
  .section-dropdown--modal {
    width: 100%;
    min-width: unset;
  }
  .section-header {
    padding: 12px var(--space-md);
  }
  .section-header__title {
    font-size: 1rem;
  }
  .section-entries {
    padding-left: 0;
  }
  .admin-nav {
    flex-direction: column;
    gap: var(--space-sm);
  }
  .admin-nav__links {
    flex-wrap: wrap;
    justify-content: center;
  }
  .pagination {
    flex-wrap: wrap;
  }
  .detail-view__meta {
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
  }
  .modal {
    margin: var(--space-md);
    max-height: 90vh;
  }
}

@media (max-width: 480px) {
  html { font-size: 15px; }
  .page-header__title { font-size: 1.8rem; }
  .card { padding: var(--space-md); }
  .btn { padding: 0.6rem 1.2rem; font-size: 0.6rem; }
}

@media print {
  body::before { display: none; }
  .card { box-shadow: none; border: 1px solid #333; }
  .btn, .admin-nav, .pagination, .entry-card__actions { display: none; }
}

/* ============================================================
   Newsletter Bar
   ============================================================ */
.newsletter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  margin-bottom: var(--space-lg);
  background: linear-gradient(135deg, var(--bg-input), color-mix(in srgb, var(--bg-input), var(--amber) 8%));
  border: 2px solid var(--amber);
  border-radius: var(--radius-md);
  font-family: var(--mono);
  font-size: 0.8rem;
  box-shadow: 0 2px 8px rgba(212, 160, 60, 0.12);
}

.newsletter-bar__label {
  font-weight: 700;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.85rem;
}

.newsletter-bar__vqs {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.newsletter-bar__vqs-label {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  white-space: nowrap;
}

.newsletter-bar__vqs-input {
  width: 180px;
  font-family: var(--mono);
  font-size: 0.7rem;
  padding: 0.35rem 0.6rem;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
}

.newsletter-bar__vqs-input:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 2px var(--amber-glow);
}

.newsletter-bar__actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.newsletter-bar__status {
  color: var(--text-dim);
}

.newsletter-bar__status--sent {
  color: var(--green);
}

.newsletter-bar__status--error {
  color: var(--rust);
}

/* ============================================================
   Board Layout — full-viewport flex column when dashboard visible
   ============================================================ */
.board-layout {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: none;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}

/* Nav gets horizontal padding since board-layout no longer has it */
.board-layout > .admin-nav {
  padding-left: 24px;
  padding-right: 24px;
  flex-shrink: 0;
  margin-bottom: 0;
}

/* Two-column split fills remaining height */
.board-split {
  flex: 1;
  display: flex;
  min-height: 0;
  overflow: hidden;
}

/* Left: scrollable board pane */
.board-pane {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  padding: var(--space-lg) 24px var(--space-xl);
}

.board-pane::-webkit-scrollbar { width: 6px; }
.board-pane::-webkit-scrollbar-track { background: var(--bg-deep); }
.board-pane::-webkit-scrollbar-thumb { background: var(--steel); border-radius: 3px; }

/* Right: preview pane — hidden until board-split--has-preview */
.preview-pane {
  display: none;
  width: 50%;
  min-width: 420px;
  max-width: 960px;
  flex-shrink: 0;
  flex-direction: column;
  border-left: 1px solid var(--border);
  background: var(--bg-deep);
}

.board-split--has-preview .preview-pane {
  display: flex;
}

/* Preview pane header */
.preview-pane__header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 8px 10px;
  background: var(--bg-card-alt);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.preview-pane__label {
  flex: 1;
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.preview-pane__actions {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-shrink: 0;
}

.preview-pane__close {
  padding: 0.3rem 0.5rem !important;
}

/* Viewport toggle buttons (Desktop / Mobile) */
.preview-viewport-toggle {
  display: flex;
  gap: 2px;
  padding: 2px;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.preview-viewport-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border: none;
  border-radius: 2px;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.preview-viewport-btn:hover {
  color: var(--text);
}

.preview-viewport-btn--active {
  background: var(--bg-card);
  color: var(--amber);
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* Preview viewport fills the pane — JS handles iframe sizing/scaling */
.preview-pane__viewport {
  flex: 1;
  overflow: hidden;
  position: relative;
  min-height: 0;
}

/* Base iframe — JS sets position/size/transform for each mode */
#newsletter-iframe {
  border: none;
  display: block;
  position: absolute;
  top: 0;
  left: 0;
}

/* Mobile mode: scrollable container with 375px frame */
.preview-pane--mobile .preview-pane__viewport {
  overflow-y: scroll; /* always show scrollbar — we're on desktop */
  overflow-x: hidden;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 20px 16px;
  background: #0a0b0d;
}

.preview-pane--mobile .preview-pane__viewport::-webkit-scrollbar { width: 8px; }
.preview-pane--mobile .preview-pane__viewport::-webkit-scrollbar-track { background: #0a0b0d; }
.preview-pane--mobile .preview-pane__viewport::-webkit-scrollbar-thumb { background: var(--steel); border-radius: 4px; }
.preview-pane--mobile .preview-pane__viewport::-webkit-scrollbar-thumb:hover { background: var(--steel-light); }

.preview-pane--mobile #newsletter-iframe {
  position: static;
  width: 375px;
  flex-shrink: 0;
  border-radius: 10px;
  box-shadow: 0 0 0 8px #1c1e24, 0 0 0 9px var(--border), 0 8px 32px rgba(0,0,0,0.6);
}

@media (max-width: 800px) {
  .preview-pane {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: min(90vw, 480px);
    z-index: 200;
    box-shadow: -6px 0 24px rgba(0,0,0,0.6);
  }
}

/* ============================================================
   Board Toolbar (tabs + action buttons)
   ============================================================ */
.board-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--border);
}

.board-tabs {
  display: flex;
  gap: 0;
}

.board-tab {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.6rem 1.2rem;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  margin-bottom: -1px;
}

.board-tab:hover { color: var(--text); }
.board-tab--active {
  color: var(--amber);
  border-bottom-color: var(--amber);
}

.board-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

/* ============================================================
   Kanban Board
   ============================================================ */
.kanban-board {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  min-height: 400px;
  padding-bottom: 24px;
  align-items: flex-start;
  scroll-padding: 16px;
}

.kanban-board::-webkit-scrollbar {
  height: 6px;
}
.kanban-board::-webkit-scrollbar-track {
  background: var(--bg-deep);
}
.kanban-board::-webkit-scrollbar-thumb {
  background: var(--steel);
  border-radius: 3px;
}
.kanban-board::-webkit-scrollbar-thumb:hover {
  background: var(--steel-light);
}

/* ============================================================
   Kanban Lane
   ============================================================ */
.kanban-lane {
  flex: 0 0 270px;
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 160px);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: box-shadow 0.2s var(--ease-out);
}

.kanban-lane__header {
  padding: 10px 14px 9px;
  border-top: 4px solid var(--lane-accent, var(--amber));
  background: var(--bg-card-alt);
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.kanban-lane__label {
  font-family: var(--display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-bright);
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kanban-lane__count {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-sm);
  min-width: 22px;
  text-align: center;
  flex-shrink: 0;
}

.kanban-lane__body {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 80px;
  transition: background 0.15s;
}

.kanban-lane__body::-webkit-scrollbar { width: 4px; }
.kanban-lane__body::-webkit-scrollbar-track { background: transparent; }
.kanban-lane__body::-webkit-scrollbar-thumb { background: var(--steel); border-radius: 2px; }

.kanban-lane--unsorted .kanban-lane__header {
  border-top-color: #6e6860;
  background: color-mix(in srgb, var(--bg-card-alt), #8a7f70 8%);
}

.kanban-lane--unsorted .kanban-lane__label {
  color: #c8c0b4;
}

.kanban-lane--drag-over .kanban-lane__body {
  background: rgba(212, 160, 60, 0.05);
  box-shadow: inset 0 0 0 2px rgba(212, 160, 60, 0.25);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.kanban-lane__empty {
  font-family: var(--mono);
  font-size: 0.6rem;
  color: var(--text-dim);
  text-align: center;
  padding: 20px 12px;
  opacity: 0.5;
  pointer-events: none;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* ============================================================
   Kanban Card
   ============================================================ */
.kanban-card {
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-left: 3px solid var(--card-accent, var(--steel));
  border-radius: var(--radius-sm);
  padding: 10px 12px 10px 10px;
  cursor: grab;
  position: relative;
  transition: box-shadow 0.15s var(--ease-out), border-color 0.15s, transform 0.1s;
  user-select: none;
}

.kanban-card:hover {
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
  border-color: var(--border-light);
  transform: translateY(-1px);
}

.kanban-card:active {
  cursor: grabbing;
}

.kanban-card.is-dragging {
  opacity: 0.35;
  transform: scale(0.97);
  box-shadow: none;
  border-style: dashed;
}

.kanban-card__header {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-bottom: 4px;
}

.kanban-card__drag-handle {
  color: var(--steel-light);
  font-size: 0.8rem;
  line-height: 1;
  cursor: grab;
  flex-shrink: 0;
  margin-top: 2px;
  opacity: 0.4;
  transition: opacity 0.15s;
}
.kanban-card:hover .kanban-card__drag-handle { opacity: 0.8; }

.kanban-card__title {
  font-family: var(--display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-bright);
  line-height: 1.35;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  cursor: pointer;
}
.kanban-card__title:hover { color: var(--amber); }

.kanban-card__meta {
  font-family: var(--mono);
  font-size: 0.58rem;
  color: var(--text-dim);
  letter-spacing: 0.05em;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin-bottom: 4px;
}

.kanban-card__excerpt {
  font-family: var(--body);
  font-size: 0.75rem;
  color: var(--text-dim);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 8px;
}

.kanban-card__footer {
  display: flex;
  gap: 4px;
  justify-content: flex-end;
  margin-top: 2px;
}

.kanban-card__btn {
  font-family: var(--mono);
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.25rem 0.55rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.15s;
}
.kanban-card__btn:hover {
  background: var(--bg-card-alt);
  color: var(--text);
  border-color: var(--steel-light);
}
.kanban-card__btn--danger:hover {
  background: rgba(160, 82, 45, 0.15);
  color: var(--rust);
  border-color: var(--rust);
}

/* Drop indicator line */
.drop-indicator {
  height: 2px;
  background: var(--amber);
  border-radius: 2px;
  margin: 2px 0;
  pointer-events: none;
  box-shadow: 0 0 6px rgba(212, 160, 60, 0.5);
  flex-shrink: 0;
}

/* ============================================================
   Archive View
   ============================================================ */
#archive-view {
  padding: var(--space-md) 0;
}

.archive-toolbar {
  margin-bottom: var(--space-lg);
  position: relative;
  max-width: 520px;
}

.archive-search__input {
  width: 100%;
  font-family: var(--mono);
  font-size: 0.82rem;
  padding: 0.7rem 1rem 0.7rem 2.8rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238a8a82' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 0.8rem center;
}

.archive-search__input:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px var(--amber-glow);
}

.archive-search__input::placeholder {
  color: var(--steel-light);
  font-style: italic;
}

#archive-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  max-width: 860px;
}

/* ============================================================
   Sections Manager Modal
   ============================================================ */
.sections-manager {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.sections-manager__add-row {
  display: flex;
  gap: var(--space-sm);
  align-items: flex-end;
  padding-top: var(--space-md);
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

.sections-manager__add-row .form-group {
  margin-bottom: 0;
  flex: 1;
  min-width: 120px;
}

.sections-manager-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.section-manager-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg-card-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 0.15s;
}

.section-manager-item.drag-over-top {
  border-top: 2px solid var(--amber);
}
.section-manager-item.drag-over-bottom {
  border-bottom: 2px solid var(--amber);
}
.section-manager-item.is-dragging {
  opacity: 0.4;
}

.section-manager-item--locked {
  opacity: 0.75;
  cursor: default;
}

.section-manager-item__handle {
  color: var(--text-dim);
  cursor: grab;
  font-size: 0.9rem;
  opacity: 0.5;
  flex-shrink: 0;
}

.section-manager-item__swatch {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  flex-shrink: 0;
  border: 1px solid rgba(255,255,255,0.1);
}

.section-manager-item__label {
  font-family: var(--display);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-bright);
  flex: 1;
}

.section-manager-item__id {
  font-family: var(--mono);
  font-size: 0.6rem;
  color: var(--text-dim);
}

.section-manager-item__actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.color-picker-input {
  width: 40px;
  height: 32px;
  padding: 2px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  cursor: pointer;
}

/* ============================================================
   Board nav additions
   ============================================================ */
.admin-nav__btn {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}
.admin-nav__btn:hover {
  color: var(--amber);
  background: rgba(212, 160, 60, 0.06);
  border-color: var(--amber-dim);
}

/* ============================================================
   Alert / toast for board actions
   ============================================================ */
.board-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  font-family: var(--mono);
  font-size: 0.72rem;
  padding: 0.65rem 1.1rem;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  z-index: 9000;
  animation: slideUp 0.25s var(--ease-out) forwards;
  max-width: 320px;
  pointer-events: none;
}
.board-toast--success { border-color: var(--green); color: var(--green); }
.board-toast--error   { border-color: var(--rust); color: var(--rust); }
.board-toast.fade-out { animation: fadeOut 0.3s var(--ease-out) forwards; }

@keyframes fadeOut {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(6px); }
}

/* ============================================================
   Locked Header Lane (desk section)
   ============================================================ */
.kanban-lane--header-locked .kanban-lane__header {
  border-bottom: 2px solid color-mix(in srgb, var(--lane-accent, #6C3483), transparent 40%);
}

/* ============================================================
   Protected Kanban Lanes
   ============================================================ */
.kanban-lane--protected {
  flex: 0 0 220px;
  opacity: 0.88;
  border-style: dashed;
  display: flex;
  flex-direction: column;
}

.kanban-lane--protected .kanban-lane__header {
  background: color-mix(in srgb, var(--bg-card-alt), transparent 20%);
}

.kanban-lane__body--protected {
  flex: 1;
  overflow-y: auto;
  padding: 8px 10px;
  pointer-events: none;
}

.protected-lock {
  font-size: 0.6rem;
  opacity: 0.5;
  flex-shrink: 0;
}

.protected-preview-cols {
  display: flex;
  gap: 6px;
}

.protected-preview-col {
  flex: 1;
}

.protected-preview-col__head {
  font-family: var(--mono);
  font-size: 0.48rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber-dim);
  margin-bottom: 4px;
}

.protected-preview-col__item,
.protected-preview-row {
  font-family: var(--mono);
  font-size: 0.54rem;
  color: var(--text-dim);
  padding: 2px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.protected-preview-row {
  display: flex;
  gap: 4px;
}

.protected-preview-row__role {
  color: var(--text-dim);
  flex-shrink: 0;
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.protected-preview-row__name {
  color: var(--text);
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
}

.protected-preview-more {
  font-family: var(--mono);
  font-size: 0.5rem;
  color: var(--text-dim);
  margin-top: 4px;
  opacity: 0.6;
}

.protected-lane-footer {
  padding: 8px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: center;
  flex-shrink: 0;
}

/* ============================================================
   Static Editor (inside modals)
   ============================================================ */
.static-editor-tabs {
  display: flex;
  gap: 0;
  margin-bottom: var(--space-md);
  border-bottom: 1px solid var(--border);
}

.static-editor-tab {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.55rem 1.1rem;
  border: none;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  margin-bottom: -1px;
}

.static-editor-tab:hover { color: var(--text); }
.static-editor-tab--active {
  color: var(--amber);
  border-bottom-color: var(--amber);
}

.static-editor-list {
  margin-bottom: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 320px;
  overflow-y: auto;
}

.static-editor-empty {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  padding: var(--space-lg) 0;
  text-align: center;
  opacity: 0.5;
  font-style: italic;
}

.se-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  background: var(--bg-card-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.se-row__order {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex-shrink: 0;
}

.se-order-btn {
  font-family: var(--mono);
  font-size: 0.55rem;
  padding: 1px 4px;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  line-height: 1;
  transition: all 0.15s;
}

.se-order-btn:hover:not(:disabled) {
  background: var(--bg-input);
  color: var(--amber);
  border-color: var(--amber-dim);
}

.se-order-btn:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

.se-row__content {
  flex: 1;
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  font-family: var(--mono);
  font-size: 0.7rem;
  flex-wrap: wrap;
}

.se-type {
  font-size: 0.55rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  padding: 1px 5px;
  border-radius: 2px;
  flex-shrink: 0;
}

.se-type--link {
  color: var(--amber-dim);
  border-color: var(--amber-dim);
  background: rgba(212,160,60,0.06);
}

.se-val {
  color: var(--text-bright);
  font-weight: 500;
}

.se-detail, .se-url {
  color: var(--text-dim);
  font-size: 0.6rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.se-sep {
  color: var(--steel-light);
  font-size: 0.65rem;
}

.se-row__actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

/* Inline edit form inside a se-row */
.se-inline-form {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  width: 100%;
}

.se-inline-form input,
.se-inline-form select {
  font-size: 0.75rem;
  padding: 0.3rem 0.5rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  min-width: 80px;
}

.se-inline-form input:focus,
.se-inline-form select:focus {
  outline: none;
  border-color: var(--amber);
}

.se-event-fields,
.se-link-fields {
  display: flex;
  gap: 6px;
  flex: 1;
}

.se-inline-form__btns {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

/* Add form at bottom of modal */
.static-editor-add-form {
  padding-top: var(--space-md);
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.static-editor-add-form__row {
  display: flex;
  align-items: flex-end;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.static-editor-add-form__field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 100px;
}

.static-editor-add-form__field label {
  font-family: var(--mono);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.static-editor-add-form__field--grow {
  flex: 1;
}
