/* Original stylesheet for the self-hosted cloud notepad. */

:root {
  --page-bg: #f9fafb;
  --white: #ffffff;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --placeholder: #a4a8ad;
  --blue-50: #f1f7fe;
  --blue-100: #dbeafe;
  --blue-600: #2563eb;
  --blue-700: #1d4ed8;
  --blue-800: #1e40af;
  --green-50: #f0fdf4;
  --green-100: #dcfce7;
  --green-500: #22c55e;
  --green-700: #15803d;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-800: #1e2937;
  --slate-900: #0f172a;
  --red-50: #fef2f2;
  --red-500: #ef4444;
  --red-600: #dc2626;
  --header-h: 64px;
  --sidebar-w: 320px;
  --editor-min: 800px;
  --max: 80rem;
  --sans: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, "Helvetica Neue", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  background: var(--page-bg);
  color: var(--gray-800);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  min-height: 100%;
}
button, input, select, textarea { font-family: inherit; }
button { cursor: pointer; border: 0; background: none; color: inherit; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}

/* ---------- top bar ---------- */
.topbar {
  height: var(--header-h);
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  position: sticky;
  top: 0;
  z-index: 40;
}
.topbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  height: 100%;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
@media (min-width: 640px) {
  .topbar-inner { padding: 0 1.5rem; }
}
.topbar-left, .topbar-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}
.topbar-center {
  flex: 1;
  display: flex;
  justify-content: center;
  min-width: 0;
}
#editor-app .topbar-center { justify-content: flex-start; padding-left: 0.25rem; }
#landing .topbar-inner { justify-content: space-between; }
#landing .topbar-center { display: none; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.brand-text {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--gray-800);
  line-height: 1;
}
.brand-tile {
  display: none;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: #fff;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}
.topbar-divider {
  width: 1px;
  height: 22px;
  background: var(--gray-200);
  flex-shrink: 0;
}
.topbar-rule {
  width: 1px;
  height: 28px;
  background: var(--gray-200);
  flex-shrink: 0;
}
.topbar-meta {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--gray-600);
  font-size: 0.875rem;
}
.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--gray-600);
  font-size: 0.875rem;
  white-space: nowrap;
}
.meta-item .fa { color: var(--gray-400); font-size: 14px; }
.password-trigger { padding: 0; }
.select-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.select-wrap .fa-angle-down {
  position: absolute;
  right: 0;
  color: var(--gray-400);
  pointer-events: none;
  font-size: 12px;
}
.expire-select {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: transparent;
  font-weight: 700;
  color: var(--gray-800);
  padding: 0 1rem 0 0.15rem;
  font-size: 0.875rem;
  cursor: pointer;
  outline: none;
}

