/* Homepage 料金プラン・助成金 (.pr), per the supplied design.
   Desktop: header (copy / three feature icons / 3D art with badge) + three plan cards + simulator (one screen).
   Phone: stacked header, simulator first, then a swipeable plan row. Simulator logic: lead-sections.js. */

.pr {
  --ink: #0f1a4d;
  --text: #3a4468;
  --muted: #6a7296;
  --accent: #2f5bf5;
  --accent-soft: #eef1ff;
  --card: rgba(255, 255, 255, 0.86);
  --line: rgba(160, 175, 240, 0.4);
  position: relative;
  overflow: hidden;
  padding: 32px 32px 24px;
  background: #eef1ff;
  color: var(--ink);
  font-family: "Noto Sans JP", system-ui, sans-serif;
  line-height: 1.6;
  text-align: left;
  isolation: isolate;
}

:where(.pr) *, :where(.pr) *::before, :where(.pr) *::after {
  box-sizing: border-box;
  font-size: inherit;
  line-height: inherit;
  letter-spacing: normal;
}

:where(.pr) :is(h2, h3, p, ul, ol, dl, dd) { margin: 0; padding: 0; }
:where(.pr) :is(ul, ol) { list-style: none; }
:where(.pr) a { text-decoration: none; }
:where(.pr) button { font: inherit; cursor: pointer; }

:where(.pr) svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pr__bg { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; }
.pr__inner { max-width: 1460px; margin: 0 auto; }

/* ---------- header ---------- */
.pr-head { display: grid; grid-template-columns: minmax(0, 1fr) auto 300px; align-items: center; gap: 32px; padding: 0 20px; }

