/* NextStep Education — visual guide-library administration */

.guide-admin-panel {
  --guide-ink: #0f172a;
  --guide-muted: #64748b;
  --guide-line: #e2e8f0;
  --guide-soft: #f8fafc;
  --guide-blue-soft: #eff6ff;
  padding: 0;
  overflow: hidden;
  background: #fff;
}

.guide-admin-panel .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.guide-admin-shell { min-height: 560px; }

.guide-admin-titlebar,
.guide-workbench-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.guide-admin-titlebar { padding: 28px 28px 22px; }
.guide-admin-titlebar h3,
.guide-workbench-header h3,
.guide-dialog-header h3 { margin: 2px 0 7px; color: var(--guide-ink); }
.guide-admin-titlebar p,
.guide-workbench-header p,
.guide-dialog-header p,
.guide-editor-card-heading p,
.guide-section-toolbar p,
.guide-category-form-heading p {
  margin: 0;
  color: var(--guide-muted);
  font-size: .78rem;
  line-height: 1.55;
}

.guide-admin-eyebrow {
  color: var(--primary);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .095em;
  text-transform: uppercase;
}

.guide-admin-title-actions,
.guide-workbench-actions,
.guide-category-form-actions,
.guide-confirm-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex-wrap: wrap;
}

.guide-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  padding: 0 28px 24px;
}

.guide-stat {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 14px 15px;
  border: 1px solid var(--guide-line);
  border-radius: 13px;
  background: var(--guide-soft);
}

.guide-stat-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 10px;
  font-size: .85rem;
  font-weight: 800;
}