/* pills */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  border-radius: 999px;
  padding: 0.15rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.4;
  border: 1px solid transparent;
  max-width: 100%;
}
.pill-muted {
  background: var(--gray-100);
  color: var(--gray-500);
  font-weight: 700;
  padding: 0.1rem 0.5rem;
}
.pill-ok {
  background: var(--green-50);
  color: var(--green-700);
  border-color: var(--green-100);
  font-weight: 600;
}
.pill-ok .fa { color: var(--green-500); }
.pill-set {
  background: #eff6ff;
  color: var(--blue-700);
  border-color: var(--blue-100);
}

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 1px solid var(--gray-200);
  background: var(--white);
  color: var(--gray-700);
  border-radius: 0.25rem;
  padding: 0.45rem 0.8rem;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  transition: background 0.15s, color 0.15s, border-color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.btn:hover { border-color: #93c5fd; color: var(--blue-600); background: #f8fafc; }
.btn-primary {
  background: var(--blue-600);
  border-color: var(--blue-600);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 4px 6px -1px rgb(37 99 235 / 0.25), 0 2px 4px -2px rgb(37 99 235 / 0.2);
}
.btn-primary:hover { background: #1d4ed8; border-color: #1d4ed8; color: #fff; }
.btn-save { padding: 0.45rem 0.95rem; }
.btn-save:hover .fa-floppy-o { animation: bounce 0.6s; }
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  40% { transform: translateY(-3px); }
  70% { transform: translateY(0); }
}
.btn-block { flex: 1; padding: 0.6rem 0.5rem; font-weight: 600; }
#copy-btn:hover { color: var(--blue-600); border-color: #93c5fd; }
#download-btn:hover { color: #15803d; border-color: #86efac; }
.btn-sm {
  padding: 0.25rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0.375rem;
}
.btn-ghost {
  background: transparent;
  border: 1px solid var(--gray-200);
  color: var(--gray-700);
}
.btn-danger-quiet {
  background: transparent;
  border: 1px solid transparent;
  color: var(--gray-500);
  font-size: 0.875rem;
  padding: 0.4rem 0.55rem;
}
.btn-danger-quiet:hover { color: var(--red-500); background: var(--red-50); }
.icon-btn {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.25rem;
  color: var(--gray-500);
}
.icon-btn:hover { background: var(--gray-100); color: var(--gray-700); }
.hamburger { width: 36px; height: 36px; font-size: 18px; color: var(--gray-700); }

/* info bar */
.info-bar {
  max-width: var(--max);
  margin: 0 auto;
  background: var(--blue-50);
  border-bottom: 1px solid #dbeafe;
  color: var(--blue-800);
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 41px;
}
@media (min-width: 640px) {
  .info-bar { padding-left: 1.5rem; padding-right: 1.5rem; }
}
.info-bar .fa-info-circle { color: var(--blue-600); }

/* tab bar */
.tabbar {
  max-width: var(--max);
  margin: 0 auto;
  background: var(--gray-100);
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: flex-end;
  padding: 0 0.5rem 0 0.75rem;
  min-height: 43px;
  position: sticky;
  top: var(--header-h);
  z-index: 30;
}
.tabbar-tabs { display: flex; align-items: flex-end; gap: 0; min-width: 0; }
.tab {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  max-width: 150px;
  padding: 0.45rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--gray-500);
  border: 1px solid transparent;
  border-bottom: 0;
  border-radius: 0.25rem 0.25rem 0 0;
  background: transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tab .fa { color: var(--gray-400); }
.tab.is-active {
  background: var(--white);
  color: var(--gray-800);
  border-color: var(--gray-200);
  position: relative;
  z-index: 1;
}
.tab.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  background: var(--white);
}
.tab-add {
  width: 28px;
  height: 28px;
  margin: 0 0.35rem 0.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.25rem;
  color: var(--gray-400);
  font-size: 14px;
}
.tab-add:hover { background: #eff6ff; color: var(--blue-600); }
.tabbar-spacer { flex: 1; }
.sidebar-toggle { margin-bottom: 0.3rem; color: var(--gray-500); }

/* workspace */
.workspace {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: stretch;
  background: var(--white);
  min-height: var(--editor-min);
  position: relative;
}
.editor-pane {
  flex: 1;
  min-width: 0;
  position: relative;
  background: var(--white);
  min-height: var(--editor-min);
}
#editor {
  display: block;
  width: 100%;
  height: 100%;
  min-height: var(--editor-min);
  border: 0;
  outline: none;
  resize: none;
  padding: 1rem;
  font-family: var(--mono);
  font-size: 1rem;
  line-height: 2;
  color: var(--gray-800);
  background: transparent;
}
@media (min-width: 768px) {
  #editor { padding: 1.5rem; }
}
#editor::placeholder { color: var(--placeholder); opacity: 1; white-space: pre-wrap; }
.eraser-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  color: var(--gray-400);
  z-index: 2;
}
.eraser-btn:hover { color: var(--red-500); background: var(--red-50); }
.char-count {
  position: absolute;
  right: 1rem;
  bottom: 0.75rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: #d1d5db;
  background: rgb(255 255 255 / 0.8);
  backdrop-filter: blur(4px);
  border: 1px solid var(--gray-100);
  border-radius: 0.25rem;
  padding: 0.15rem 0.45rem;
  pointer-events: none;
  z-index: 2;
}
.editor-pane:hover .char-count { color: #9ca3af; }

/* sidebar */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--gray-50);
  border-left: 1px solid var(--gray-200);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  min-height: var(--editor-min);
  position: relative;
}
.workspace.sidebar-collapsed .sidebar { display: none; }
.action-row { display: flex; gap: 0.75rem; }
.download-wrap { flex: 1; position: relative; }
.download-wrap .btn-block { width: 100%; }

.card {
  background: var(--white);
  border: 1px solid var(--gray-100);
  border-radius: 0.25rem;
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  padding: 1rem 1rem 0.9rem;
}
.card-title {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  text-align: center;
}
.stats > div {
  padding: 0.15rem 0.25rem;
}
.stats > div + div { border-left: 1px solid var(--gray-100); }
.stats strong {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--gray-800);
  line-height: 1.2;
}
.stats span {
  display: block;
  font-size: 0.75rem;
  color: var(--gray-400);
  margin-top: 0.15rem;
}

