/* Editorial guide layout layered over the shared service-page foundation. */
body.guide-page .page-hero {
  padding-bottom: clamp(3.5rem, 6vw, 5rem) !important;
}

.guide-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1.25rem;
  margin: 0 0 1.5rem;
  color: var(--muted-strong);
  font-size: 0.92rem;
  line-height: 1.5;
}

.guide-meta span {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.guide-meta span::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--detail-accent);
  content: "";
}

.guide-overview {
  padding: 2.5rem 2rem !important;
  border-bottom: 1px solid var(--line);
  background: var(--soft) !important;
}

.guide-overview-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.guide-overview h2 {
  margin: 0 0 1rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.25rem;
  line-height: 1.3;
}

.guide-toc {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.guide-toc a {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  color: var(--muted-strong);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.45;
  text-decoration: none;
}

.guide-toc a::before {
  color: var(--detail-accent);
  content: "→";
}

.guide-toc a:hover,
.guide-toc a:focus-visible {
  color: var(--detail-accent);
}

.guide-toc a:focus-visible {
  outline: 2px solid var(--detail-accent);
  outline-offset: 4px;
}

.guide-article {
  padding: clamp(3.5rem, 6vw, 5.5rem) 2rem !important;
  background: var(--white) !important;
}

.guide-article-inner {
  display: grid;
  grid-template-columns: minmax(0, 820px) minmax(230px, 300px);
  gap: clamp(3rem, 7vw, 6rem);
  align-items: start;
  max-width: 1240px;
  margin: 0 auto;
}

.guide-content {
  min-width: 0;
}

.guide-section {
  padding: 0 0 3rem;
  scroll-margin-top: 92px;
}

.guide-section + .guide-section {
  padding-top: 3rem;
  border-top: 1px solid var(--line);
}

.guide-section h2 {
  margin: 0 0 1rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  line-height: 1.18;
}

.guide-section h3 {
  margin: 1.8rem 0 0.65rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.18rem;
  line-height: 1.3;
}

.guide-section p,
.guide-section li {
  color: var(--text-body);
  font-size: 1rem;
  line-height: 1.75;
}

.guide-section p + p {
  margin-top: 1rem;
}

.guide-section ul,
.guide-section ol {
  margin: 1rem 0 0;
  padding-left: 1.3rem;
}

.guide-section li + li {
  margin-top: 0.6rem;
}

.guide-section a,
.guide-sidebar a {
  color: var(--detail-accent);
  font-weight: 700;
  text-underline-offset: 0.18em;
}

.guide-media {
  margin: 1.5rem 0 1.8rem;
}

.guide-media picture,
.guide-media img {
  display: block;
  width: 100%;
}

.guide-media img {
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.12);
}

.guide-media figcaption {
  margin-top: 0.65rem;
  color: var(--gray-dark);
  font-size: 0.88rem;
  line-height: 1.55;
}

.guide-step-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.6rem;
}

.guide-step {
  min-height: 100%;
  padding: 1.4rem;
  border: 1px solid var(--line);
  border-top: 3px solid var(--detail-accent);
  border-radius: 8px;
  background: var(--white);
}

.guide-step-number {
  display: block;
  margin-bottom: 0.6rem;
  color: var(--detail-accent);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.guide-step h3 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
}

.guide-step p {
  font-size: 0.94rem;
  line-height: 1.65;
}

.guide-table-wrap {
  margin-top: 1.5rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.guide-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
}

.guide-table th,
.guide-table td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.guide-table th {
  background: var(--soft);
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 850;
}

.guide-table td {
  color: var(--text-body);
  font-size: 0.92rem;
  line-height: 1.55;
}

.guide-table tbody tr:last-child td {
  border-bottom: 0;
}

.guide-note {
  margin-top: 1.5rem;
  padding: 1.2rem 1.35rem;
  border-left: 4px solid var(--detail-accent);
  border-radius: 0 8px 8px 0;
  background: var(--detail-accent-soft);
}

.guide-note strong {
  color: var(--ink);
}

.guide-note p {
  margin: 0;
  color: var(--muted-strong);
  font-size: 0.94rem;
  line-height: 1.65;
}

.guide-sidebar {
  position: sticky;
  top: 96px;
  padding-left: 1.5rem;
  border-left: 3px solid var(--detail-accent);
}

.guide-sidebar h2 {
  margin: 0 0 0.85rem;
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.3;
}

.guide-sidebar p,
.guide-sidebar li {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.65;
}

.guide-sidebar ul {
  margin: 0.75rem 0 0;
  padding-left: 1.1rem;
}

.guide-sidebar li + li {
  margin-top: 0.45rem;
}

.guide-sources {
  padding: clamp(3.5rem, 6vw, 5rem) 2rem !important;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--soft) !important;
}

.guide-sources-inner {
  max-width: 1240px;
  margin: 0 auto;
}

.guide-source-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}

.guide-source {
  padding-top: 1rem;
  border-top: 3px solid var(--detail-accent);
}

.guide-source h3 {
  margin: 0 0 0.5rem;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.35;
}

.guide-source p {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

.guide-source a {
  color: var(--detail-accent);
  font-size: 0.88rem;
  font-weight: 800;
  text-underline-offset: 0.18em;
}

.guide-disclaimer {
  max-width: 920px;
  margin-top: 2rem;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.65;
}

@media (max-width: 980px) {
  .guide-toc {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .guide-article-inner {
    grid-template-columns: 1fr;
  }

  .guide-sidebar {
    position: static;
    order: -1;
    padding-left: 1.25rem;
  }

  .guide-source-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .guide-overview,
  .guide-article,
  .guide-sources {
    padding-right: 1.25rem !important;
    padding-left: 1.25rem !important;
  }

  .guide-toc,
  .guide-step-list {
    grid-template-columns: 1fr;
  }

  .guide-meta {
    flex-direction: column;
    gap: 0.45rem;
  }

  .guide-table {
    min-width: 620px;
  }
}
