/*
Theme Name: Original Service Frame
Author: Original
Description: 比較・ランキング型の長文サービス紹介サイト用オリジナルテーマ。
Version: 1.0.7
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: original-service-frame
*/

:root {
  --ink: #262626;
  --muted: #707070;
  --line: #e4e4e4;
  --soft: #f7f7f7;
  --soft-blue: #edf6fb;
  --soft-yellow: #fff8d9;
  --accent: #147aa3;
  --cta-start: #f8a7a9;
  --cta-end: #2e77bd;
  --header: #050505;
  --content: 860px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  font-size: 16px;
  line-height: 1.9;
  overflow-wrap: anywhere;
}
a { color: var(--accent); text-underline-offset: .18em; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
.screen-reader-text {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.site-header { background: var(--header); color: #fff; }
.header-inner {
  width: min(1120px, calc(100% - 40px)); min-height: 72px; margin: auto;
  display: flex; align-items: center; justify-content: space-between; gap: 28px;
}
.site-branding { flex: 0 0 auto; }
.site-branding a { color: #fff; text-decoration: none; font-weight: 800; letter-spacing: .08em; }
.custom-logo { width: auto; max-height: 45px; }
.header-actions { display: flex; align-items: center; gap: 24px; }
.primary-nav ul { display: flex; align-items: center; gap: 30px; list-style: none; margin: 0; padding: 0; }
.primary-nav a { color: #fff; text-decoration: none; font-size: .92rem; }
.menu-toggle, .search-toggle {
  appearance: none; border: 0; background: transparent; color: #fff; cursor: pointer; padding: 8px;
}
.menu-toggle { display: none; }
.search-panel { display: none; padding: 18px 20px; background: #171717; }
.search-panel.is-open { display: block; }
.search-form { display: flex; max-width: 680px; margin: auto; }
.search-field { width: 100%; min-height: 46px; padding: 8px 13px; border: 0; }
.search-submit { border: 0; padding: 8px 22px; color: #fff; background: var(--accent); cursor: pointer; }

.site-main { width: min(var(--content), calc(100% - 40px)); margin: 0 auto; padding: 38px 0 80px; }
.entry-title { margin: 0 0 6px; font-size: clamp(1.75rem, 4vw, 2.35rem); line-height: 1.55; letter-spacing: .01em; }
.updated-date { margin: 0 0 18px; color: var(--muted); font-size: .9rem; }
.hero-placeholder {
  aspect-ratio: 16 / 9; display: grid; place-items: center; margin: 0 0 22px;
  color: #777; background: linear-gradient(135deg, #eeeeee 0 49%, #e2e2e2 49% 51%, #f4f4f4 51%);
  border: 1px solid #ddd; font-size: 1.15rem; font-weight: 700;
}
.disclosure { margin: 20px 0 30px; color: #666; font-size: .84rem; line-height: 1.7; }
.lead { margin: 1.5em 0; }
.marker { background: linear-gradient(transparent 62%, #fff2a8 62%); font-weight: 700; }

.top-picks { width: 100%; margin: 30px 0; border-collapse: collapse; table-layout: fixed; }
.top-picks th, .top-picks td { padding: 15px; border: 1px solid var(--line); vertical-align: middle; }
.top-picks th { color: #fff; background: #3d3d3d; font-size: .92rem; }
.top-picks th:first-child { width: 32%; }
.pick-logo {
  width: 96px; aspect-ratio: 1; display: grid; place-items: center; margin: 0 auto 8px;
  color: #888; background: #efefef; border: 1px solid #ddd; font-weight: 800;
}
.rating { color: #ed9b11; letter-spacing: .08em; white-space: nowrap; }
.pick-title { display: block; margin: 2px 0 4px; font-weight: 800; }
.pick-copy { margin: 0 0 10px; font-size: .92rem; line-height: 1.7; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 22px;
  border: 0; border-radius: 999px; color: #fff;
  background: linear-gradient(90deg, var(--cta-start) 0%, var(--cta-end) 100%);
  text-decoration: none; font-size: .9rem; font-weight: 800; line-height: 1.4; white-space: nowrap;
  box-shadow: none; transition: transform .15s ease, filter .15s ease;
}
.button:hover { color: #fff; filter: brightness(1.06); transform: translateY(-1px); }
.button-block { width: min(520px, 100%); }

.toc {
  width: min(620px, 100%); margin: 34px auto 46px; padding: 16px 10px 12px;
  border-top: 1px solid #252525; border-bottom: 1px solid #252525; background: #fff;
}
.toc-title { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 0 12px; font-size: .95rem; font-weight: 500; }
.toc-list { margin: 0; padding-left: 1.4em; list-style: disc; font-size: .88rem; line-height: 1.55; }
.toc-list > li { margin: .5em 0; }
.toc-list ul { margin: .18em 0 .45em; padding-left: 1.45em; list-style: none; color: #686868; }
.toc-list ul li { position: relative; margin: .12em 0; }
.toc-list ul li::before { content: "└"; position: absolute; left: -1.25em; color: #8a8a8a; }
.toc:not(.is-expanded) .toc-extra { display: none; }
.toc a { color: #333; text-decoration: none; }
.toc-toggle-row { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 12px; color: #aaa; }
.toc-toggle-row::before, .toc-toggle-row::after { content: "・・・・"; letter-spacing: .12em; font-size: .72rem; }
.toc-toggle {
  min-height: 31px; padding: 4px 15px; border: 1px solid #222; border-radius: 999px;
  color: #222; background: #fff; font-size: .78rem; line-height: 1; cursor: pointer;
}
.toc-toggle:hover { background: #f5f5f5; }

.section { scroll-margin-top: 24px; margin-top: 54px; }
.section > h2 {
  margin: 0 0 25px; padding: 15px 18px; border-left: 5px solid #202020;
  background: #f2f2f2; font-size: clamp(1.45rem, 3vw, 1.85rem); line-height: 1.5;
}
.section h3 { margin: 42px 0 18px; padding: 0 0 10px; border-bottom: 3px solid #2e2e2e; font-size: 1.35rem; line-height: 1.55; }
.section h4 { margin: 32px 0 14px; padding-left: 12px; border-left: 4px solid #777; font-size: 1.1rem; }
.note-box { margin: 22px 0; padding: 20px 22px; background: var(--soft-yellow); border: 1px solid #eadc91; }
.check-list { list-style: none; margin: 22px 0; padding: 0; }
.check-list li { position: relative; margin: 9px 0; padding-left: 28px; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--cta-end); font-weight: 900; }

#comparison .comparison-display-title {
  display: flex; align-items: flex-end; gap: 2px; margin: 0 0 24px; padding: 0;
  border: 0; background: transparent; color: #050505; font-size: 1.12rem; line-height: 1.25;
}
#comparison .comparison-display-title span {
  display: inline-block; margin: 0 1px -4px 0; font-size: clamp(3.45rem, 8vw, 4.9rem);
  font-weight: 950; line-height: .78; letter-spacing: -.13em;
}
.comparison-intro {
  display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(250px, .82fr);
  align-items: stretch; margin: 0 0 12px;
}
.comparison-copy {
  position: relative; z-index: 1; margin-right: -1px; padding: 24px 25px 22px;
  border: 2px solid #111; border-radius: 5px; background: #fff;
  font-size: .92rem; line-height: 1.75;
}
.comparison-copy p { margin: 0 0 15px; }
.comparison-copy p:last-child { margin-bottom: 0; }
.comparison-copy ul { margin: 12px 0 17px; padding: 0; list-style: none; }
.comparison-copy li { position: relative; padding: 9px 0 9px 25px; border-bottom: 1px dotted #d8d8d8; }
.comparison-copy li:last-child { border-bottom: 0; }
.comparison-copy li::before {
  content: "✓"; position: absolute; left: 2px; top: 8px; color: #111; font-weight: 900;
}
.comparison-visual {
  position: relative; isolation: isolate; display: grid; min-height: 410px; place-items: center;
  overflow: hidden; background: linear-gradient(145deg, #dadada 0 26%, #b8b8b8 26% 52%, #e8e8e8 52% 74%, #c5c5c5 74%);
}
.comparison-visual::before {
  content: ""; position: absolute; z-index: -1; width: 58%; aspect-ratio: 1; border-radius: 50%;
  background: rgb(255 255 255 / 55%); box-shadow: 0 132px 0 65px rgb(70 70 70 / 24%);
}
.comparison-visual span { color: rgb(255 255 255 / 88%); font-size: 4.5rem; text-shadow: 0 2px 12px rgb(0 0 0 / 16%); }

.scroll-hint { margin: 0 0 6px; color: var(--muted); text-align: center; font-size: .83rem; }
.table-scroll { width: 100%; overflow-x: auto; border: 1px solid var(--line); -webkit-overflow-scrolling: touch; }
.compare-table { width: 1420px; border-collapse: collapse; font-size: .84rem; line-height: 1.55; }
.compare-table th, .compare-table td { min-width: 98px; padding: 12px 9px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-align: center; vertical-align: middle; }
.compare-table th { position: sticky; top: 0; color: #fff; background: #363636; }
.compare-table td:first-child { min-width: 150px; font-weight: 800; background: #fafafa; }
.compare-table .table-cta {
  min-height: 28px; margin-top: 7px; padding: 4px 11px; font-size: .72rem; line-height: 1;
}
.rank-badge { display: inline-grid; place-items: center; width: 34px; height: 34px; margin-bottom: 5px; border-radius: 50%; color: #fff; background: #333; font-weight: 800; }

.ranking-item { margin: 58px 0 76px; }
.ranking-item > h3 {
  display: table; margin: 0 auto 30px; padding: 0 3px 2px; border: 0;
  background: linear-gradient(transparent 64%, #f1e56e 64%); font-size: 1.08rem; line-height: 1.45;
}
.service-summary { overflow: visible; border: 0; border-radius: 0; box-shadow: none; }
.service-summary-head { display: grid; grid-template-columns: 1fr 1.18fr; gap: 0; align-items: stretch; padding: 0; background: transparent; }
.service-image {
  display: grid; min-height: 225px; place-items: center; overflow: hidden; border: 0;
  color: rgb(255 255 255 / 90%); background: linear-gradient(135deg, #d9e9ee 0 38%, #b5ccd3 38% 66%, #e9e2df 66%);
  font-size: 3.4rem; font-weight: 800;
}
.service-recommendation {
  display: flex; flex-direction: column; justify-content: center; padding: 25px 28px;
  border: 2px solid #111; border-radius: 5px; background: #fff;
}
.service-recommendation > strong { margin-bottom: 6px; font-size: .82rem; }
.service-points { margin: 4px 0 0; padding: 0; list-style: none; }
.service-points li { position: relative; margin: .34em 0; padding-left: 23px; }
.service-points li::before { content: "✓"; position: absolute; left: 0; color: #111; font-weight: 900; }
.service-summary-cta { padding-top: 14px; text-align: center; }
.service-summary-cta .button { min-height: 36px; padding: 6px 18px; font-size: .78rem; }
.feature-grid { display: grid; grid-template-columns: repeat(6, 1fr); width: 72%; margin: 24px auto 0; border: 1px solid var(--line); }
.feature { padding: 12px 6px; border-right: 1px solid var(--line); text-align: center; line-height: 1.45; }
.feature::before { content: "●"; display: block; margin-bottom: 2px; color: #111; font-size: .72rem; }
.feature:last-child { border-right: 0; }
.feature span { display: block; color: var(--muted); font-size: .74rem; }
.feature strong { display: block; margin-top: 5px; font-size: .92rem; }
.content-placeholder { margin: 20px 0; }
.media-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 20px 0; }
.small-placeholder { aspect-ratio: 4 / 3; display: grid; place-items: center; color: #888; background: #efefef; border: 1px solid #ddd; font-weight: 700; }
.info-table { width: 100%; margin: 20px 0; border-collapse: collapse; }
.info-table th, .info-table td { padding: 13px 15px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.info-table th { width: 30%; background: #f3f3f3; }
.cta-box { margin: 30px 0; padding: 26px; text-align: center; background: #f8f8f8; border: 1px solid var(--line); }
.cta-box p { margin-top: 0; font-weight: 800; }
.related-box { margin: 24px 0; padding: 18px 20px; border: 1px solid #d8d8d8; }
.related-box strong { display: block; margin-bottom: 6px; }

.step-list { counter-reset: step; list-style: none; margin: 28px 0; padding: 0; }
.step-list li { counter-increment: step; position: relative; margin: 0 0 14px; padding: 16px 18px 16px 62px; background: #f5f5f5; }
.step-list li::before { content: counter(step); position: absolute; left: 16px; top: 13px; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: #fff; background: #333; font-weight: 800; }
.faq { margin: 28px 0; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { position: relative; padding: 18px 44px 18px 50px; cursor: pointer; list-style: none; font-weight: 800; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "Q"; position: absolute; left: 10px; top: 14px; color: var(--accent); font-size: 1.2rem; }
.faq summary::after { content: "+"; position: absolute; right: 12px; top: 14px; font-size: 1.35rem; }
.faq details[open] summary::after { content: "−"; }
.faq-answer { position: relative; padding: 0 18px 20px 50px; }
.faq-answer::before { content: "A"; position: absolute; left: 10px; top: 0; color: #d25e45; font-size: 1.2rem; font-weight: 800; }

.site-footer { color: #d6d6d6; background: #111; }
.footer-inner { width: min(1120px, calc(100% - 40px)); margin: auto; padding: 48px 0 22px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 42px; }
.footer-title { margin: 0 0 14px; color: #fff; font-size: 1rem; }
.footer-menu { list-style: none; margin: 0; padding: 0; }
.footer-menu li { margin: 7px 0; }
.footer-menu a { color: #d6d6d6; text-decoration: none; }
.copyright { margin: 35px 0 0; padding-top: 20px; border-top: 1px solid #333; text-align: center; font-size: .8rem; }

@media (max-width: 760px) {
  .header-inner { width: min(100% - 28px, 1120px); min-height: 62px; }
  .menu-toggle { display: block; }
  .header-actions { gap: 8px; }
  .primary-nav { display: none; position: absolute; z-index: 20; top: 62px; left: 0; right: 0; padding: 12px 20px 20px; background: #101010; }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: block; }
  .primary-nav li { border-bottom: 1px solid #333; }
  .primary-nav a { display: block; padding: 12px 2px; }
  .site-main { width: min(100% - 28px, var(--content)); padding-top: 28px; }
  .entry-title { font-size: 1.65rem; }
  .top-picks { font-size: .9rem; }
  .top-picks th, .top-picks td { padding: 10px 8px; }
  .top-picks th:first-child { width: 34%; }
  .pick-copy { display: none; }
  .button { padding-inline: 16px; }
  .toc { width: 100%; padding: 14px 4px 10px; }
  .toc-list { font-size: .84rem; }
  .section { margin-top: 44px; }
  .section > h2 { padding: 13px 14px; font-size: 1.4rem; }
  #comparison .comparison-display-title { gap: 1px; margin-bottom: 18px; font-size: .98rem; }
  #comparison .comparison-display-title span { font-size: 3.3rem; }
  .comparison-intro { grid-template-columns: 1fr; }
  .comparison-copy { order: 2; margin: -1px 0 0; padding: 20px 18px; border-radius: 0 0 5px 5px; font-size: .9rem; }
  .comparison-visual { order: 1; min-height: 260px; border-radius: 5px 5px 0 0; }
  .ranking-item > h3 { margin-bottom: 22px; font-size: 1rem; }
  .service-summary-head { grid-template-columns: 1fr; }
  .service-image { min-height: 190px; }
  .service-recommendation { padding: 21px 18px; border-radius: 0 0 5px 5px; }
  .service-points { font-size: .9rem; }
  .feature-grid { grid-template-columns: repeat(3, 1fr); width: 100%; margin-top: 18px; }
  .feature:nth-child(3) { border-right: 0; }
  .feature:nth-child(-n+3) { border-bottom: 1px solid var(--line); }
  .media-pair { grid-template-columns: 1fr; }
  .info-table { font-size: .9rem; }
  .info-table th, .info-table td { padding: 10px; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
