.seo-page {
  background: #f8f7f3;
  color: #1e2a27;
}

.seo-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid rgba(30, 42, 39, 0.1);
  backdrop-filter: blur(12px);
}

.seo-header__inner,
.seo-main,
.seo-footer__inner {
  width: min(100% - 40px, 960px);
  margin-inline: auto;
}

.seo-header__inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.seo-logo {
  color: #173d32;
  font-weight: 800;
  text-decoration: none;
}

.seo-header__cta,
.seo-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  background: #b84f26;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.seo-main {
  padding: 28px 0 88px;
}

.seo-breadcrumb {
  margin: 0 0 36px;
  color: #60716c;
  font-size: 0.86rem;
}

.seo-breadcrumb a {
  color: inherit;
}

.seo-hero {
  padding: clamp(36px, 7vw, 72px);
  border-radius: 28px;
  background: linear-gradient(135deg, #173d32, #245f4e);
  color: #fff;
  box-shadow: 0 24px 70px rgba(23, 61, 50, 0.16);
}

.seo-eyebrow {
  margin: 0 0 14px;
  color: #f7c8a5;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.seo-hero h1 {
  margin: 0;
  max-width: 17em;
  font-size: clamp(2rem, 5vw, 3.45rem);
  line-height: 1.32;
  letter-spacing: -0.025em;
}

.seo-hero__lead {
  margin: 24px 0 0;
  max-width: 47em;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1rem, 2vw, 1.14rem);
  line-height: 1.9;
}

.seo-section {
  padding: 72px 0 0;
}

.seo-section h2 {
  margin: 0 0 22px;
  color: #173d32;
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1.45;
}

.seo-section h3 {
  margin: 0 0 10px;
  color: #173d32;
  font-size: 1.15rem;
}

.seo-section p,
.seo-section li {
  line-height: 1.9;
}

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

.seo-card {
  padding: 26px;
  border: 1px solid rgba(23, 61, 50, 0.1);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 12px 35px rgba(23, 61, 50, 0.06);
}

.seo-card__num {
  display: block;
  margin-bottom: 15px;
  color: #b84f26;
  font-weight: 800;
}

.seo-checklist {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.seo-checklist li {
  position: relative;
  padding: 15px 18px 15px 48px;
  border-radius: 14px;
  background: #fff;
}

.seo-checklist li::before {
  content: "✓";
  position: absolute;
  left: 18px;
  color: #b84f26;
  font-weight: 800;
}

.seo-checklist--spaced {
  margin-top: 18px;
}

.seo-checklist--columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.seo-example {
  padding: 28px;
  border-left: 5px solid #b84f26;
  border-radius: 0 18px 18px 0;
  background: #fff;
}

.seo-example--mail p {
  margin-block: 0 18px;
}

.seo-example--mail p:last-child {
  margin-bottom: 0;
}

.seo-faq {
  display: grid;
  gap: 12px;
}

.seo-faq details {
  padding: 18px 20px;
  border-radius: 14px;
  background: #fff;
}

.seo-faq summary {
  cursor: pointer;
  color: #173d32;
  font-weight: 700;
}

.seo-cta-box {
  margin-top: 72px;
  padding: clamp(30px, 6vw, 58px);
  border-radius: 26px;
  background: #f1e4d5;
  text-align: center;
}

.seo-cta-box h2 {
  margin-top: 0;
}

.seo-related {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.seo-related a {
  padding: 12px 16px;
  border: 1px solid rgba(23, 61, 50, 0.16);
  border-radius: 999px;
  color: #173d32;
  background: #fff;
  text-decoration: none;
  font-weight: 700;
}

.seo-quick-nav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 22px;
}

.seo-quick-nav a {
  padding: 13px 14px;
  border: 1px solid rgba(23, 61, 50, 0.15);
  border-radius: 12px;
  background: #fff;
  color: #173d32;
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
}

.seo-tool__eyebrow {
  margin-bottom: 8px;
  color: #a94721;
  font-size: 0.86rem;
  font-weight: 800;
}

.seo-tool {
  margin-top: 24px;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(23, 61, 50, 0.12);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 35px rgba(23, 61, 50, 0.06);
}

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

.seo-tool label {
  display: grid;
  gap: 7px;
  color: #173d32;
  font-size: 0.9rem;
  font-weight: 700;
}

.seo-tool input,
.seo-tool select,
.seo-tool textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 13px;
  border: 1px solid #b8c3bf;
  border-radius: 10px;
  background: #fff;
  color: #1e2a27;
  font: inherit;
}

