:root {
  --ink: #22334a;
  --muted: #8190a3;
  --blue: #4d81cb;
  --line: #e9eff6;
  --ease: cubic-bezier(0.2, 0.75, 0.25, 1);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  color: #22334a;
  background: #f8fbff;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  min-width: 320px;
  background: radial-gradient(ellipse at 50% 5%, #e8f1ff 0, transparent 42%), #f8fbff;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- 顶栏 ---------- */
.site-header {
  height: 82px;
  padding: 0 clamp(22px, 6.5vw, 112px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #e9eff488;
  background: #ffffff9c;
  backdrop-filter: blur(18px);
  position: relative;
  z-index: 5;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.brand img { width: 34px; height: 34px; border-radius: 10px; object-fit: cover; }
.brand small { font-size: 9px; color: #a0adbd; letter-spacing: 1.7px; font-weight: 600; }

.header-right { display: flex; align-items: center; gap: 19px; }
.header-nav { font-size: 9px; letter-spacing: 2px; color: #9aa8ba; font-weight: 650; }

.update-check {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 13px;
  border: 1px solid #e6edf5;
  border-radius: 10px;
  background: #fff;
  color: #7e8fa3;
  font-size: 11px;
  transition: 0.2s var(--ease);
}
.update-check svg { width: 14px; height: 14px; }
.update-check:hover { border-color: #cadcf0; color: #4d7dbe; transform: translateY(-1px); }

.mascot {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  padding: 4px;
  border: 1px solid #e9edf4;
  border-radius: 17px;
  background: #fff;
  box-shadow: 0 4px 14px #344b6910;
  transition: 0.25s var(--ease);
}
.mascot:hover { transform: translateY(-2px) rotate(3deg); box-shadow: 0 8px 24px #344b6920; }
.mascot img { width: 44px; height: 44px; border-radius: 13px; object-fit: cover; }

/* ---------- 使用方法 / 更新日志 ---------- */
.site-info-links {
  width: min(1010px, calc(100% - 64px));
  min-height: 62px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}
.site-info-links > button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border: 1px solid #dbe7f2;
  border-radius: 7px;
  background: #fff;
  color: #58748f;
  font-size: 11px;
  font-weight: 550;
  transition: 0.16s ease;
}
.site-info-links > button:hover { border-color: #bdd8ee; background: #f5faff; color: #168ee5; }
.site-info-links svg { width: 14px; height: 14px; color: #168ee5; }

/* ---------- 首屏 ---------- */
.hero { text-align: center; padding: 51px 20px 62px; }

.hero-logo-wrap {
  position: relative;
  width: 126px;
  height: 126px;
  margin: 0 auto 23px;
  display: grid;
  place-items: center;
}
.hero-logo {
  position: relative;
  z-index: 1;
  width: 116px;
  height: 116px;
  object-fit: cover;
  border-radius: 29px;
  box-shadow: 0 16px 40px #3f6ba329;
}
.logo-orbit {
  position: absolute;
  inset: -8px;
  border: 1px solid #99b9e455;
  border-radius: 37px;
  transform: rotate(13deg);
}

.hero-kicker { margin: 0 0 10px; font-size: 8px; letter-spacing: 3px; color: #9aa8ba; font-weight: 650; }
.hero h1 {
  margin: 0;
  color: #30445e;
  font-size: 57px;
  line-height: 1.13;
  letter-spacing: 5px;
  font-weight: 760;
}
.hero h1 span { color: #6591cd; }
.hero-description {
  font-size: 13px;
  color: #8b99ab;
  margin: 14px 0 30px;
  letter-spacing: 1px;
}
.hero-description.is-editable { cursor: pointer; text-decoration: underline dotted #b7c8dc; text-underline-offset: 4px; }
.hero-description.is-editable:hover { color: #5f82af; }

.search-box {
  width: min(460px, 100%);
  height: 52px;
  margin: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 17px;
  border: 1px solid #e8edf4;
  background: #fff;
  border-radius: 13px;
  box-shadow: 0 7px 26px #47618a0c;
  transition: 0.2s;
}
.search-box:focus-within { border-color: #9ab8e3; box-shadow: 0 8px 28px #4777b21c; }
.search-icon { color: #90a3bb; display: flex; }
.search-icon svg { width: 18px; height: 18px; }
.search-box input {
  border: 0;
  outline: 0;
  flex: 1;
  min-width: 0;
  background: none;
  color: #344b66;
  font-size: 13px;
}
.search-box input::placeholder { color: #b2bdca; }
.search-box kbd {
  border: 1px solid #e9edf2;
  border-radius: 5px;
  padding: 3px 6px;
  color: #a6b0bc;
  font-size: 9px;
}
.search-box button {
  border: 0;
  background: #edf3fa;
  color: #687b91;
  width: 23px;
  height: 23px;
  border-radius: 7px;
}

/* ---------- 目录 ---------- */
.directory { width: min(1010px, calc(100% - 64px)); margin: 0 auto; }

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 20px;
}
.section-title { display: flex; align-items: center; gap: 13px; }
.section-icon {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #edf4fe;
  color: #6390ce;
}
.section-icon svg { width: 21px; height: 21px; }
.section-title .eyebrow { margin: 0 0 3px; font-size: 8px; letter-spacing: 2px; color: #9aa8ba; font-weight: 650; }
.section-title h2 { margin: 0; font-size: 20px; letter-spacing: 0.5px; }
.result-count {
  margin-left: 2px;
  padding: 4px 8px;
  border-radius: 20px;
  background: #eef3f9;
  color: #8d9caf;
  font-size: 10px;
}

.category-tabs {
  display: flex;
  gap: 5px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.category-tab {
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: #8593a5;
  font-size: 11px;
  transition: 0.2s;
}
.category-tab:hover { background: #fff; color: #4e75a5; }
.category-tab.active {
  background: #fff;
  color: #4c7fbe;
  border-color: #e6edf6;
  box-shadow: 0 3px 10px #45628c0a;
}

/* ---------- 表格 ---------- */
.table-shell {
  background: #fff;
  border: 1px solid #e8eef5;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 34px #3d58750b;
}
.table-scroll { overflow: auto; }
.nav-table { width: 100%; border-collapse: collapse; text-align: left; min-width: 640px; }

.nav-table th {
  height: 49px;
  padding: 0 25px;
  background: #fbfcfe;
  border-bottom: 1px solid #edf1f6;
  color: #99a5b4;
  font-size: 10px;
  letter-spacing: 1px;
  font-weight: 600;
}
.nav-table th.image-column { width: 102px; padding-left: 29px; }
.nav-table th.link-column { width: 24%; }

.nav-table td {
  height: 91px;
  padding: 13px 25px;
  border-bottom: 1px solid #f0f3f7;
  vertical-align: middle;
}
.nav-table tbody tr:last-child td { border-bottom: 0; }
.nav-table tbody tr { transition: background 0.2s; }
.nav-table tbody tr:hover { background: #fbfdff; }

.site-logo-cell { width: 102px; padding-left: 29px !important; }

.site-icon-frame { position: relative; display: block; width: 46px; height: 46px; }
.site-icon,
.site-icon-fallback {
  position: absolute;
  inset: 0;
  width: 46px;
  height: 46px;
  border-radius: 13px;
}
.site-icon {
  z-index: 1;
  object-fit: cover;
  background: #f1f5fa;
  border: 1px solid #edf0f5;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.site-icon.is-ready { opacity: 1; }
.site-icon-fallback {
  display: grid;
  place-items: center;
  border: 1px solid #e6eef8;
  background: linear-gradient(145deg, #edf5ff, #e7eef9);
  color: #6188b8;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.site-name { display: flex; align-items: center; gap: 9px; }
.site-name strong { font-size: 14px; font-weight: 650; color: #354860; }
.site-tag {
  padding: 3px 6px;
  border-radius: 5px;
  background: #f1f5fa;
  color: #94a1b1;
  font-size: 9px;
}
.site-description { margin: 7px 0 0; color: #96a2b1; font-size: 11px; line-height: 1.5; }

.site-link {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border: 1px solid #e9eff6;
  border-radius: 9px;
  color: #6688b2;
  font-size: 11px;
  transition: 0.2s;
}
.site-link:hover {
  background: #edf5ff;
  border-color: #d8e7f8;
  color: #3d71b4;
  transform: translateY(-1px);
}
.site-link svg { width: 15px; height: 15px; }
.site-url {
  display: block;
  max-width: 100%;
  margin-top: 7px;
  color: #8a9bb0;
  font-size: 10px;
  line-height: 1.5;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.site-url:hover { color: #4d81cb; }

.table-foot {
  height: 45px;
  padding: 0 25px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f0f3f7;
  color: #a0abba;
  font-size: 10px;
}
.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 8px;
  border-radius: 50%;
  background: #78c99d;
  box-shadow: 0 0 0 3px #78c99d20;
}
.empty-state { text-align: center; color: #99a7b7 !important; padding: 35px !important; }

/* ---------- 更多 / 结尾 ---------- */
.directory-more { display: flex; justify-content: center; }
.directory-more:has(button:not([hidden])) { padding-top: 20px; }

.button {
  min-height: 38px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 11px;
  font-weight: 600;
  transition: 0.2s;
}
.button svg { width: 15px; height: 15px; }
.button.primary { background: #5e8fc9; color: #fff; box-shadow: 0 4px 12px #5e8fc933; }
.button.primary:hover { background: #4d7fb9; transform: translateY(-1px); }
.button.secondary { border-color: #e0e8f1; background: #fff; color: #71839a; }
.button.secondary:hover { border-color: #c9daee; color: #4d7db5; }
.button.ghost {
  border-color: #e4ecf5;
  background: #fff;
  color: #6b8bad;
  box-shadow: 0 4px 14px #44618a0e;
}
.button.ghost:hover { border-color: #cfe0f1; color: #3d71b4; transform: translateY(-1px); }
.button[disabled] { opacity: 0.6; pointer-events: none; }
.text-button { padding: 7px 9px; border: 0; background: transparent; color: #92a0b0; font-size: 10px; }
.text-button:hover { color: #597da9; }

.closing-note {
  padding: 37px 12px 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  color: #a4afbd;
  font-size: 10px;
  letter-spacing: 1px;
}
.closing-line { height: 1px; width: 33px; background: #e1e8f0; }

.guestbook-entry {
  width: min(1010px, calc(100% - 64px));
  margin: 0 auto 44px;
  padding: 22px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: #ffffffa8;
  border: 1px solid #e3ebf4;
  border-radius: 14px;
}
.guestbook-entry h2 { margin: 0 0 8px; font-size: 16px; color: #455d79; }
.guestbook-entry p { margin: 0; color: #8597ac; font-size: 11px; line-height: 1.8; }
.guestbook-entry > button { flex: none; white-space: nowrap; }

.site-footer {
  width: min(1010px, calc(100% - 64px));
  min-height: 78px;
  margin: auto;
  border-top: 1px solid #e9eef4;
  display: flex;
  align-items: center;
  gap: 11px;
  color: #a0adbd;
  font-size: 9px;
  letter-spacing: 0.3px;
}
.footer-brand { display: flex; align-items: center; gap: 7px; color: #718198; }
.footer-brand img { width: 20px; height: 20px; border-radius: 6px; }
.footer-brand b { font-size: 10px; }
.footer-brand > span { font-size: 8px; letter-spacing: 1px; color: #a9b4c1; }
.footer-separator { color: #ccd5df; }
.footer-end { margin-left: auto; color: #8190a3; white-space: nowrap; }

/* ---------- 编辑态 ---------- */
.editor-panel {
  margin: 0 0 14px;
  padding: 13px 15px;
  background: #eef5ff;
  border: 1px solid #dce9f8;
  border-radius: 12px;
}
.editor-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.editing-label { display: flex; align-items: center; gap: 8px; color: #71859d; font-size: 11px; }
.editing-label svg { width: 17px; height: 17px; color: #638dbe; }
.editing-label b { color: #537fb8; }
.editor-actions { display: flex; gap: 7px; align-items: center; flex-wrap: wrap; }

.nav-table input,
.nav-table select {
  display: block;
  width: 100%;
  min-width: 120px;
  height: 34px;
  margin: 0 0 5px;
  padding: 0 8px;
  border: 1px solid #dce5ef;
  border-radius: 7px;
  outline: 0;
  color: #3d526c;
  background: #fff;
  font-size: 10px;
}
.nav-table input:focus,
.nav-table select:focus { border-color: #8cb1df; }

.upload-button { position: relative; width: 46px; height: 46px; padding: 0; border: 0; background: none; }
.upload-button .site-icon-fallback { border-style: dashed; }
.row-tools { display: flex; gap: 5px; align-items: center; }
.row-tools button {
  width: 29px;
  height: 29px;
  border: 1px solid #e6edf5;
  border-radius: 7px;
  background: #fff;
  color: #7d8fa4;
  font-size: 11px;
}
.row-tools button.danger { border-color: #f0e1e1; background: #fff8f7; color: #bd7772; }
.row-tools button[disabled] { opacity: 0.4; pointer-events: none; }

.category-list { display: grid; gap: 6px; margin-bottom: 12px; }
.category-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid #e8eff6;
  border-radius: 8px;
  font-size: 11px;
  color: #4d637c;
}
.category-row button {
  width: 24px;
  height: 24px;
  border: 1px solid #f0e1e1;
  border-radius: 6px;
  background: #fff8f7;
  color: #bd7772;
  font-size: 11px;
}
.inline-add { display: flex; gap: 7px; }

/* ---------- 弹窗 ---------- */
.modal {
  width: min(420px, calc(100% - 30px));
  padding: 0;
  border: 1px solid #e9eef5;
  border-radius: 20px;
  background: #fff;
  color: #30435b;
  box-shadow: 0 22px 80px #243a572b;
}
.modal::backdrop { background: #1f334c66; backdrop-filter: blur(5px); }
.modal-content { position: relative; display: flex; flex-direction: column; padding: 36px 38px 31px; }
.modal-close {
  position: absolute;
  right: 16px;
  top: 15px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 9px;
  background: #f4f7fa;
  color: #8594a5;
  font-size: 21px;
  line-height: 1;
}
.modal-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin-bottom: 19px;
  border-radius: 13px;
  background: #edf4fe;
  color: #6795d2;
}
.modal-mark svg { width: 21px; height: 21px; }
.modal h2 { margin: 0 0 8px; font-size: 22px; }
.modal-content > p { margin: 0 0 21px; color: #8b9aab; font-size: 11px; line-height: 1.7; }
.modal-content label { margin-bottom: 8px; color: #667b94; font-size: 11px; }
.modal-content input,
.modal-content textarea {
  height: 43px;
  margin-bottom: 15px;
  padding: 0 12px;
  border: 1px solid #e1e8f0;
  border-radius: 9px;
  outline: 0;
  font-size: 12px;
}
.modal-content textarea { height: auto; padding: 10px 12px; resize: vertical; }
.modal-content input:focus,
.modal-content textarea:focus { border-color: #83a8d4; box-shadow: 0 0 0 3px #7da8da22; }
.modal-content .button { width: 100%; margin-top: 2px; }
.inline-add input { margin-bottom: 0; }
.form-error { color: #bd6a6a !important; margin: -8px 0 13px !important; }

.site-info-dialog { width: min(620px, calc(100% - 24px)); max-width: none; border-radius: 10px; }
.site-info-content {
  position: relative;
  max-height: min(82dvh, 680px);
  overflow: auto;
  padding: 27px 31px 29px;
}
.site-info-tabs {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 42px 18px;
  border-bottom: 1px solid #e9f0f6;
}
.site-info-tabs button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 8px 13px;
  border: 1px solid #dbe7f2;
  border-radius: 7px;
  background: #fff;
  color: #71869c;
  font-size: 11px;
  font-weight: 550;
}
.site-info-tabs button[aria-selected="true"] { border-color: #bbdaf1; background: #edf7ff; color: #167ec0; }
.site-info-content h2 { margin: 21px 0 12px; color: #173750; font-size: 20px; font-weight: 700; }

.guide-steps, .release-notes { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.guide-steps { counter-reset: guide-step; }
.guide-steps li {
  position: relative;
  padding: 13px 12px 13px 43px;
  border: 1px solid #e8eff6;
  border-radius: 7px;
  background: #fff;
}
.guide-steps li::before {
  counter-increment: guide-step;
  content: counter(guide-step, decimal-leading-zero);
  position: absolute;
  left: 12px;
  top: 14px;
  color: #168ee5;
  font-size: 10px;
  font-weight: 700;
}
.guide-steps strong, .release-notes strong { color: #213c51; font-size: 13px; font-weight: 650; }
.guide-steps p, .release-notes p { margin: 5px 0 0; color: #748aa0; font-size: 11px; line-height: 1.85; }
.release-notes li {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 13px;
  padding: 14px 12px;
  border: 1px solid #e8eff6;
  border-radius: 7px;
  background: #fff;
}
.release-notes li:first-child { border-color: #dbeaf6; background: #f8fbfe; }
.release-notes time { padding-top: 3px; color: #168ee5; font-size: 10px; font-weight: 600; }

.msg-list { display: grid; gap: 8px; max-height: 40vh; overflow: auto; }
.msg-item { padding: 11px 13px; border: 1px solid #eaf0f7; border-radius: 9px; background: #fbfdff; }
.msg-item b { font-size: 11px; color: #4a647f; }
.msg-item time { margin-left: 8px; font-size: 9px; color: #a6b3c1; }
.msg-item p { margin: 6px 0 0; font-size: 11px; color: #6d849c; line-height: 1.7; word-break: break-word; }

.toast {
  position: fixed;
  z-index: 100;
  left: 50%;
  bottom: max(28px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  max-width: calc(100vw - 32px);
  padding: 12px 19px;
  border-radius: 11px;
  background: #253a53ed;
  color: #fff;
  text-align: center;
  font-size: 11px;
  box-shadow: 0 8px 25px #1b2f4825;
  animation: pop-in 0.2s var(--ease);
}
@keyframes pop-in {
  from { opacity: 0; translate: 0 8px; }
  to { opacity: 1; translate: 0 0; }
}

/* ---------- 手机 ---------- */
@media (max-width: 760px) {
  .site-header { height: calc(70px + env(safe-area-inset-top)); padding: 0 23px; padding-top: env(safe-area-inset-top); }
  .header-nav { display: none; }
  .header-right { gap: 8px; }
  .update-check { width: 34px; height: 34px; padding: 0; justify-content: center; }
  .update-check > span:last-child { display: none; }
  .mascot { width: 42px; height: 42px; border-radius: 13px; }
  .mascot img { width: 34px; height: 34px; border-radius: 9px; }

  .site-info-links { width: calc(100% - 40px); min-height: 57px; gap: 7px; }
  .hero { padding: 36px 18px 47px; }
  .hero-logo-wrap { width: 108px; height: 108px; margin-bottom: 20px; }
  .hero-logo { width: 100px; height: 100px; border-radius: 24px; }
  .logo-orbit { border-radius: 31px; }
  .hero h1 { font-size: 47px; }
  .hero-description { font-size: 11px; margin-bottom: 24px; }
  .search-box { height: 48px; }

  .directory { width: calc(100% - 42px); }
  .section-heading { display: block; margin-bottom: 15px; }
  .section-title { margin-bottom: 14px; }
  .category-tabs { justify-content: flex-start; gap: 3px; }
  .category-tab { font-size: 10px; padding: 7px 10px; }

  .nav-table { width: 100%; min-width: 0; table-layout: fixed; }
  .nav-table th { height: 40px; padding: 0 8px; font-size: 9px; letter-spacing: 0.2px; }
  .nav-table th.image-column, .site-logo-cell { width: 54px; padding-left: 8px !important; padding-right: 4px !important; }
  .nav-table th.link-column { width: 101px; }
  .nav-table td { height: 72px; padding: 9px 7px; }
  .site-icon-frame { width: 34px; height: 34px; }
  .site-icon, .site-icon-fallback { width: 34px; height: 34px; border-radius: 9px; }
  .upload-button, .upload-button .site-icon-fallback { width: 34px; height: 34px; border-radius: 9px; }
  .site-name { align-items: flex-start; gap: 4px; flex-direction: column; }
  .site-name strong { max-width: 100%; font-size: 11px; overflow-wrap: anywhere; }
  .site-tag { max-width: 100%; padding: 2px 4px; font-size: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .site-description {
    display: -webkit-box;
    margin-top: 4px;
    font-size: 9px;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .site-link { min-height: 31px; justify-content: center; gap: 4px; padding: 0 5px; font-size: 9px; white-space: nowrap; }
  .site-link svg { width: 12px; height: 12px; }
  .site-url { font-size: 9px; margin-top: 6px; }
  .nav-table input, .nav-table select { min-width: 0; height: 31px; padding: 0 5px; font-size: 9px; }

  .table-foot { padding: 0 16px; font-size: 9px; }
  .closing-note { padding: 29px 0 32px; font-size: 9px; gap: 9px; }
  .closing-line { width: 18px; }
  .guestbook-entry { width: calc(100% - 40px); padding: 17px; gap: 14px; }
  .guestbook-entry h2 { font-size: 14px; }
  .guestbook-entry p { font-size: 10px; }
  .site-footer {
    width: calc(100% - 42px);
    min-height: 67px;
    gap: 8px;
    font-size: 8px;
    flex-wrap: wrap;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .editor-toolbar { align-items: flex-start; flex-direction: column; }
  .editor-actions { width: 100%; }
  .editor-actions .button { flex: 1; padding: 0 8px; font-size: 10px; }
  .modal-content { padding: 32px 26px 25px; }
  .site-info-content { padding: 22px 19px; }
  .site-info-content h2 { font-size: 18px; }
  .release-notes li { grid-template-columns: 76px minmax(0, 1fr); gap: 8px; padding: 12px 9px; }
  .guide-steps li { padding: 12px 9px 12px 37px; }
  .guide-steps li::before { left: 10px; top: 13px; }
}

@media (max-width: 420px) {
  .site-header { padding: 0 18px; }
  .header-right { gap: 9px; }
  .brand { gap: 8px; font-size: 12px; }
  .brand img { width: 30px; height: 30px; }
  .brand small { font-size: 8px; }
  .hero { padding-top: 29px; }
  .hero h1 { font-size: 42px; }
  .hero-logo-wrap { width: 98px; height: 98px; }
  .hero-logo { width: 91px; height: 91px; }
  .hero-description { letter-spacing: 0.3px; }
  .search-box kbd { display: none; }
  .directory { width: calc(100% - 24px); }
  .section-title h2 { font-size: 17px; }
  .category-tab { padding: 7px 9px; font-size: 9px; }
  .table-shell { border-radius: 12px; }
  .nav-table th.image-column, .site-logo-cell { width: 47px; padding-left: 6px !important; padding-right: 3px !important; }
  .nav-table th.link-column { width: 94px; }
  .nav-table td { padding-left: 5px; padding-right: 5px; }
  .site-icon-frame, .site-icon, .site-icon-fallback { width: 32px; height: 32px; }
  .site-link { gap: 3px; padding: 0 3px; font-size: 8px; }
  .table-foot-right { display: none; }
  .guestbook-entry { width: calc(100% - 24px); align-items: flex-start; flex-direction: column; }
  .site-footer { width: calc(100% - 32px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
