.seo-content-body {
  min-width: 0;
  padding-bottom: max(36px, env(safe-area-inset-bottom));
}

.seo-content-page {
  width: min(100%, 960px);
  margin: 0 auto;
  padding: 0 24px;
}

.seo-content-header {
  padding: 44px 0 28px;
  border-bottom: 2px solid #1a1410;
}

.seo-content-header .site-name {
  margin-bottom: 14px;
}

.seo-content-header h1 {
  max-width: 760px;
  font-size: clamp(30px, 5vw, 52px);
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.seo-content-lead {
  max-width: 720px;
  margin: 24px 0 0;
  color: #3a3330;
  font-size: 17px;
  line-height: 1.85;
}

.seo-primary-entry {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 22px;
  padding: 12px 22px;
  border: 2px solid #1a1410;
  background: #c8341e;
  color: #fffaf1;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none;
  box-shadow: 4px 4px 0 #1a1410;
  transition: transform 120ms ease, box-shadow 120ms ease;
}

.seo-primary-entry:hover {
  color: #fffaf1;
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #1a1410;
}

.seo-section-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 26px 0 8px;
}

.seo-section-nav a {
  padding: 8px 12px;
  border: 1px solid #cfc4b7;
  background: #fff;
  color: #3a3330;
  font-size: 13px;
  line-height: 1.4;
  text-decoration: none;
}

.seo-section-nav a:hover {
  border-color: #c8341e;
  color: #c8341e;
}

.seo-content-main {
  padding: 24px 0 0;
}

.seo-content-section {
  scroll-margin-top: 16px;
  padding: 38px 0;
  border-bottom: 1px solid #ded5ca;
}

.seo-section-heading {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 16px;
  align-items: baseline;
  margin-bottom: 20px;
}

.seo-section-index {
  color: #c8341e;
  font-family: "Bebas Neue", sans-serif;
  font-size: 18px;
  letter-spacing: 0.08em;
}

.seo-section-heading h2 {
  font-size: clamp(22px, 3.4vw, 30px);
  line-height: 1.3;
}

.seo-section-heading p {
  grid-column: 2;
  max-width: 680px;
  color: #6d625a;
  font-size: 14px;
  line-height: 1.7;
}

.seo-quote-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.seo-quote-card {
  display: flex;
  min-width: 0;
  min-height: 164px;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
  border: 1px solid #d8cec1;
  border-left: 4px solid #c8341e;
  background: #fff;
  box-shadow: 0 8px 22px rgba(43, 31, 22, 0.05);
}

.seo-quote-text {
  overflow-wrap: anywhere;
  color: #1a1410;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.72;
  user-select: text;
}

.seo-quote-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.seo-copy-button {
  min-width: 104px;
  min-height: 42px;
  padding: 9px 16px;
  border: 1px solid #1a1410;
  background: #1a1410;
  color: #fffaf1;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}

.seo-copy-button[data-copy-state="success"] {
  border-color: #1a1410;
  background: #1a1410;
  color: #fffaf1;
}

.seo-copy-button[data-copy-state="failed"] {
  border-color: #9f2d21;
  background: #fff8f2;
  color: #9f2d21;
}

.seo-quote-number {
  color: #8c8179;
  font-family: "Bebas Neue", sans-serif;
  font-size: 13px;
  letter-spacing: 0.1em;
}

.seo-section-next {
  display: flex;
  justify-content: flex-end;
  margin-top: 18px;
}

.seo-section-next a {
  color: #9f2d21;
  font-size: 14px;
  font-weight: 700;
  text-underline-offset: 4px;
}

.seo-tool-box {
  margin: 42px 0 36px;
  padding: 30px;
  border: 2px solid #1a1410;
  background: #1a1410;
  color: #f4ecd8;
  text-align: center;
}

.seo-tool-box h2 {
  margin-bottom: 8px;
  font-size: clamp(22px, 4vw, 30px);
}

.seo-tool-box p {
  margin: 0 auto;
  max-width: 560px;
  color: #d9cdbf;
  font-size: 14px;
  line-height: 1.7;
}

.seo-tool-box .seo-primary-entry {
  border-color: #f4ecd8;
  box-shadow: 4px 4px 0 #f4ecd8;
}

.seo-tool-box .seo-primary-entry:hover {
  box-shadow: 2px 2px 0 #f4ecd8;
}

.seo-content-related {
  margin-bottom: 40px;
  padding-top: 28px;
  border-top: 1px solid #ded5ca;
}

.seo-content-related h2 {
  margin-bottom: 16px;
  color: #6d625a;
  font-size: 13px;
  letter-spacing: 0.15em;
}

.seo-content-related-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.seo-content-related a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  padding: 8px 14px;
  border: 1px solid #ccc;
  background: #fff;
  color: #3a3330;
  font-size: 13px;
  text-decoration: none;
}

.seo-content-related a:hover {
  border-color: #c8341e;
  color: #c8341e;
}

.seo-content-footer {
  padding: 24px 0;
  border-top: 1px solid #e0d8cc;
  color: #70665f;
  font-size: 12px;
  text-align: center;
}

.seo-copy-button:focus-visible,
.seo-primary-entry:focus-visible,
.seo-section-nav a:focus-visible,
.seo-section-next a:focus-visible,
.seo-content-related a:focus-visible {
  outline: 3px solid #f2ad33;
  outline-offset: 3px;
}

.seo-toast {
  position: fixed;
  z-index: 30;
  top: max(16px, env(safe-area-inset-top));
  left: 50%;
  max-width: min(360px, calc(100vw - 32px));
  padding: 11px 18px;
  transform: translate(-50%, -16px);
  border: 1px solid #1a1410;
  background: #1a1410;
  color: #fffaf1;
  font-size: 14px;
  line-height: 1.4;
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease, transform 150ms ease;
}

.seo-toast.show {
  transform: translate(-50%, 0);
  opacity: 1;
}

@media (max-width: 700px) {
  .seo-content-page {
    padding: 0 16px;
  }

  .seo-content-header {
    padding: 30px 0 24px;
  }

  .seo-content-header h1 {
    font-size: clamp(29px, 9vw, 40px);
  }

  .seo-content-lead {
    font-size: 16px;
    line-height: 1.75;
  }

  .seo-section-nav {
    flex-wrap: nowrap;
    margin-right: -16px;
    padding-right: 40px;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: none;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 28px), transparent 100%);
    mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 28px), transparent 100%);
  }

  .seo-section-nav::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
  }

  .seo-section-nav a {
    flex: 0 0 auto;
  }

  .seo-content-section {
    padding: 30px 0;
  }

  .seo-quote-grid {
    grid-template-columns: 1fr;
  }

  .seo-quote-card {
    min-height: 0;
    padding: 18px;
  }

  .seo-tool-box {
    padding: 26px 20px;
  }
}

@media (max-width: 340px) {
  .seo-content-page {
    padding: 0 12px;
  }

  .seo-section-nav {
    margin-right: -12px;
    padding-right: 36px;
  }

  .seo-quote-text {
    font-size: 16px;
  }

  .seo-copy-button {
    min-width: 96px;
    padding-inline: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .seo-primary-entry,
  .seo-toast {
    transition: none;
  }
}