.seo-tool input:focus,
.seo-tool select:focus,
.seo-tool textarea:focus {
  outline: 3px solid rgba(23, 61, 50, 0.16);
  border-color: #173d32;
}

.seo-tool > label {
  margin-top: 16px;
}

.seo-tool textarea {
  resize: vertical;
  line-height: 1.7;
}

.seo-tool__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0;
}

.seo-tool__button,
.seo-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid #173d32;
  border-radius: 10px;
  background: #173d32;
  color: #fff;
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.seo-tool__button--sub {
  background: #fff;
  color: #173d32;
}

.seo-tool__result-label {
  margin-top: 4px !important;
}

.seo-tool .seo-tool__result {
  margin-top: 8px;
  background: #edf3f0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92rem;
}

.seo-tool .seo-nippo-output {
  min-height: 290px;
  white-space: pre-wrap;
}

.seo-tool .seo-mail-output {
  min-height: 440px;
  white-space: pre-wrap;
}

.seo-tool .seo-paint-output {
  min-height: 360px;
  white-space: pre-wrap;
}

.seo-calc-highlight {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
  padding: 18px 22px;
  border-radius: 14px;
  background: #f1e4d5;
  color: #173d32;
  font-weight: 800;
}

.seo-calc-highlight strong {
  color: #a94721;
  font-size: clamp(1.7rem, 4vw, 2.4rem);
}

.seo-tool .seo-calc-output {
  min-height: 430px;
  white-space: pre-wrap;
}

.seo-tool__status,
.seo-download-note {
  margin-top: 10px;
  color: #53655f;
  font-size: 0.86rem;
}

.seo-download {
  margin-top: 18px;
  background: #b84f26;
  border-color: #b84f26;
}

.seo-diagnosis {
  margin-top: 24px;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid rgba(23, 61, 50, 0.12);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 35px rgba(23, 61, 50, 0.06);
}

.seo-diagnosis fieldset {
  border: 0;
}

.seo-diagnosis legend {
  margin-bottom: 14px;
  color: #173d32;
  font-size: 1rem;
  font-weight: 800;
}

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

.seo-diagnosis__options label {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 16px;
  border: 1px solid #c8d0cd;
  border-radius: 12px;
  color: #263a34;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.65;
  cursor: pointer;
}

.seo-diagnosis__options label:has(input:checked) {
  border-color: #173d32;
  background: #edf3f0;
}

.seo-diagnosis__options input {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin-top: 3px;
  accent-color: #173d32;
}

.seo-diagnosis__result {
  margin-top: 22px;
  padding: 22px;
  border-left: 5px solid #173d32;
  border-radius: 0 14px 14px 0;
  background: #edf3f0;
}

.seo-diagnosis__result h3 {
  margin-bottom: 8px;
}

.seo-diagnosis__result > p {
  color: #42564f;
}

.seo-diagnosis__result ul {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.seo-diagnosis__result li {
  display: grid;
  gap: 5px;
  padding: 16px;
  border-radius: 12px;
  background: #fff;
}

.seo-diagnosis__result li span {
  color: #4d625b;
  font-size: 0.9rem;
}

.seo-diagnosis__result li a,
.seo-card p a {
  color: #174f5c;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.seo-quick-nav a:focus-visible,
.seo-tool__button:focus-visible,
.seo-download:focus-visible {
  outline: 3px solid #f3b47a;
  outline-offset: 3px;
}

.seo-footer {
  padding: 38px 0;
  background: #173d32;
  color: rgba(255, 255, 255, 0.8);
}

.seo-footer__inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
}

.seo-footer a {
  color: #fff;
}

@media (max-width: 760px) {
  .seo-grid {
    grid-template-columns: 1fr;
  }

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

  .seo-quick-nav,
  .seo-tool__grid,
  .seo-diagnosis__options {
    grid-template-columns: 1fr;
  }

  .seo-tool__actions,
  .seo-tool__button,
  .seo-download {
    width: 100%;
  }

  .seo-calc-highlight {
    align-items: flex-start;
    flex-direction: column;
  }

  .seo-header__cta {
    min-height: 40px;
    padding: 0 15px;
    font-size: 0.85rem;
  }

  .seo-footer__inner {
    flex-direction: column;
  }
}
