:root {
  --ink: #0f1725;
  --muted: #5b6879;
  --line: #dbe4ec;
  --soft: #f6fafb;
  --green: #079d61;
  --green-dark: #056f47;
  --green-soft: #eaf8f1;
  --blue: #2367d8;
  --red: #e63746;
  --amber: #b36b00;
  --amber-soft: #fff7e5;
  --shadow: 0 16px 42px rgba(15, 23, 37, .07);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body.yai-page {
  margin: 0;
  background: linear-gradient(180deg, #fff 0, #f8fbfa 540px, #fbfdfc 100%);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", "Yu Gothic", Meiryo, sans-serif;
  letter-spacing: 0;
  line-height: 1.75;
}

a {
  color: inherit;
}

.yai-header {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 clamp(16px, 4vw, 48px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .97);
}

.yai-brand,
.yai-header nav a {
  color: var(--ink);
  text-decoration: none;
}

.yai-brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 25px;
  font-weight: 950;
}

.yai-mark {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.yai-mark i {
  display: block;
  width: 5px;
  border-radius: 999px;
  background: var(--green);
}

.yai-mark i:nth-child(1) { height: 18px; }
.yai-mark i:nth-child(2) { height: 34px; }
.yai-mark i:nth-child(3) { height: 24px; }

.yai-header nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.yai-header nav a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  color: #263446;
  font-weight: 900;
  white-space: nowrap;
}

.yai-header nav a:last-child {
  border-radius: 8px;
  background: var(--green);
  color: #fff;
}

.yai-shell {
  width: min(1480px, calc(100% - 40px));
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 34px;
  align-items: start;
  margin: 0 auto;
  padding: 28px 0 0;
}

.yai-main {
  min-width: 0;
}

.yai-breadcrumb {
  margin: 0 0 18px;
  color: #66778c;
  font-size: 14px;
  font-weight: 850;
}

.yai-breadcrumb a {
  text-decoration: none;
}

.yai-breadcrumb span {
  padding: 0 8px;
  color: #9aabb9;
}

.yai-kicker {
  width: fit-content;
  margin: 0 0 12px;
  padding: 5px 12px;
  border-radius: 999px;
  background: #fff2f2;
  color: var(--red);
  font-weight: 950;
}

.yai-hero h1 {
  margin: 0;
  font-size: clamp(40px, 4.6vw, 70px);
  line-height: 1.12;
  font-weight: 950;
}

.yai-hero h1::first-letter {
  color: var(--green);
}

.yai-lead {
  margin: 16px 0 0;
  color: #243447;
  font-size: clamp(21px, 2.1vw, 30px);
  line-height: 1.35;
  font-weight: 900;
}

.yai-fast-answer {
  margin-top: 18px;
  padding: 16px 18px;
  border: 1px solid #bfe8d4;
  border-left: 7px solid var(--green);
  border-radius: 8px;
  background: #f7fffb;
}

.yai-fast-answer b {
  display: block;
  color: #062238;
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.35;
  font-weight: 950;
}

.yai-fast-answer p {
  margin: 8px 0 0;
  color: #425166;
  font-size: 17px;
  line-height: 1.75;
  font-weight: 780;
}

.yai-conclusion,
.yai-tool-cta,
.yai-section,
.yai-side-cta,
.yai-side-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.yai-conclusion {
  margin-top: 22px;
  padding: 22px;
  border-color: rgba(7, 157, 97, .55);
  background: #fbfffd;
}

.yai-conclusion-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.yai-conclusion-head span {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 950;
  flex: 0 0 auto;
}

.yai-conclusion-head h2,
.yai-tool-cta h2,
.yai-section-head h2 {
  margin: 0;
  font-size: clamp(27px, 2.8vw, 40px);
  line-height: 1.25;
  font-weight: 950;
}

.yai-check-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.yai-check-cards article {
  min-height: 170px;
  padding: 18px;
  border: 1px solid #cfe4da;
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.yai-check-cards span,
.yai-steps span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin: 0 auto 10px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-weight: 950;
}

.yai-check-cards b {
  display: block;
  font-size: 22px;
}

.yai-check-cards p {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 760;
}

.yai-main-cta,
.yai-tool-cta a,
.yai-side-cta a,
.yai-script-box a {
  min-height: 62px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-size: 20px;
  font-weight: 950;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(7, 157, 97, .22);
}

.yai-main-cta {
  width: 100%;
  margin-top: 16px;
}

.yai-note,
.yai-small {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: #eef5ff;
  color: #36516f;
  font-size: 15px;
  font-weight: 820;
}

.yai-section {
  margin-top: 30px;
  padding: clamp(20px, 2.6vw, 30px);
}

.yai-section-head {
  margin-bottom: 16px;
}

.yai-section-head p {
  margin: 0 0 6px;
  color: var(--green-dark);
  font-weight: 950;
}

.yai-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.yai-table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
  background: #fff;
}

.yai-table th,
.yai-table td {
  padding: 14px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 15px;
  font-weight: 780;
}

.yai-table th {
  background: #f1fbf6;
  color: #173552;
  font-weight: 950;
}

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

.yai-table th:last-child,
.yai-table td:last-child {
  border-right: 0;
}

.yai-table b {
  display: block;
  font-size: 17px;
}

.yai-table small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.yai-tool-cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 20px;
  align-items: center;
  margin-top: 26px;
  padding: 22px;
  border-color: #b8d5ff;
  background: linear-gradient(135deg, #f4f9ff, #fff);
}

.yai-tool-cta > div {
  display: flex;
  align-items: center;
  gap: 16px;
}