.pr-eyebrow { color: #3f55c8; font-size: 15px; font-weight: 500; line-height: 1.5; }
.pr-eyebrow small { display: block; color: #5b6fc4; font-family: "Inter", sans-serif; font-size: 12px; font-weight: 600; letter-spacing: 0.12em; }

.pr-title { margin-top: 12px; color: var(--ink); font-size: clamp(30px, 2.8vw, 44px); font-weight: 800; line-height: 1.35; letter-spacing: 0.01em; }
.pr-title em { color: var(--accent); font-style: normal; }
.pr-title__num { position: relative; display: inline-block; font-family: "Inter", "Noto Sans JP", sans-serif; }

/* Hand-drawn swash under "75". */
.pr-title__num::after {
  content: "";
  position: absolute;
  left: -2%;
  bottom: -4px;
  width: 64%;
  height: 10px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 12' preserveAspectRatio='none'%3E%3Cpath d='M2 9c20-6 62-8 96-3' fill='none' stroke='%232f5bf5' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

.pr-lead { margin-top: 16px; color: var(--text); font-size: 14.5px; line-height: 1.85; }

.pr-feats { display: flex; gap: 28px; }
.pr-feats li { display: flex; flex-direction: column; align-items: center; gap: 12px; width: 150px; text-align: center; }

.pr-feat__icon {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: #fff;
  color: var(--accent);
  box-shadow: 0 10px 24px rgba(60, 80, 200, 0.12);
}

.pr-feat__icon svg { width: 28px; height: 28px; }
.pr-feats li:first-child .pr-feat__icon svg path:first-child,
.pr-feats li:last-child .pr-feat__icon svg path:first-child { fill: currentColor; }
.pr-feats li:first-child .pr-feat__icon svg path:last-child,
.pr-feats li:last-child .pr-feat__icon svg path:last-child { stroke: #fff; }
.pr-feats li:nth-child(2) .pr-feat__icon svg circle { fill: currentColor; }
.pr-feats li:nth-child(2) .pr-feat__icon svg path { stroke: #fff; }
.pr-feats p { color: var(--ink); font-size: 12.5px; font-weight: 700; line-height: 1.6; }

.pr-art { position: relative; height: 230px; }
.pr-art img { position: absolute; right: -10px; bottom: 0; width: 290px; height: auto; transform: rotate(-4deg); }

.pr-art__badge {
  position: absolute;
  top: 0;
  right: -20px;
  display: grid;
  place-items: center;
  align-content: center;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #5b86ff, #2f4de0 70%);
  color: #fff;
  line-height: 1.1;
  box-shadow: 0 14px 30px rgba(47, 77, 224, 0.4);
}

.pr-art__badge small { font-size: 13px; font-weight: 700; }
.pr-art__badge b { font-family: "Inter", sans-serif; font-size: 32px; font-weight: 700; }

/* ---------- body ---------- */
.pr-body { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 1.4fr); gap: 20px; margin-top: 18px; }
.pr-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: stretch; }

.pr-plan {
  display: flex;
  flex-direction: column;
  padding: 20px 26px 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  box-shadow: 0 16px 40px rgba(70, 90, 200, 0.08);
  backdrop-filter: blur(10px);
}

.pr-plan--pick { margin-top: -14px; border: 2px solid #7f9cf8; background: rgba(255, 255, 255, 0.94); box-shadow: 0 20px 48px rgba(60, 90, 230, 0.2); }

.pr-plan__label { align-self: flex-start; color: #3f55c8; font-family: "Inter", sans-serif; font-size: 13px; font-weight: 600; }

.pr-plan__badge {
  align-self: flex-start;
  padding: 2px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
}

.pr-plan__name { margin-top: 8px; font-size: 22px; font-weight: 800; line-height: 1.4; }
.pr-plan__who { margin-top: 4px; color: var(--muted); font-size: 13px; }

.pr-plan__price {
  display: flex;
  align-items: baseline;
  gap: 2px;
  margin-top: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid #dde2f4;
  font-size: 17px;
  font-weight: 700;
}

.pr-plan__price b { font-family: "Inter", sans-serif; font-size: 40px; font-weight: 700; line-height: 1; letter-spacing: -0.02em; }
.pr-plan__price small { margin-left: 6px; color: var(--muted); font-size: 15px; font-weight: 500; }
.pr-plan__price b.is-ask { font-family: "Noto Sans JP", sans-serif; font-size: 30px; font-weight: 800; letter-spacing: 0; line-height: 1.34; }

.pr-plan__list { display: grid; gap: 6px; margin-top: 14px; }

.pr-plan__list li {
  position: relative;
  padding-left: 26px;
  color: var(--text);
  font-size: 13.5px;
  line-height: 1.6;
}

.pr-plan__list li::before {
  content: "";
  position: absolute;
  top: 0.35em;
  left: 2px;
  width: 14px;
  height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232f5bf5' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 12.5 5 5L20 6.5'/%3E%3C/svg%3E") center / contain no-repeat;
}

.pr-plan__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 48px;
  margin-top: auto;
  border: 1px solid #1e2a6e;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  transition: background 0.2s, color 0.2s;
}

.pr-plan__list { margin-bottom: 18px; }
.pr-plan__btn:hover { background: var(--accent-soft); }
.pr-plan__btn--fill { border: 0; background: linear-gradient(90deg, #2f5bf5, #3b6cff); color: #fff; box-shadow: 0 10px 24px rgba(47, 91, 245, 0.3); }
.pr-plan__btn--fill:hover { background: #2548d8; }

/* ---------- simulator ---------- */
.pr-sim {
  display: flex;
  flex-direction: column;
  padding: 18px 22px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 16px 40px rgba(70, 90, 200, 0.1);
}

.pr-sim__head { display: flex; align-items: flex-start; gap: 14px; }

.pr-sim__icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
}

.pr-sim__icon svg { width: 26px; height: 26px; }
.pr-sim__title { font-size: 18px; font-weight: 800; line-height: 1.4; }
.pr-sim__sub { margin-top: 2px; color: var(--muted); font-size: 11.5px; line-height: 1.5; }

.pr-sim__seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-top: 16px; padding: 4px; border-radius: 10px; background: #eef0f8; }

.pr-sim__seg button {
  padding: 8px 6px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}

.pr-sim__seg button[aria-pressed="true"] { background: linear-gradient(90deg, #2f5bf5, #3b6cff); color: #fff; font-weight: 700; }

.pr-sim__row { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; padding-bottom: 14px; border-bottom: 1px solid #e3e7f5; }
.pr-sim__row > span { color: var(--ink); font-size: 14px; font-weight: 700; }
.pr-sim__stepper { display: flex; align-items: center; gap: 14px; }

.pr-sim__stepper button {
  width: 44px;
  height: 44px;
  border: 1px solid #c9d0ec;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 20px;
}

.pr-sim__stepper button:disabled { opacity: 0.35; cursor: default; }
.pr-sim__stepper output { min-width: 2ch; font-family: "Inter", sans-serif; font-size: 28px; font-weight: 700; text-align: right; }
.pr-sim__stepper small { margin-left: -8px; color: var(--muted); font-size: 13px; }

.pr-sim__receipt { display: grid; gap: 6px; margin-top: 12px; }
.pr-sim__receipt > div { display: flex; align-items: baseline; gap: 10px; font-size: 13.5px; }
.pr-sim__receipt dt { display: flex; flex: 1; align-items: baseline; gap: 10px; color: var(--text); white-space: nowrap; }
.pr-sim__receipt dt::after { content: ""; flex: 1; border-bottom: 1px solid #dde2f4; transform: translateY(-4px); }
.pr-sim__receipt dd b { font-family: "Inter", sans-serif; font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.pr-sim__receipt dd small { margin-left: 4px; font-size: 13px; font-weight: 700; }
.pr-sim__receipt .is-grant dd { color: var(--accent); }

.pr-sim__net { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding: 12px 20px; border-radius: 10px; background: #eef1fb; }
.pr-sim__net > p:first-child { font-size: 15px; font-weight: 800; }
.pr-sim__netval { text-align: right; }
.pr-sim__netval b { color: var(--accent); font-family: "Inter", sans-serif; font-size: 38px; font-weight: 700; line-height: 1.1; }
.pr-sim__netval > small { margin-left: 6px; color: var(--accent); font-size: 18px; font-weight: 700; }
.pr-sim__netval span { display: block; color: var(--muted); font-size: 11.5px; }
.pr-sim__netval em { color: var(--ink); font-style: normal; font-weight: 700; }

.pr-sim__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 54px;
  margin-top: 16px;
  border-radius: 10px;
  background: linear-gradient(90deg, #2f6cf5, #3d4ff0);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 12px 28px rgba(47, 91, 245, 0.35);
  transition: filter 0.2s;
}

.pr-sim__cta:hover { filter: brightness(0.95); }

/* ---------- foot ---------- */
.pr-foot { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 16px; padding: 0 4px; }
.pr-foot p { color: var(--muted); font-size: 12px; }

.pr-foot a {
  display: inline-flex;
  flex: none;
  gap: 8px;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---------- tablet ---------- */
@media (max-width: 1100px) and (min-width: 768px) {
  .pr-head { grid-template-columns: minmax(0, 1fr) 220px; }
  .pr-feats { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; }
  .pr-art { height: 170px; }
  .pr-art img { width: 210px; }
  .pr-art__badge { width: 88px; height: 88px; right: 0; }
  .pr-art__badge b { font-size: 25px; }
}

@media (max-width: 1100px) and (min-width: 768px) {
  .pr { padding: 64px 28px 48px; }
  .pr-body { grid-template-columns: 1fr; }
  .pr-sim { max-width: 560px; }
}

/* ---------- phone ---------- */
@media (max-width: 767px) {
  .pr { padding: 56px 16px 44px; }
  .pr-head { display: flex; flex-direction: column; align-items: stretch; gap: 20px; padding: 0; }
  .pr-title { font-size: clamp(24px, 7vw, 30px); }
  .pr-lead { margin-top: 12px; font-size: 13px; }
  .pr-lead br { display: none; }

  .pr-feats { justify-content: space-between; gap: 8px; }
  .pr-feats li { width: auto; flex: 1; gap: 8px; }
  .pr-feat__icon { width: 50px; height: 50px; }
  .pr-feat__icon svg { width: 22px; height: 22px; }
  .pr-feats p { font-size: 11px; }
  .pr-feats p br { display: none; }
  .pr-art { display: none; }

  /* Simulator first on phones; plans become a swipeable row. */
  .pr-body { display: flex; flex-direction: column-reverse; gap: 22px; margin-top: 22px; }
  .pr-sim { padding: 18px 16px; }
  .pr-sim__net { padding: 12px 14px; }
  .pr-sim__netval b { font-size: 32px; }

  .pr-plans {
    display: grid;
    grid-auto-columns: 78%;
    grid-auto-flow: column;
    grid-template-columns: none;
    gap: 12px;
    margin: 0 -16px;
    padding: 16px 16px 6px;
    overflow-x: auto;
    scroll-padding: 0 16px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .pr-plans::-webkit-scrollbar { display: none; }
  .pr-plan { padding: 18px 18px; scroll-snap-align: start; }
  .pr-plan--pick { order: -1; margin-top: 0; }
  .pr-plan__name { font-size: 20px; }
  .pr-plan__price b { font-size: 36px; }
  .pr-plan__list li { font-size: 13px; }

  .pr-foot { flex-direction: column; align-items: flex-start; gap: 12px; }
  .pr-foot p { font-size: 11px; line-height: 1.7; }
}

/* ---------- desktop: fit one screen (~850px at 1280–1680 wide) ---------- */
@media (min-width: 1101px) {
  .pr { padding: 22px 32px 18px; }
  .pr-head { grid-template-columns: minmax(0, 1fr) auto 240px; gap: 24px; }
  .pr-title { margin-top: 6px; font-size: clamp(28px, 2.6vw, 42px); line-height: 1.3; }
  .pr-lead { margin-top: 10px; font-size: 13.5px; line-height: 1.75; }
  .pr-feats { gap: 16px; }
  .pr-feats li { width: 132px; gap: 8px; }
  .pr-feat__icon { width: 52px; height: 52px; }
  .pr-feat__icon svg { width: 24px; height: 24px; }
  .pr-feats p { font-size: 12px; }
  .pr-art { height: 176px; }
  .pr-art img { width: 230px; }
  .pr-art__badge { width: 92px; height: 92px; right: -6px; }
  .pr-art__badge b { font-size: 26px; }
  .pr-art__badge small { font-size: 11.5px; }

  .pr-body { margin-top: 10px; }
  .pr-plan { padding: 16px 22px 16px; }
  .pr-plan--pick { margin-top: -10px; }
  .pr-plan__name { margin-top: 6px; font-size: 20px; }
  .pr-plan__who { font-size: 12.5px; }
  .pr-plan__price { margin-top: 10px; padding-bottom: 10px; }
  .pr-plan__price b { font-size: 36px; }
  .pr-plan__price b.is-ask { font-size: 28px; line-height: 1.29; }
  .pr-plan__list { gap: 3px; margin-top: 10px; margin-bottom: 14px; }
  .pr-plan__list li { font-size: 13px; }
  .pr-plan__btn { height: 44px; }

  .pr-sim { padding: 14px 20px 16px; }
  .pr-sim__icon { width: 40px; height: 40px; }
  .pr-sim__title { font-size: 17px; }
  .pr-sim__seg { margin-top: 10px; }
  .pr-sim__seg button { padding: 6px; }
  .pr-sim__row { margin-top: 8px; padding-bottom: 8px; }
  .pr-sim__stepper button { width: 38px; height: 38px; }
  .pr-sim__stepper output { font-size: 24px; }
  .pr-sim__receipt { gap: 2px; margin-top: 8px; }
  .pr-sim__net { margin-top: 8px; padding: 8px 18px; }
  .pr-sim__netval b { font-size: 32px; }
  .pr-sim__cta { height: 48px; margin-top: 12px; font-size: 15px; }

  .pr-foot { margin-top: 12px; }
}

@media (min-width: 1101px) and (max-width: 1320px) {
  .pr-head { grid-template-columns: minmax(0, 1fr) auto 190px; }
  .pr-feats li { width: 112px; }
  .pr-feats p { font-size: 11px; }
  .pr-art img { width: 190px; }
  .pr-art__badge { width: 80px; height: 80px; }
  .pr-art__badge b { font-size: 22px; }
  .pr-plan { padding: 16px 18px; }
  .pr-plan__list li { font-size: 12.5px; }
}
