:root {
  --ink: #17201d;
  --muted: #65706b;
  --line: #dce2de;
  --soft-line: #e9eeeb;
  --paper: #ffffff;
  --canvas: #f4f6f3;
  --soft-green: #e8f4ee;
  --green: #14785d;
  --deep-green: #0b5743;
  --amber: #ad6b13;
  --soft-amber: #fff2dc;
  --blue: #315f91;
  --danger: #b43c36;
  --shadow: 0 16px 42px rgba(28, 41, 35, 0.09);
  color-scheme: light;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  font-synthesis: none;
  letter-spacing: 0;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-size: 15px;
  line-height: 1.65;
}

button,
input,
textarea {
  font: inherit;
  letter-spacing: 0;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid rgba(20, 120, 93, 0.25);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 10px;
  left: 10px;
  padding: 8px 12px;
  border-radius: 4px;
  color: white;
  background: var(--ink);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
}

.header-inner,
.footer-inner {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.header-inner {
  display: grid;
  grid-template-columns: minmax(190px, 1fr) minmax(340px, 520px) minmax(190px, 1fr);
  align-items: center;
  min-height: 76px;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: max-content;
  font-weight: 750;
}

.brand-mark {
  display: block;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  overflow: hidden;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.55);
}

.brand-name {
  white-space: nowrap;
}

.header-contact {
  display: grid;
  justify-self: end;
  gap: 1px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
  white-space: nowrap;
}

.header-contact a,
.header-contact p {
  display: flex;
  gap: 7px;
  margin: 0;
}

.header-contact strong {
  color: var(--ink);
  font-weight: 650;
}

.header-contact a:hover strong {
  color: var(--green);
}

.search-box {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 46px;
  padding-left: 14px;
  overflow: hidden;
  border: 1px solid #cbd4cf;
  border-radius: 6px;
  background: #f8faf8;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.search-box:focus-within {
  border-color: var(--green);
  background: white;
  box-shadow: 0 0 0 4px rgba(20, 120, 93, 0.1);
}

.search-icon {
  width: 19px;
  height: 19px;
  color: #78837e;
}

.search-box input {
  width: 100%;
  height: 44px;
  padding: 0 10px;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
}

.search-box input::placeholder,
input::placeholder,
textarea::placeholder {
  color: #929b97;
}

.search-box input::-webkit-search-cancel-button {
  cursor: pointer;
}

.search-submit {
  align-self: stretch;
  min-width: 68px;
  border: 0;
  border-left: 1px solid var(--line);
  color: white;
  background: var(--ink);
  cursor: pointer;
  font-weight: 650;
  transition: background 160ms ease;
}

.search-submit:hover {
  background: var(--deep-green);
}

.view-shell,
.detail-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.view-shell {
  padding: 54px 0 72px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 248px;
  align-items: start;
  gap: 64px;
}

.section-heading-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  min-height: 74px;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 2px solid var(--ink);
}

.section-kicker {
  margin: 0 0 3px;
  color: var(--green);
  font-size: 12px;
  font-weight: 750;
}

.section-heading-row h1,
.admin-title-row h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.25;
}

.result-meta {
  margin: 0 0 3px;
  color: var(--muted);
  font-size: 13px;
}

.question-list {
  border-bottom: 1px solid var(--line);
}

.question-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 158px 22px;
  align-items: center;
  min-height: 172px;
  gap: 24px;
  padding: 25px 5px 25px 2px;
  border-top: 1px solid var(--line);
  transition: background 160ms ease, padding 160ms ease;
}

.question-row:first-child {
  border-top: 0;
}

.question-row:hover {
  margin-inline: -14px;
  padding-inline: 16px 14px;
  background: var(--paper);
}

.question-row:focus-visible {
  border-radius: 4px;
}

.question-row-content {
  min-width: 0;
}

.question-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
}

.tag,
.topic-button {
  border: 1px solid #d3dfd9;
  border-radius: 999px;
  color: var(--deep-green);
  background: #f8fbf9;
  font-size: 12px;
  font-weight: 650;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 2px 9px;
}

.question-row h2 {
  margin: 0 0 8px;
  font-size: 19px;
  line-height: 1.42;
  transition: color 160ms ease;
}

.question-row:hover h2 {
  color: var(--green);
}

.question-summary {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.question-thumbnail {
  width: 158px;
  height: 104px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #e5e9e6;
}

.question-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}

.question-row:hover .question-thumbnail img {
  transform: scale(1.025);
}

.row-arrow {
  width: 20px;
  height: 20px;
  color: #89948f;
  transition: color 160ms ease, transform 160ms ease;
}