.guide-stat-published .guide-stat-icon { color: #047857; background: #d1fae5; }
.guide-stat-draft .guide-stat-icon { color: #1d4ed8; background: #dbeafe; }
.guide-stat-featured .guide-stat-icon { color: #a16207; background: #fef3c7; }
.guide-stat-categories .guide-stat-icon { color: #6d28d9; background: #ede9fe; }
.guide-stat strong { display: block; color: var(--guide-ink); font-size: 1.18rem; line-height: 1.05; }
.guide-stat div > span { display: block; margin-top: 4px; color: var(--guide-muted); font-size: .7rem; }

.guide-list-tabs {
  display: flex;
  gap: 22px;
  margin: 0 28px;
  border-bottom: 1px solid var(--guide-line);
}

.guide-list-tab {
  position: relative;
  border: 0;
  padding: 10px 1px 12px;
  background: none;
  color: var(--guide-muted);
  font: 700 .78rem/1 inherit;
  cursor: pointer;
}

.guide-list-tab::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  border-radius: 2px 2px 0 0;
  background: transparent;
}

.guide-list-tab:hover,
.guide-list-tab.active { color: var(--primary); }
.guide-list-tab.active::after { background: var(--primary); }

.guide-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1.35fr) repeat(3, minmax(145px, .58fr)) 40px;
  gap: 9px;
  padding: 18px 28px;
  align-items: center;
}

.guide-search-field {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding-left: 11px;
  border: 1px solid var(--guide-line);
  border-radius: 10px;
  color: var(--guide-muted);
  background: #fff;
}

.guide-search-field input,
.guide-toolbar select,
.guide-field input,
.guide-field textarea,
.guide-field select,
.guide-language-card input,
.guide-language-card textarea,
.guide-section-card input,
.guide-section-card textarea,
.guide-category-form-pane input,
.guide-category-form-pane select {
  width: 100%;
  border: 1px solid var(--guide-line);
  border-radius: 10px;
  padding: 10px 11px;
  background: #fff;
  color: var(--guide-ink);
  font: 500 .8rem/1.4 inherit;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.guide-search-field input {
  min-width: 0;
  border: 0;
  padding-left: 0;
  outline: 0;
}

.guide-toolbar select { min-width: 0; }
.guide-icon-button,
.guide-back-button,
.guide-dialog-close,
.guide-section-icon-button {
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--guide-line);
  border-radius: 10px;
  background: #fff;
  color: var(--guide-muted);
  cursor: pointer;
  transition: border-color .18s ease, color .18s ease, background .18s ease;
}

.guide-icon-button { width: 40px; height: 40px; font-size: 1rem; }
.guide-icon-button:hover,
.guide-back-button:hover,
.guide-dialog-close:hover,
.guide-section-icon-button:hover { color: var(--primary); border-color: #93c5fd; background: var(--guide-blue-soft); }

.guide-list-head,
.guide-list-row {
  display: grid;
  grid-template-columns: minmax(250px, 1.45fr) minmax(135px, .62fr) minmax(145px, .7fr) minmax(120px, .55fr) minmax(190px, .8fr);
  gap: 16px;
  align-items: center;
}

.guide-list-head {
  padding: 9px 28px;
  border-top: 1px solid var(--guide-line);
  border-bottom: 1px solid var(--guide-line);
  background: var(--guide-soft);
  color: var(--guide-muted);
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .045em;
  text-transform: uppercase;
}

.guide-admin-list { min-height: 230px; }
.guide-list-row {
  padding: 16px 28px;
  border-bottom: 1px solid var(--guide-line);
  background: #fff;
  transition: background .16s ease;
}
.guide-list-row:hover { background: #fbfdff; }
.guide-list-row:last-child { border-bottom: 0; }
.guide-list-primary { min-width: 0; }
.guide-list-title { display: flex; align-items: center; gap: 7px; color: var(--guide-ink); font-size: .84rem; font-weight: 750; }
.guide-list-title > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.guide-list-summary { margin-top: 4px; color: var(--guide-muted); font-size: .7rem; line-height: 1.45; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.guide-feature-star { color: #d97706; font-size: .75rem; }
.guide-category-pill,
.guide-kind-pill,
.guide-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: .65rem;
  font-weight: 750;
  line-height: 1.25;
  white-space: nowrap;
}
.guide-category-pill::before { content: ''; width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: var(--category-color, #64748b); }
.guide-category-pill { color: #334155; background: var(--guide-soft); border: 1px solid var(--guide-line); }
.guide-kind-pill { color: #1e40af; background: #eff6ff; border: 1px solid #bfdbfe; }
.guide-status-pill[data-status="published"] { color: #065f46; background: #ecfdf5; border: 1px solid #a7f3d0; }
.guide-status-pill[data-status="draft"] { color: #475569; background: #f8fafc; border: 1px solid #cbd5e1; }
.guide-list-badges { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.guide-list-date { color: var(--guide-muted); font-size: .7rem; line-height: 1.45; }
.guide-list-actions { display: flex; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.guide-row-button { padding: 6px 9px; border: 1px solid var(--guide-line); border-radius: 8px; background: #fff; color: #334155; font: 700 .67rem/1.2 inherit; cursor: pointer; }
.guide-row-button:hover { color: var(--primary); border-color: #93c5fd; }
.guide-row-button.danger:hover { color: #b91c1c; border-color: #fecaca; background: #fef2f2; }

.guide-loading-state,
.guide-empty-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 52px 24px;
  color: var(--guide-muted);
  text-align: center;
  font-size: .8rem;
}
.guide-empty-state strong { color: var(--guide-ink); font-size: .95rem; }
.guide-empty-state span[aria-hidden="true"] { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 15px; background: var(--guide-blue-soft); color: var(--primary); font-size: 1.15rem; }
.guide-spinner { width: 22px; height: 22px; border: 3px solid #dbeafe; border-top-color: var(--primary); border-radius: 50%; animation: guide-spin .75s linear infinite; }
@keyframes guide-spin { to { transform: rotate(360deg); } }
.guide-admin-panel > .form-status,
.guide-admin-shell > .form-status,
[data-guide-list-status] { margin: 0 28px 22px; }

/* Full-width guide editor */
.guide-workbench { background: #f8fafc; }
.guide-workbench-header {
  position: static;
  padding: 18px 24px;
  border-bottom: 1px solid var(--guide-line);
  background: rgba(255,255,255,.96);
  box-shadow: 0 8px 24px rgba(15, 23, 42, .05);
  backdrop-filter: blur(10px);
}
.guide-workbench-heading { display: flex; align-items: flex-start; gap: 12px; }
.guide-back-button { width: 36px; height: 36px; flex: 0 0 36px; font-size: 1rem; }
.guide-workbench-header h3 { margin-bottom: 3px; font-size: 1.15rem; }
.guide-workbench-header p { font-size: .7rem; }
.guide-workbench-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 330px);
  gap: 20px;
  padding: 22px;
  align-items: start;
}
.guide-form-column { display: grid; gap: 16px; min-width: 0; }
.guide-editor-card {
  padding: 20px;
  border: 1px solid var(--guide-line);
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(15, 23, 42, .025);
}
.guide-editor-card-heading { display: flex; gap: 11px; margin-bottom: 18px; }
.guide-editor-card-heading h4 { margin: 0 0 3px; color: var(--guide-ink); font-size: .92rem; }
.guide-step { display: grid; place-items: center; width: 26px; height: 26px; flex: 0 0 26px; border-radius: 8px; background: var(--guide-blue-soft); color: var(--primary); font-size: .7rem; font-weight: 800; }
.guide-bilingual-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.guide-language-card { min-width: 0; margin: 0; padding: 14px; border: 1px solid var(--guide-line); border-radius: 12px; background: #fbfdff; }
.guide-language-card legend { padding: 0 7px; color: var(--primary); font-size: .68rem; font-weight: 800; letter-spacing: .07em; }
.guide-language-card legend span { margin-left: 4px; color: var(--guide-muted); font-weight: 650; letter-spacing: 0; }
.guide-language-card label,
.guide-field { display: grid; gap: 6px; margin-bottom: 12px; color: #334155; font-size: .72rem; font-weight: 750; }
.guide-language-card label:last-child,
.guide-field:last-child { margin-bottom: 0; }
.guide-language-card label > span em { color: var(--guide-muted); font-size: .64rem; font-style: normal; font-weight: 500; }
.guide-language-card textarea { min-height: 94px; resize: vertical; }
.guide-language-card small,
.guide-field small { color: var(--guide-muted); font-size: .62rem; font-weight: 500; line-height: 1.45; }
.guide-language-card label small[data-count-for] { justify-self: end; margin-top: -2px; }
.guide-language-card input:focus,
.guide-language-card textarea:focus,
.guide-field input:focus,
.guide-field textarea:focus,
.guide-field select:focus,
.guide-section-card input:focus,
.guide-section-card textarea:focus,
.guide-category-form-pane input:focus,
.guide-category-form-pane select:focus { outline: 0; border-color: #60a5fa; box-shadow: 0 0 0 3px rgba(37,99,235,.11); }
.guide-field [aria-invalid="true"],
.guide-language-card [aria-invalid="true"],
.guide-section-card [aria-invalid="true"] { border-color: #f87171; box-shadow: 0 0 0 3px rgba(239,68,68,.08); }

.guide-action-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
.guide-action-choice { display: flex; align-items: flex-start; gap: 11px; padding: 14px; border: 1.5px solid var(--guide-line); border-radius: 12px; background: #fff; cursor: pointer; transition: border-color .18s ease, background .18s ease, box-shadow .18s ease; }
.guide-action-choice:hover { border-color: #93c5fd; }
.guide-action-choice.selected { border-color: var(--primary); background: var(--guide-blue-soft); box-shadow: 0 0 0 3px rgba(37,99,235,.07); }
.guide-action-choice input { position: absolute; opacity: 0; pointer-events: none; }
.guide-action-choice-icon { display: grid; place-items: center; width: 32px; height: 32px; flex: 0 0 32px; border-radius: 9px; background: #f1f5f9; color: #475569; font-weight: 800; }
.guide-action-choice.selected .guide-action-choice-icon { color: var(--primary); background: #dbeafe; }
.guide-action-choice strong,
.guide-action-choice small { display: block; }
.guide-action-choice strong { color: var(--guide-ink); font-size: .76rem; }
.guide-action-choice small { margin-top: 4px; color: var(--guide-muted); font-size: .65rem; font-weight: 500; line-height: 1.45; }
.guide-section-toolbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding-top: 2px; margin-bottom: 12px; }
.guide-section-toolbar h5 { margin: 0 0 2px; color: var(--guide-ink); }
.guide-section-list { display: grid; gap: 11px; }
.guide-section-card { border: 1px solid var(--guide-line); border-radius: 12px; background: var(--guide-soft); overflow: hidden; }
.guide-section-card-header { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 9px 11px; border-bottom: 1px solid var(--guide-line); background: #fff; }
.guide-section-card-header strong { color: #334155; font-size: .7rem; }
.guide-section-card-actions { display: flex; gap: 5px; }
.guide-section-icon-button { width: 27px; height: 27px; border-radius: 7px; font-size: .72rem; }
.guide-section-icon-button.danger:hover { color: #b91c1c; border-color: #fecaca; background: #fef2f2; }
.guide-section-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 12px; }
.guide-section-language { display: grid; gap: 7px; min-width: 0; }
.guide-section-language > span { color: var(--guide-muted); font-size: .63rem; font-weight: 800; letter-spacing: .05em; }
.guide-section-card textarea { min-height: 120px; resize: vertical; }
.guide-section-empty { padding: 22px; border: 1px dashed #cbd5e1; border-radius: 12px; color: var(--guide-muted); text-align: center; font-size: .72rem; }
.guide-link-fields { padding: 15px; border: 1px solid var(--guide-line); border-radius: 12px; background: var(--guide-soft); }
.guide-legacy-note { margin-bottom: 18px; padding: 14px 15px; border: 1px solid #cbd5e1; border-radius: 12px; color: #334155; background: #f8fafc; font-size: .72rem; line-height: 1.6; }
.guide-link-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 12px; }
.guide-settings-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(150px, .45fr); gap: 12px; }
.guide-publish-options { margin-top: 3px; }
.guide-feature-toggle { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid var(--guide-line); border-radius: 11px; background: var(--guide-soft); cursor: pointer; }
.guide-feature-toggle input { margin-top: 3px; accent-color: var(--primary); }
.guide-feature-toggle > span[aria-hidden="true"] { color: #d97706; font-weight: 800; }
.guide-feature-toggle strong,
.guide-feature-toggle small { display: block; }
.guide-feature-toggle strong { color: var(--guide-ink); font-size: .72rem; }
.guide-feature-toggle small { margin-top: 3px; color: var(--guide-muted); font-size: .62rem; font-weight: 500; line-height: 1.4; }

.guide-preview-sticky { position: sticky; top: calc(var(--nav-height, 72px) + 16px); padding: 16px; border: 1px solid var(--guide-line); border-radius: 15px; background: #fff; box-shadow: 0 10px 28px rgba(15,23,42,.05); }

[data-guide-editor-view] { scroll-margin-top: calc(var(--nav-height, 72px) + 16px); }
.guide-workbench :is(input, textarea, select, button) { scroll-margin-top: calc(var(--nav-height, 72px) + 24px); }
.guide-raw-order-hidden { display: none !important; }
.guide-position-select { width: 100%; }
.guide-preview-heading { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 13px; color: var(--guide-ink); font-size: .75rem; font-weight: 800; }
.guide-preview-heading small { display: block; margin-top: 2px; color: var(--guide-muted); font-size: .6rem; font-weight: 500; }
.guide-preview-language { display: flex; padding: 2px; border: 1px solid var(--guide-line); border-radius: 8px; background: var(--guide-soft); }
.guide-preview-language button { border: 0; border-radius: 6px; padding: 4px 7px; background: transparent; color: var(--guide-muted); font: 750 .6rem/1 inherit; cursor: pointer; }
.guide-preview-language button.active { background: #fff; color: var(--primary); box-shadow: 0 1px 4px rgba(15,23,42,.1); }
.guide-preview-card { position: relative; display: flex; min-height: 280px; flex-direction: column; overflow: hidden; padding: 20px; border: 1px solid var(--guide-line); border-radius: 13px; background: #fff; }
.guide-preview-accent { position: absolute; top: 0; right: 0; left: 0; height: 4px; background: #2563eb; }
.guide-preview-badges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.guide-preview-category,
.guide-preview-type { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 4px 8px; font-size: .58rem; font-weight: 750; }
.guide-preview-category { color: #1e40af; background: #eff6ff; }
.guide-preview-type { color: #475569; background: #f1f5f9; }
.guide-preview-card h4 { margin: 0 0 9px; color: var(--guide-ink); font-size: .95rem; line-height: 1.38; }
.guide-preview-card p { flex: 1; margin: 0 0 18px; color: var(--guide-muted); font-size: .72rem; line-height: 1.65; }
.guide-preview-card .btn { align-self: flex-start; pointer-events: none; }
.guide-preview-note { display: flex; align-items: flex-start; gap: 8px; margin-top: 12px; padding: 10px; border-radius: 9px; color: #1e3a8a; background: var(--guide-blue-soft); font-size: .62rem; line-height: 1.5; }

/* Category manager and destructive confirmations.
   The global reset removes the user-agent dialog margin, so centering must be
   explicit instead of relying on browser defaults. */
.guide-dialog {
  position: fixed;
  inset: 0;
  width: min(920px, calc(100vw - 32px));
  max-height: min(86vh, 760px);
  max-height: min(86dvh, 760px);
  margin: auto;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 0;
  border-radius: 18px;
  color: var(--guide-ink);
  background: #fff;
  box-shadow: 0 30px 90px rgba(15,23,42,.28);
}
.guide-dialog::backdrop { background: rgba(15,23,42,.65); backdrop-filter: blur(3px); }
.guide-dialog-frame { margin: 0; }
.guide-dialog-header { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; padding: 22px 24px; border-bottom: 1px solid var(--guide-line); }
.guide-dialog-close { width: 34px; height: 34px; flex: 0 0 34px; }
.guide-category-layout { display: grid; grid-template-columns: minmax(260px, .78fr) minmax(340px, 1.22fr); min-height: 440px; }
.guide-category-list-pane { padding: 18px; border-right: 1px solid var(--guide-line); background: var(--guide-soft); }
.guide-category-pane-heading { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 12px; }
.guide-category-pane-heading h4,
.guide-category-form-heading h4 { margin: 0; font-size: .83rem; }
.guide-category-list { display: grid; gap: 7px; }
.guide-category-row { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 9px; align-items: center; width: 100%; padding: 10px; border: 1px solid transparent; border-radius: 10px; background: transparent; text-align: left; cursor: pointer; }
.guide-category-row:hover,
.guide-category-row.active { border-color: #bfdbfe; background: #fff; }
.guide-category-row-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--category-color, #2563eb); }
.guide-category-row strong { display: block; overflow: hidden; color: var(--guide-ink); font-size: .72rem; text-overflow: ellipsis; white-space: nowrap; }
.guide-category-row small { display: block; margin-top: 2px; color: var(--guide-muted); font-size: .6rem; }
.guide-category-row-actions { display: flex; gap: 4px; }
.guide-category-row-actions button { width: 26px; height: 26px; border: 1px solid var(--guide-line); border-radius: 7px; background: #fff; color: var(--guide-muted); cursor: pointer; }
.guide-category-row-actions button:hover { color: var(--primary); border-color: #93c5fd; }
.guide-category-row-actions button.danger:hover { color: #b91c1c; border-color: #fecaca; }
.guide-category-row-actions button:disabled { opacity: .35; cursor: not-allowed; }
.guide-category-form-pane { padding: 22px; overflow: auto; }
.guide-category-form-heading { display: flex; gap: 10px; align-items: flex-start; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--guide-line); }
.guide-category-color-dot { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; background: #2563eb; box-shadow: inset 0 0 0 1px rgba(15,23,42,.08); }
.guide-color-picker { display: grid; grid-template-columns: 46px 1fr; gap: 8px; }
.guide-color-picker input[type="color"] { height: 40px; padding: 3px; cursor: pointer; }
.guide-color-swatches { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 2px; }
.guide-color-swatch { width: 27px; height: 27px; border: 2px solid #fff; border-radius: 8px; background: var(--swatch); box-shadow: 0 0 0 1px #cbd5e1; cursor: pointer; }
.guide-color-swatch.selected { box-shadow: 0 0 0 2px var(--guide-ink); }
.guide-category-chip-preview { display: inline-flex; align-items: center; margin-top: 11px; padding: 5px 10px; border-radius: 999px; color: #1e3a8a; background: #eff6ff; font-size: .65rem; font-weight: 750; }
.guide-category-form-actions { margin-top: 18px; }
.guide-confirm-dialog { width: min(440px, calc(100vw - 28px)); }
.guide-confirm-dialog .guide-dialog-frame { padding: 26px; text-align: center; }
.guide-confirm-icon { display: grid; place-items: center; width: 46px; height: 46px; margin: 0 auto 13px; border-radius: 15px; color: #b91c1c; background: #fee2e2; font-size: 1.1rem; font-weight: 800; }
.guide-confirm-dialog h3 { margin-bottom: 8px; }
.guide-confirm-dialog p { margin: 0 0 17px; color: var(--guide-muted); font-size: .78rem; line-height: 1.6; }
.guide-confirm-dialog .guide-field { text-align: left; }
.guide-confirm-actions { margin-top: 18px; }

@media (max-width: 1040px) {
  .guide-list-head,
  .guide-list-row { grid-template-columns: minmax(220px, 1.4fr) minmax(130px, .7fr) minmax(145px, .8fr) minmax(180px, .85fr); }
  .guide-list-head > :nth-child(4),
  .guide-list-row > :nth-child(4) { display: none; }
  .guide-workbench-layout { grid-template-columns: 1fr; }
  .guide-preview-column { display: none; }
  .guide-preview-column.preview-open { display: block; }
  .guide-preview-column.preview-open .guide-preview-sticky { position: static; }
}

@media (max-width: 820px) {
  .guide-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .guide-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .guide-search-field { grid-column: 1 / -1; }
  .guide-icon-button { width: 100%; }
  .guide-list-head { display: none; }
  .guide-list-row { grid-template-columns: minmax(0, 1fr) auto; gap: 10px; margin: 10px 18px; padding: 14px; border: 1px solid var(--guide-line); border-radius: 12px; }
  .guide-list-row > :nth-child(2),
  .guide-list-row > :nth-child(3) { grid-column: 1; }
  .guide-list-row > :nth-child(5) { grid-column: 2; grid-row: 1 / span 3; align-self: center; flex-direction: column; }
  .guide-bilingual-grid,
  .guide-section-fields,
  .guide-action-choices,
  .guide-link-options { grid-template-columns: 1fr; }
  .guide-category-layout { grid-template-columns: 1fr; }
  .guide-category-list-pane { max-height: 260px; overflow: auto; border-right: 0; border-bottom: 1px solid var(--guide-line); }
}

@media (max-width: 560px) {
  .guide-admin-titlebar,
  .guide-workbench-header { flex-direction: column; }
  .guide-admin-titlebar { padding: 20px 16px 16px; }
  .guide-admin-title-actions,
  .guide-workbench-actions { width: 100%; }
  .guide-admin-title-actions .btn,
  .guide-workbench-actions .btn { flex: 1 1 130px; }
  .guide-stats { padding: 0 16px 18px; gap: 8px; }
  .guide-stat { padding: 11px; }
  .guide-stat-icon { width: 30px; height: 30px; flex-basis: 30px; }
  .guide-list-tabs { margin-inline: 16px; }
  .guide-toolbar { grid-template-columns: 1fr; padding: 14px 16px; }
  .guide-search-field { grid-column: auto; }
  .guide-list-row { grid-template-columns: 1fr; margin-inline: 12px; }
  .guide-list-row > :nth-child(5) { grid-column: 1; grid-row: auto; flex-direction: row; justify-content: flex-start; }
  .guide-workbench-header { position: static; padding: 16px; }
  .guide-workbench-layout { padding: 12px; }
  .guide-editor-card { padding: 15px; }
  .guide-settings-grid { grid-template-columns: 1fr; }
  .guide-section-toolbar { flex-direction: column; }
  .guide-section-toolbar .btn { width: 100%; }
  .guide-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 18px);
    max-height: calc(100dvh - 18px);
    border-radius: 14px;
  }
  .guide-dialog-header,
  .guide-category-form-pane { padding: 17px; }
  .guide-confirm-actions { flex-direction: column-reverse; }
  .guide-confirm-actions .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .guide-spinner { animation-duration: 1.5s; }
  .guide-action-choice,
  .guide-list-row { transition: none; }
}