.info-rows {
  font-size: 0.8125rem;
  color: var(--gray-600);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.info-rows #info-reads { font-weight: 700; color: var(--gray-800); }

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.45rem 0;
  width: 100%;
  text-align: left;
}
.setting-row + .setting-row { border-top: 1px solid var(--gray-100); }
.setting-label { color: var(--gray-700); font-size: 0.875rem; display: inline-flex; align-items: center; gap: 0.4rem; }
.setting-label .fa { color: var(--gray-400); }
.select-boxed {
  border: 1px solid var(--gray-200);
  border-radius: 0.375rem;
  background: var(--white);
  padding: 0.15rem 0.45rem;
}
.select-boxed .expire-select { padding-right: 1.1rem; font-weight: 600; }
.select-boxed .fa-angle-down { right: 0.35rem; }

.share-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}
.share-head .card-title { margin: 0; }
.segmented {
  display: inline-flex;
  background: var(--gray-200);
  padding: 0.125rem;
  border-radius: 0.25rem;
}
.seg-btn {
  font-size: 10px;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 0.2rem;
  color: var(--gray-500);
}
.seg-btn.active {
  background: var(--white);
  color: var(--blue-600);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06);
}
.share-caption { font-size: 0.75rem; color: var(--gray-600); margin: 0 0 0.5rem; }
.share-url {
  display: flex;
  align-items: center;
  border: 1px solid var(--gray-200);
  border-radius: 0.5rem;
  padding: 0.2rem 0.25rem 0.2rem 0.7rem;
  background: var(--white);
  gap: 0.35rem;
}
.share-url input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  font-size: 0.75rem;
  color: var(--gray-600);
  background: transparent;
}
.qr-link {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: var(--gray-500);
}
.link-btn { color: var(--gray-500); font-size: 0.8125rem; }
.link-btn:hover { color: var(--blue-600); }

.menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0; right: 0;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 0.375rem;
  box-shadow: 0 8px 20px rgb(0 0 0 / 0.08);
  z-index: 20;
  overflow: hidden;
}
.menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.7rem;
  font-size: 0.8125rem;
  color: var(--gray-700);
}
.menu button:hover { background: var(--gray-50); color: var(--blue-600); }

/* overlay / mobile drawer */
.sidebar-overlay {
  display: none;
}
.sidebar-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.08);
  color: var(--gray-600);
  z-index: 5;
  display: none;
}

/* footer */
.site-footer {
  background: var(--slate-900);
  color: #fff;
  padding: 4rem 1.5rem 2rem;
}
.footer-inner { max-width: var(--max); margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
.footer-brand {
  display: inline-block;
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.85rem;
}
.footer-blurb {
  color: var(--slate-400);
  font-size: 0.875rem;
  line-height: 1.7;
  max-width: 18rem;
  margin: 0;
}
.site-footer h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 0.85rem;
  color: #fff;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li, .site-footer li a {
  color: var(--slate-400);
  font-size: 0.875rem;
  line-height: 2;
}
.site-footer li a:hover { color: #fff; }
.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--slate-800);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  color: var(--slate-500);
  font-size: 0.8125rem;
}
.footer-badges { color: var(--slate-500); }
.footer-badges .fa { margin: 0 0.15rem; }

/* landing */
.landing-main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 3.5rem 1.25rem 4rem;
  min-height: calc(100vh - var(--header-h) - 16rem);
  display: flex;
  justify-content: center;
}
.landing-card {
  width: 100%;
  max-width: 32rem;
  background: var(--white);
  border: 1px solid var(--gray-100);
  border-radius: 0.5rem;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.05);
  padding: 2.25rem 1.75rem;
  text-align: center;
}
.landing-card h1 {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 0.6rem;
}
.landing-lead {
  color: var(--gray-500);
  font-size: 0.9375rem;
  margin: 0 0 1.5rem;
  line-height: 1.7;
}
.landing-form {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.landing-form input {
  width: 100%;
  border: 1px solid var(--gray-200);
  border-radius: 0.375rem;
  padding: 0.7rem 0.85rem;
  font-size: 0.9375rem;
  outline: none;
}
.landing-form input:focus { border-color: var(--blue-600); box-shadow: 0 0 0 3px rgb(37 99 235 / 0.15); }
.landing-or { color: var(--gray-400); font-size: 0.8125rem; margin: 1rem 0 0.75rem; }
.landing-error { color: var(--red-600); font-size: 0.8125rem; margin-top: 0.75rem; }

/* toasts / modal / loading */
.toast-container {
  position: fixed;
  top: 80px;
  right: 24px;
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}
.toast {
  background: var(--white);
  border: 1px solid var(--gray-100);
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.1);
  border-radius: 0.375rem;
  padding: 0.65rem 0.9rem;
  font-size: 0.875rem;
  color: var(--gray-700);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 10rem;
  pointer-events: auto;
  animation: toast-in 0.2s ease;
}
.toast .fa-check-circle { color: var(--green-500); }
.toast.is-error .fa { color: var(--red-500); }
.toast.is-info .fa { color: var(--blue-600); }
@keyframes toast-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