.question-row:hover .row-arrow {
  color: var(--green);
  transform: translateX(3px);
}

.question-row.no-thumbnail {
  grid-template-columns: minmax(0, 1fr) 22px;
  min-height: 150px;
}

.topic-sidebar {
  position: sticky;
  top: 112px;
  padding-top: 16px;
}

.topic-heading {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
}

.topic-heading svg {
  width: 18px;
  height: 18px;
  color: var(--amber);
}

.topic-heading h2 {
  margin: 0;
  font-size: 15px;
}

.topic-list {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}

.topic-button {
  min-height: 32px;
  padding: 5px 11px;
  cursor: pointer;
}

.topic-button:hover,
.topic-button.active {
  border-color: var(--green);
  color: white;
  background: var(--green);
}

.sidebar-note {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 22px;
  color: var(--muted);
  font-size: 12px;
}

.sidebar-note p {
  margin: 0;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4aaa7e;
  box-shadow: 0 0 0 4px rgba(74, 170, 126, 0.12);
}

.loading-list {
  border-bottom: 1px solid var(--line);
}

.skeleton-row {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 150px;
  gap: 12px;
  border-top: 1px solid var(--line);
}

.skeleton-row:first-child {
  border-top: 0;
}

.skeleton-row span,
.detail-loading span {
  display: block;
  height: 12px;
  border-radius: 3px;
  background: #e3e8e5;
  animation: pulse 1.4s ease-in-out infinite alternate;
}

.skeleton-row span:first-child {
  width: 22%;
  height: 9px;
}

.skeleton-row span:nth-child(2) {
  width: 72%;
  height: 20px;
}

.skeleton-row span:last-child {
  width: 91%;
}

@keyframes pulse {
  to { opacity: 0.42; }
}

.empty-state {
  display: grid;
  min-height: 360px;
  place-items: center;
  align-content: center;
  padding: 36px;
  text-align: center;
  border-bottom: 1px solid var(--line);
}

.empty-state svg {
  width: 34px;
  height: 34px;
  margin-bottom: 15px;
  color: #89948f;
}

.empty-state h2 {
  margin: 0 0 4px;
  font-size: 18px;
}

.empty-state p {
  margin: 0 0 20px;
  color: var(--muted);
}

.secondary-button,
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 16px;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 700;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.secondary-button {
  border: 1px solid #bdc7c2;
  background: white;
}

.secondary-button:hover {
  border-color: #89958f;
  background: #f8faf9;
}

.primary-button {
  border: 1px solid var(--green);
  color: white;
  background: var(--green);
}

.primary-button:hover {
  border-color: var(--deep-green);
  background: var(--deep-green);
}

