.support-guide {
  background: #f5f6f8;
  color: #303845;
  padding: 0 0 56px;
  font-size: 16px;
  line-height: 1.7;
  min-height: 70vh;
}

.support-guide * { box-sizing: border-box; }
.support-guide [hidden] { display: none !important; }
.support-guide .container { max-width: 1180px; width: 100%; padding: 0 24px; margin: auto; }
.support-guide a { color: #bc2335; }

.sg-intro {
  background: #fff;
  border-top: 1px solid #e7e9ed;
  border-bottom: 1px solid #e1e4e8;
  padding: 18px 0 22px;
  margin-bottom: 24px;
  box-shadow: 0 3px 10px rgba(35, 45, 55, .035);
}

.sg-heading { margin-bottom: 18px; }
.sg-heading h1 { font-size: 32px; line-height: 1.3; margin: 0 0 8px; font-weight: 600; }
.sg-heading p { margin: 0; color: #68717d; }

.sg-search {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr) auto;
  grid-template-areas: "label input clear" ". count count";
  align-items: center;
  gap: 8px 12px;
  background: #f7f8fa;
  padding: 14px 16px;
  border: 1px solid #e4e7eb;
  border-radius: 7px;
  margin: 0;
}

.sg-search label { grid-area: label; display: block; font-weight: 600; margin: 0; }
.sg-search input { grid-area: input; width: 100%; font: inherit; padding: 10px 14px; border: 1px solid #cdd2d9; border-radius: 5px; background: #fff; }
.sg-search button { grid-area: clear; font: inherit; color: #bc2335; background: #fff; border: 1px solid #dcdfe4; border-radius: 5px; padding: 9px 14px; margin: 0; cursor: pointer; }
#sg-count { grid-area: count; margin: 0; font-size: 14px; color: #68717d; }

.sg-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 24px; align-items: start; }
.sg-sidebar { position: sticky; top: 90px; max-height: calc(100vh - 110px); overflow: auto; background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; padding: 18px; }
.sg-sidebar h2 { font-size: 18px; font-weight: 600; margin: 0 0 14px; }
.sg-group { border-top: 1px solid #eef0f2; padding: 12px 0; }
.sg-group summary { cursor: pointer; font-weight: 600; line-height: 1.5; padding: 4px 0; }
.sg-badge { font-size: 13px; background: #f2f3f5; color: #65707b; padding: 2px 7px; border-radius: 12px; }
.sg-link { display: block; padding: 9px 12px; margin: 4px 0; border-radius: 5px; color: #505966 !important; font-size: 16px; line-height: 1.5; }
.sg-link:hover,
.sg-link[aria-current] { background: #fff0f2; color: #b61e32 !important; text-decoration: none; }

.sg-article { background: #fff; border: 1px solid #e5e7eb; border-radius: 8px; padding: 28px; margin-bottom: 20px; scroll-margin-top: 100px; }
.sg-article > header { border-bottom: 1px solid #eceef1; margin-bottom: 22px; padding-bottom: 16px; }
.sg-article h2 { font-size: 24px; line-height: 1.4; font-weight: 600; margin: 0; }
.sg-body { overflow-wrap: anywhere; overflow-x: auto; }
.sg-body p { line-height: 1.8; }
.sg-body img,
.sg-article figure img { max-width: 100% !important; height: auto !important; }
.sg-article figure { margin: 22px 0; }
.sg-back { display: inline-block; margin-top: 22px; font-size: 14px; }
.sg-empty { padding: 32px; background: #fff; border: 1px dashed #d4d8df; border-radius: 8px; }
.sg-empty h2 { font-size: 22px; }
.support-guide :is(a, button, input, summary):focus-visible { outline: 3px solid #d65a6c; outline-offset: 3px; }
#sg-query { scroll-margin-top: 110px; }

@media (max-width: 767px) {
  .support-guide .container { padding: 0 16px; }
  .sg-intro { padding: 14px 0 18px; margin-bottom: 16px; }
  .sg-heading { margin-bottom: 16px; }
  .sg-heading h1 { font-size: 28px; }
  .sg-search { grid-template-columns: 1fr auto; grid-template-areas: "label label" "input clear" "count count"; padding: 13px; }
  .sg-layout { grid-template-columns: 1fr; gap: 16px; }
  .sg-sidebar { position: static; max-height: 320px; }
  .sg-article { padding: 18px; }
  .sg-article h2 { font-size: 22px; }
}

@media (max-width: 480px) {
  .sg-search { grid-template-columns: 1fr; grid-template-areas: "label" "input" "clear" "count"; }
  .sg-search button { justify-self: start; }
}