.modal-root {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgb(0 0 0 / 0.4);
}
.modal {
  position: relative;
  background: var(--white);
  border-radius: 0.5rem;
  box-shadow: 0 20px 40px rgb(0 0 0 / 0.18);
  width: 100%;
  max-width: 26rem;
  padding: 1.35rem 1.35rem 1.15rem;
  z-index: 1;
}
.modal h3 { margin: 0 0 0.85rem; font-size: 1.05rem; }
.modal p { margin: 0 0 0.75rem; color: var(--gray-600); font-size: 0.875rem; line-height: 1.6; }
.modal input[type="password"], .modal input[type="text"] {
  width: 100%;
  border: 1px solid var(--gray-200);
  border-radius: 0.375rem;
  padding: 0.55rem 0.7rem;
  font-size: 0.9375rem;
  outline: none;
  margin-bottom: 0.75rem;
}
.modal input:focus { border-color: var(--blue-600); box-shadow: 0 0 0 3px rgb(37 99 235 / 0.15); }
.modal-actions { display: flex; justify-content: flex-end; gap: 0.5rem; }
.modal-error { color: var(--red-600) !important; min-height: 1.2em; }
.modal-table { width: 100%; border-collapse: collapse; font-size: 0.8125rem; }
.modal-table th, .modal-table td {
  text-align: left;
  padding: 0.4rem 0.35rem;
  border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700);
}
.modal-table th { color: var(--gray-400); font-weight: 600; }
.qr-box { display: flex; justify-content: center; padding: 0.5rem 0 0.25rem; }
.qr-box img, .qr-box canvas, .qr-box table { margin: 0 auto; }

.loading {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 20vh;
  background: rgb(249 250 251 / 0.65);
}
.loading-card {
  background: var(--white);
  border-radius: 0.375rem;
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.08);
  padding: 0.8rem 1.1rem;
  color: var(--gray-600);
  font-size: 0.875rem;
}

.warn { color: var(--red-600); font-size: 0.8125rem; }

/* responsive visibility helpers
   sm 640, md 768, lg 1024 — match Tailwind-style breakpoints from the inventory */
.hidden-below-sm { }
.hidden-below-md { }
.hidden-below-lg { }
.hidden-at-lg { }

@media (max-width: 639px) {
  .hidden-below-sm { display: none !important; }
}
@media (max-width: 767px) {
  .hidden-below-md { display: none !important; }
  .brand-text { display: none; }
  .brand-tile { display: inline-flex; }
  #editor-app .topbar-center { flex: 1; justify-content: flex-start; }
  .pill-ok { font-size: 0.6875rem; padding: 0.2rem 0.5rem; line-height: 1.3; }
  .toast-container { left: 12px; right: 12px; top: 72px; }
}
@media (max-width: 1023px) {
  .hidden-below-lg { display: none !important; }
  .sidebar {
    position: fixed;
    inset: 0 0 0 auto;
    width: 85vw;
    max-width: 320px;
    height: 100vh;
    min-height: 100vh;
    z-index: 60;
    box-shadow: 0 20px 40px rgb(0 0 0 / 0.18);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.2s ease;
    display: flex;
  }
  .sidebar.is-open { transform: translateX(0); }
  .sidebar-close { display: inline-flex; }
  .sidebar-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgb(0 0 0 / 0.2);
    backdrop-filter: blur(2px);
    z-index: 55;
  }
  .workspace { display: block; }
}
@media (min-width: 1024px) {
  .hidden-at-lg { display: none !important; }
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr 1fr; gap: 2.5rem; }
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  .landing-form { flex-direction: row; }
  .landing-form input { flex: 1; }
}

/* when used as a note, footer sits under the editor (no promo bar) */
#editor-app + #site-footer,
body.is-editor #site-footer { /* footer is a sibling */ }

body.is-landing #editor-app { display: none !important; }
body.is-editor #landing { display: none !important; }