.detail-shell {
  max-width: 900px;
  min-height: calc(100vh - 150px);
  padding: 38px 0 80px;
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  margin-bottom: 34px;
  padding: 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.back-button:hover {
  color: var(--green);
}

.back-button svg {
  width: 18px;
  height: 18px;
}

.detail-header {
  padding-bottom: 34px;
  border-bottom: 1px solid var(--line);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 16px;
}

.detail-header h1 {
  max-width: 820px;
  margin: 0 0 16px;
  font-size: 34px;
  line-height: 1.34;
}

.detail-date {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.qa-section {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: 0 28px;
  padding: 42px 0;
  border-bottom: 1px solid var(--line);
}

.answer-section {
  margin-top: 16px;
  padding-inline: 28px;
  border: 1px solid #cfe0d7;
  border-left: 4px solid var(--green);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 0 8px 24px rgba(29, 57, 45, 0.05);
}

.qa-label {
  display: flex;
  align-items: center;
  align-self: start;
  gap: 10px;
}

.qa-label h2 {
  margin: 0;
  font-size: 14px;
}

.qa-letter {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 5px;
  font-family: Georgia, serif;
  font-size: 17px;
  font-weight: 700;
}

.question-letter {
  color: #294a6d;
  background: #e8eff6;
}

.answer-letter {
  color: var(--deep-green);
  background: var(--soft-green);
}

.rich-copy {
  grid-column: 2;
  min-width: 0;
  color: #26312c;
  font-size: 16px;
  line-height: 1.9;
}

.rich-copy p {
  margin: 0 0 18px;
  white-space: pre-wrap;
}

.rich-copy p:last-child {
  margin-bottom: 0;
}

.rich-copy a {
  color: var(--green);
  font-weight: 650;
  overflow-wrap: anywhere;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.rich-copy a:hover {
  color: var(--deep-green);
}

.content-images {
  display: grid;
  grid-column: 2;
  gap: 18px;
  margin-top: 26px;
}

.content-image {
  margin: 0;
}

.content-image img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #edf0ee;
}

.content-image figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.detail-loading {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 40px 0;
}

.detail-loading span:first-child {
  width: 30%;
}

.detail-loading span:nth-child(2) {
  width: 82%;
  height: 34px;
}

.detail-loading span:last-child {
  width: 66%;
}

.compact-empty {
  min-height: 320px;
}

.pinned-guide {
  position: fixed;
  z-index: 15;
  right: 20px;
  bottom: 20px;
  width: min(284px, calc(100% - 28px));
  padding: 15px 17px;
  border: 1px solid #cbd8d1;
  border-left: 4px solid var(--green);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 12px 30px rgba(28, 41, 35, 0.16);
  backdrop-filter: blur(12px);
}

.pinned-guide-label {
  margin: 0 0 3px;
  color: var(--green);
  font-size: 11px;
  font-weight: 750;
}

.pinned-guide-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 17px;
  font-weight: 750;
  line-height: 1.4;
}

.pinned-guide-title svg {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  color: var(--green);
}

.pinned-guide-title:hover,
.pinned-guide-site:hover strong {
  color: var(--green);
}

.pinned-guide-site {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 9px;
  padding-top: 9px;
  border-top: 1px solid var(--soft-line);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.pinned-guide-site strong {
  color: var(--ink);
  font-weight: 650;
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: #eef1ee;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
  font-size: 12px;
}

.footer-inner a:hover {
  color: var(--green);
}

/* Admin */
.admin-body {
  background: #f5f6f4;
}

.admin-header {
  border-bottom: 1px solid var(--line);
  background: white;
}

.admin-header-inner {
  display: flex;
  align-items: center;
  width: min(1080px, calc(100% - 40px));
  min-height: 72px;
  margin: 0 auto;
}

.admin-divider {
  width: 1px;
  height: 22px;
  margin: 0 18px;
  background: var(--line);
}

.admin-area-name {
  color: var(--muted);
  font-size: 14px;
}

.view-site-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  color: var(--green);
  font-size: 13px;
  font-weight: 700;
}

.view-site-link svg {
  width: 17px;
  height: 17px;
  transition: transform 160ms ease;
}

.view-site-link:hover svg {
  transform: translateX(3px);
}

.admin-logout {
  min-height: 34px;
  margin-left: 18px;
  padding: 5px 11px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  background: white;
  cursor: pointer;
  font-size: 12px;
}

.admin-logout:hover {
  border-color: #aeb9b3;
  color: var(--danger);
}

.admin-body:not(.is-authenticated) .admin-main {
  display: none;
}

.login-main {
  display: grid;
  min-height: calc(100vh - 73px);
  padding: 48px 20px;
  place-items: center;
}

.admin-body.is-authenticated .login-main {
  display: none;
}

.login-surface {
  width: min(420px, 100%);
  padding: 38px;
  border-top: 3px solid var(--ink);
  border-radius: 6px;
  background: white;
  box-shadow: var(--shadow);
}

.login-icon {
  display: grid;
  width: 44px;
  height: 44px;
  margin-bottom: 22px;
  place-items: center;
  border-radius: 6px;
  color: var(--deep-green);
  background: var(--soft-green);
}

.login-icon svg {
  width: 22px;
  height: 22px;
}

.login-surface h1 {
  margin: 0 0 28px;
  font-size: 26px;
  line-height: 1.3;
}

.login-form {
  display: grid;
  gap: 20px;
}

.password-field {
  position: relative;
}

.password-field input {
  padding-right: 48px;
}

.password-field button {
  position: absolute;
  top: 5px;
  right: 5px;
  display: grid;
  width: 34px;
  height: 34px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 4px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.password-field button:hover {
  color: var(--green);
  background: var(--soft-green);
}

.password-field svg {
  width: 18px;
  height: 18px;
}

.login-status {
  min-height: 22px;
  margin: -5px 0 -6px;
  color: var(--danger);
  font-size: 12px;
}

.login-button {
  width: 100%;
  gap: 8px;
}

.login-button svg {
  width: 18px;
  height: 18px;
}

.admin-main {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
  padding: 48px 0 90px;
}

.admin-title-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 28px;
}

.required-note {
  margin: 0 0 3px;
  color: var(--muted);
  font-size: 12px;
}

.required-note span,
.field b {
  color: var(--danger);
}

.editor-form {
  border-top: 2px solid var(--ink);
}

.form-section {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 44px;
  padding: 40px 28px;
  border-bottom: 1px solid var(--line);
  background: white;
}

.form-section-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.form-section-heading > span {
  color: var(--green);
  font-family: Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
}

.form-section-heading h2 {
  margin: -3px 0 3px;
  font-size: 17px;
}

.form-section-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.form-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.full-field {
  grid-column: 1 / -1;
}

.field {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field > span,
.field-title-row > span:first-child,
.image-alt-field > span {
  font-size: 13px;
  font-weight: 700;
}

.field b {
  font-weight: 700;
}

.field input,
.field textarea,
.media-panel input,
.image-alt-field input {
  width: 100%;
  border: 1px solid #cbd4cf;
  border-radius: 5px;
  outline: 0;
  color: var(--ink);
  background: #fbfcfb;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.field input,
.media-panel input,
.image-alt-field input {
  min-height: 44px;
  padding: 9px 12px;
}

.field textarea {
  min-height: 96px;
  padding: 11px 12px;
  resize: vertical;
  line-height: 1.7;
}

.field textarea[name="questionText"] {
  min-height: 180px;
}

.field textarea[name="answerText"] {
  min-height: 250px;
}

.field input:focus,
.field textarea:focus,
.media-panel input:focus,
.image-alt-field input:focus {
  border-color: var(--green);
  background: white;
  box-shadow: 0 0 0 3px rgba(20, 120, 93, 0.1);
}

.field small {
  align-self: flex-end;
  color: var(--muted);
  font-size: 11px;
}

.media-editor {
  padding-top: 5px;
}

.field-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.optional-label {
  color: var(--muted);
  font-size: 11px;
}

.segmented-control {
  display: inline-grid;
  grid-template-columns: repeat(2, 96px);
  align-self: start;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #f0f3f1;
}

.segment {
  min-height: 32px;
  border: 0;
  border-radius: 3px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  font-size: 12px;
}

.segment.active {
  color: var(--ink);
  background: white;
  box-shadow: 0 1px 4px rgba(29, 42, 36, 0.1);
  font-weight: 700;
}

.upload-zone {
  display: grid;
  min-height: 142px;
  place-items: center;
  align-content: center;
  border: 1px dashed #b9c6c0;
  border-radius: 5px;
  background: #f8faf8;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease;
}

.upload-zone:hover {
  border-color: var(--green);
  background: #f2f8f5;
}

.upload-zone svg {
  width: 25px;
  height: 25px;
  margin-bottom: 8px;
  color: var(--green);
}

.upload-zone > span {
  font-size: 13px;
  font-weight: 700;
}

.upload-zone small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.upload-zone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.image-alt-field {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.image-preview {
  position: relative;
  width: min(100%, 520px);
  margin: 4px 0 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #eef1ef;
}

.image-preview img {
  display: block;
  width: 100%;
  max-height: 320px;
  object-fit: contain;
}

.image-preview button {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  width: 34px;
  height: 34px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 4px;
  color: white;
  background: rgba(23, 32, 29, 0.78);
  cursor: pointer;
}

.image-preview button:hover {
  background: var(--danger);
}

.image-preview button svg {
  width: 17px;
  height: 17px;
}

.access-section {
  padding-bottom: 34px;
}

.token-field {
  max-width: 420px;
}

.form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 92px;
  gap: 24px;
  padding: 18px 28px;
  border-bottom-right-radius: 6px;
  border-bottom-left-radius: 6px;
  background: #edf1ee;
}

.form-actions p {
  margin: 0;
  color: var(--danger);
  font-size: 13px;
}

.form-actions .primary-button {
  min-width: 132px;
}

.form-actions svg,
.dialog-actions svg {
  width: 18px;
  height: 18px;
  margin-right: 7px;
}

.primary-button:disabled {
  border-color: #9fa8a4;
  background: #9fa8a4;
  cursor: wait;
}

.success-dialog {
  position: fixed;
  z-index: 50;
  inset: 0;
  display: grid;
  padding: 20px;
  place-items: center;
  background: rgba(20, 29, 25, 0.58);
  backdrop-filter: blur(4px);
}

.dialog-surface {
  width: min(430px, 100%);
  padding: 38px;
  border-radius: 7px;
  background: white;
  box-shadow: var(--shadow);
  text-align: center;
}

.success-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin: 0 auto 18px;
  place-items: center;
  border-radius: 50%;
  color: var(--green);
  background: var(--soft-green);
}

.success-icon svg {
  width: 28px;
  height: 28px;
}

.dialog-surface h2 {
  margin: 0 0 5px;
  font-size: 22px;
}

.dialog-surface > p {
  margin: 0 0 26px;
  color: var(--muted);
}

.dialog-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.not-found-page {
  display: grid;
  min-height: 100vh;
  padding: 30px;
  place-items: center;
  background: white;
}

.not-found-page main {
  text-align: center;
}

.not-found-page .brand {
  margin-bottom: 52px;
}

.error-code {
  margin: 0;
  color: var(--green);
  font-family: Consolas, monospace;
  font-size: 64px;
  font-weight: 800;
  line-height: 1;
}

.not-found-page h1 {
  margin: 14px 0 6px;
}

.not-found-page main > p:not(.error-code) {
  margin: 0 0 24px;
  color: var(--muted);
}

@media (max-width: 900px) {
  .header-inner {
    grid-template-columns: minmax(160px, 1fr) minmax(280px, 440px) minmax(160px, 1fr);
    gap: 20px;
  }

  .brand-name {
    display: none;
  }

  .content-grid {
    grid-template-columns: minmax(0, 1fr) 205px;
    gap: 36px;
  }

  .form-section {
    grid-template-columns: 170px minmax(0, 1fr);
    gap: 28px;
  }
}

@media (max-width: 720px) {
  .header-inner,
  .footer-inner,
  .view-shell,
  .detail-shell,
  .admin-header-inner,
  .admin-main {
    width: min(100% - 28px, 1180px);
  }

  .header-inner {
    grid-template-columns: auto minmax(0, 1fr);
    min-height: 120px;
    gap: 10px 14px;
    padding: 12px 0;
  }

  .brand-name {
    display: inline;
    font-size: 14px;
  }

  .search-box {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .header-contact {
    grid-column: 2;
    grid-row: 1;
  }

  .view-shell {
    padding: 34px 0 56px;
  }

  .content-grid {
    display: block;
  }

  .topic-sidebar {
    position: static;
    margin-top: 36px;
    padding: 24px 0;
    border-top: 1px solid var(--line);
  }

  .sidebar-note {
    display: none;
  }

  .question-row,
  .question-row.no-thumbnail {
    grid-template-columns: minmax(0, 1fr) 18px;
    min-height: 142px;
    gap: 12px;
    padding-block: 22px;
  }

  .question-thumbnail {
    display: none;
  }

  .question-row h2 {
    font-size: 17px;
  }

  .detail-shell {
    padding-top: 26px;
  }

  .detail-header h1 {
    font-size: 27px;
  }

  .qa-section {
    display: block;
    padding: 30px 0;
  }

  .answer-section {
    margin-inline: -7px;
    padding-inline: 18px;
  }

  .qa-label {
    margin-bottom: 18px;
  }

  .rich-copy,
  .content-images {
    grid-column: auto;
  }

  .admin-header-inner .brand-name {
    display: none;
  }

  .admin-divider {
    margin-inline: 12px;
  }

  .admin-main {
    padding-top: 32px;
  }

  .form-section {
    display: block;
    padding: 28px 18px 32px;
  }

  .form-section-heading {
    margin-bottom: 26px;
  }

  .form-fields {
    display: block;
  }

  .form-fields > * + * {
    margin-top: 22px;
  }

  .form-actions {
    align-items: stretch;
    flex-direction: column;
    padding: 18px;
  }

  .form-actions .primary-button {
    width: 100%;
  }
}

@media (max-width: 430px) {
  .pinned-guide {
    right: 12px;
    bottom: 12px;
    width: calc(100% - 24px);
    padding: 11px 13px;
  }

  .pinned-guide-label {
    display: none;
  }

  .pinned-guide-title {
    font-size: 15px;
  }

  .pinned-guide-site {
    margin-top: 5px;
    padding-top: 5px;
  }

  .brand-name {
    max-width: 138px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header-contact {
    font-size: 13px;
  }

  .search-submit {
    min-width: 60px;
  }

  .section-heading-row {
    align-items: flex-start;
  }

  .section-heading-row h1,
  .admin-title-row h1 {
    font-size: 24px;
  }

  .question-meta .tag:nth-of-type(n + 3) {
    display: none;
  }

  .admin-area-name,
  .admin-divider {
    display: none;
  }

  .admin-title-row {
    align-items: flex-start;
  }

  .required-note {
    padding-top: 7px;
  }

  .image-alt-field {
    display: block;
  }

  .image-alt-field span {
    display: block;
    margin-bottom: 7px;
  }

  .dialog-actions {
    flex-direction: column;
  }
}

@media (max-width: 350px) {
  .header-inner {
    grid-template-columns: 1fr;
    min-height: 166px;
  }

  .brand,
  .header-contact,
  .search-box {
    grid-column: 1;
  }

  .brand {
    grid-row: 1;
  }

  .header-contact {
    grid-row: 2;
    justify-self: start;
  }

  .search-box {
    grid-row: 3;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