.yai-tool-cta span {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #e7f1ff;
  color: var(--blue);
  font-size: 24px;
  font-weight: 950;
  flex: 0 0 auto;
}

.yai-tool-cta p {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 760;
}

.yai-list-grid,
.yai-steps,
.yai-ref-grid {
  display: grid;
  gap: 14px;
}

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

.yai-list-grid label {
  min-height: 62px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid #e9c36d;
  border-radius: 8px;
  background: var(--amber-soft);
  color: #354559;
  font-size: 16px;
  font-weight: 860;
}

.yai-list-grid input {
  width: 22px;
  height: 22px;
  accent-color: var(--green);
  flex: 0 0 auto;
}

.yai-steps {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.yai-steps article,
.yai-ref-grid a,
.yai-script-box,
.yai-faq details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 37, .04);
}

.yai-steps article {
  padding: 18px;
}

.yai-steps h3 {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1.35;
}

.yai-steps p {
  margin: 0;
  color: var(--muted);
  font-weight: 760;
}

.yai-script-box {
  padding: 20px;
}

.yai-script-box pre {
  margin: 0;
  white-space: pre-wrap;
  color: #2f3f53;
  font-family: "Noto Sans JP", "Yu Gothic", Meiryo, sans-serif;
  font-size: 18px;
  line-height: 1.85;
  font-weight: 780;
}

.yai-script-box a {
  margin-top: 16px;
  padding: 0 18px;
}

.yai-ref-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.yai-ref-grid a {
  min-height: 126px;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px;
  color: #155b9e;
  text-decoration: none;
}

.yai-ref-grid b {
  color: #173552;
  font-size: 18px;
}

.yai-ref-grid span {
  color: #58677a;
  font-size: 14px;
  font-weight: 760;
}

.yai-faq details + details {
  margin-top: 10px;
}

.yai-faq summary {
  padding: 18px;
  font-size: 18px;
  font-weight: 950;
  cursor: pointer;
}

.yai-faq p {
  margin: 0;
  padding: 0 18px 18px;
  color: #4a596a;
  font-weight: 760;
}

.yai-side {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 16px;
}

.yai-side-cta,
.yai-side-box {
  padding: 20px;
}

.yai-side-cta {
  border-color: rgba(7, 157, 97, .45);
  background: #fbfffd;
}

.yai-side-cta h2,
.yai-side-box h2 {
  margin: 0 0 14px;
  font-size: 22px;
}

.yai-side-cta p,
.yai-side-note p {
  margin: 0 0 10px;
  color: var(--muted);
  font-weight: 780;
}

.yai-side-cta a {
  width: 100%;
  min-height: 58px;
  font-size: 17px;
}

.yai-side-box a {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0;
  color: #28547f;
  text-decoration: none;
  font-weight: 900;
}

.yai-side-box span {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: 14px;
  flex: 0 0 auto;
}

.yai-footer {
  display: flex;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 40px;
  padding: 30px 16px;
  border-top: 1px solid var(--line);
  background: #fbfdfc;
  color: #5d6877;
  font-size: 14px;
  font-weight: 850;
}

@media (max-width: 1180px) {
  .yai-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .yai-side {
    position: static;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .yai-check-cards,
  .yai-steps,
  .yai-ref-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .yai-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 13px 14px;
  }

  .yai-brand {
    font-size: 21px;
  }

  .yai-header nav {
    width: 100%;
    flex-wrap: wrap;
    overflow-x: visible;
    padding-bottom: 0;
  }

  .yai-header nav a {
    flex: 0 1 auto;
    min-height: 34px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: #263446;
    white-space: nowrap;
  }

  .yai-header nav a:last-child {
    background: var(--green);
    color: #fff;
  }

  .yai-shell {
    width: calc(100% - 20px);
    padding-top: 18px;
  }

  .yai-hero h1 {
    font-size: 37px;
  }

  .yai-lead {
    font-size: 20px;
  }

  .yai-conclusion-head,
  .yai-tool-cta,
  .yai-tool-cta > div {
    grid-template-columns: minmax(0, 1fr);
  }

  .yai-conclusion-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .yai-check-cards,
  .yai-list-grid,
  .yai-steps,
  .yai-ref-grid,
  .yai-side {
    grid-template-columns: minmax(0, 1fr);
  }

  .yai-tool-cta {
    padding: 18px;
  }

  .yai-tool-cta span {
    width: 64px;
    height: 64px;
  }

  .yai-table th,
  .yai-table td {
    font-size: 15px;
  }

  .yai-table-wrap {
    overflow: visible;
    border: 0;
    border-radius: 0;
  }

  .yai-table {
    min-width: 0;
    display: block;
    background: transparent;
  }

  .yai-table thead {
    display: none;
  }

  .yai-table tbody {
    display: grid;
    gap: 12px;
  }

  .yai-table tr {
    display: block;
    padding: 13px 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
  }

  .yai-table td {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 10px;
    padding: 9px 0;
    border: 0;
    border-bottom: 1px solid #edf2f0;
  }

  .yai-table td:last-child {
    border-bottom: 0;
  }

  .yai-table td::before {
    color: var(--green-dark);
    font-weight: 950;
  }

  .yai-table td:nth-child(1)::before { content: "ツール"; }
  .yai-table td:nth-child(2)::before { content: "無料枠"; }
  .yai-table td:nth-child(3)::before { content: "商用利用"; }
  .yai-table td:nth-child(4)::before { content: "確認点"; }
  .yai-table td:nth-child(5)::before { content: "用途"; }

  .yai-table small {
    font-size: 13px;
  }
}
