/*
Theme Name: 紅（くれない）為替テーマ
Description: 外国為替証拠金取引・差金決済取引の事業者向け日本語テーマ。証拠金の計算、経済指標、用語集、入出金の案内を備えています。会社情報は「外観 ＞ カスタマイズ ＞ 会社情報」で設定します。
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: kurenai-fx
*/

:root {
  --red: #c8202e;
  --red-d: #a3141f;
  --red-soft: #fcedee;
  --black: #08090b;
  --ink: #1b1b1f;
  --muted: #6b6c72;
  --line: #e4e4e8;
  --soft: #f6f6f7;
  --grey: #f0f0f1;
  --blue: #3aa0ff;
  --amber: #ff8a3d;
  --head: "Murecho", "Noto Sans JP", sans-serif;
  --sans:
    "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: #fff;
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: 0.03em;
  -webkit-font-smoothing: antialiased;
}
a {
  color: var(--red);
}
img {
  max-width: 100%;
  height: auto;
}
:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}
h1,
h2,
h3,
h4 {
  font-family: var(--head);
  letter-spacing: 0.02em;
}
.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}
.narrow {
  max-width: 880px;
}
.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--red);
  color: #fff;
  padding: 8px 16px;
  z-index: 300;
}
.skip:focus {
  left: 8px;
}
.vh {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ヘッダー */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 24px;
  min-height: 96px;
}
.brand {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding-right: 44px;
  text-decoration: none;
  color: var(--ink);
  background: var(--grey);
}
.brand::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  right: 100%;
  width: 100vw;
  background: var(--grey);
}
.brand svg {
  width: 54px;
  height: 54px;
  flex: none;
}
.brand-name {
  display: block;
  font-family: var(--head);
  font-weight: 800;
  font-size: 21px;
  line-height: 1.25;
  letter-spacing: 0.04em;
}
.brand-sub {
  display: block;
  font-size: 11px;
  letter-spacing: 0.32em;
  color: var(--muted);
}
.gnav {
  display: flex;
  align-items: center;
  flex: 1;
}
.gnav > ul {
  display: flex;
  align-items: center;
  gap: 30px;
  list-style: none;
  margin: 0;
  padding: 0 0 0 40px;
  width: 100%;
}
.gnav li.nav-cta {
  margin-left: auto;
}
.gnav a {
  display: block;
  white-space: nowrap;
  text-decoration: none;
  color: #55565c;
  font-size: 15px;
  font-weight: 500;
  padding: 6px 0;
}
.gnav a:hover,
.gnav a[aria-current="page"] {
  color: var(--red);
}
.gnav .has-sub {
  position: relative;
}
.gnav .has-sub > a {
  padding-right: 16px;
}
.gnav .has-sub > a::after {
  content: "";
  position: absolute;
  right: 0;
  top: 50%;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-70%) rotate(45deg);
}
.gnav .sub {
  display: none;
  position: absolute;
  left: -20px;
  top: 100%;
  min-width: 240px;
  background: #fff;
  list-style: none;
  margin: 0;
  padding: 10px 0;
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}
.gnav .sub a {
  padding: 9px 22px;
  font-size: 14px;
}
.gnav .sub a:hover {
  background: var(--soft);
}
.gnav .has-sub:hover .sub,
.gnav .has-sub:focus-within .sub {
  display: block;
}
.gnav .nav-cta a {
  background: var(--red);
  color: #fff;
  padding: 15px 30px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.gnav .nav-cta a:hover {
  background: var(--red-d);
  color: #fff;
}
.menu-toggle {
  display: none;
  align-self: center;
  background: var(--red);
  color: #fff;
  border: 0;
  font: inherit;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 18px;
  border-radius: 999px;
  cursor: pointer;
}

/* ボタン */
.btn {
  display: inline-block;
  background: var(--red);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.06em;
  padding: 16px 32px;
  border-radius: 999px;
  border: 2px solid var(--red);
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s;
  cursor: pointer;
  font-family: inherit;
}
.btn:hover {
  background: var(--red-d);
  border-color: var(--red-d);
  color: #fff;
}
.btn-ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}
.btn-ghost:hover {
  background: #fff;
  color: var(--ink);
  border-color: #fff;
}
.btn-line {
  background: #fff;
  color: var(--ink);
  border-color: var(--ink);
}
.btn-line:hover {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.btn-sm {
  padding: 10px 20px;
  font-size: 13px;
}
.actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* ヒーロー */
.hero {
  position: relative;
  background: var(--black);
  color: #fff;
  overflow: hidden;
  min-height: 720px;
  display: flex;
  align-items: center;
}
.hero-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(8, 9, 11, 0.92) 0%,
    rgba(8, 9, 11, 0.7) 42%,
    rgba(8, 9, 11, 0.15) 78%,
    rgba(8, 9, 11, 0.3) 100%
  );
}
.hero .wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-top: 90px;
  padding-bottom: 90px;
}
.kicker {
  display: inline-block;
  font-family: var(--head);
  font-weight: 700;
  font-size: 17px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--red);
  margin: 0 0 26px;
}
.hero h1 {
  font-weight: 700;
  font-size: clamp(40px, 6.2vw, 88px);
  line-height: 1.22;
  margin: 0 0 26px;
}
.hero h1 span {
  display: block;
  white-space: nowrap;
}
.hero-lead {
  max-width: 36em;
  color: #c9cbd1;
  margin: 0 0 34px;
}
.hero-label {
  color: var(--red);
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 15px;
  margin: 46px 0 12px;
}
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.trust div {
  background: #fff;
  color: var(--ink);
  border-radius: 6px;
  padding: 12px 20px;
  min-width: 170px;
}
.trust small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.06em;
}
.trust b {
  display: block;
  font-family: var(--head);
  font-size: 16px;
}
.hero .wrap > * {
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.hero .wrap > *:nth-child(2) {
  animation-delay: 0.08s;
}
.hero .wrap > *:nth-child(3) {
  animation-delay: 0.16s;
}
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* セクション */
.section {
  padding: 110px 0;
  position: relative;
}
.section-soft {
  background: var(--soft);
}
.section-soft.shapes {
  background:
    linear-gradient(
      135deg,
      transparent 0 30%,
      rgba(0, 0, 0, 0.018) 30% 46%,
      transparent 46%
    ),
    linear-gradient(
      45deg,
      transparent 0 62%,
      rgba(0, 0, 0, 0.02) 62% 78%,
      transparent 78%
    ),
    var(--soft);
}
.title {
  font-weight: 700;
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.35;
  margin: 0 0 22px;
}
.title-c {
  text-align: center;
}
.lead {
  color: var(--muted);
  max-width: 40em;
  margin: 0 0 34px;
}
.title-c + .lead {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
}

/* 写真風の組み合わせ */
.collage {
  position: relative;
  padding: 40px 40px 0 0;
}
.collage::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 76%;
  height: 88%;
  background: repeating-linear-gradient(-45deg, #ededee 0 2px, #fff 2px 9px);
}
.collage .c-main {
  position: relative;
  display: block;
  width: 92%;
  aspect-ratio: 1/1;
}
.collage .c-sub {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 48%;
  aspect-ratio: 4/5;
  border: 6px solid #fff;
  object-fit: cover;
}

/* 数字 */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  list-style: none;
  margin: 56px 0 0;
  padding: 0;
}
.stats li {
  padding: 8px 34px;
  border-left: 1px solid #cfcfd4;
}
.stats li:first-child {
  border-left: 0;
  padding-left: 0;
}
.stats b {
  display: block;
  font-family: var(--head);
  font-weight: 700;
  color: var(--red);
  font-size: clamp(40px, 4.6vw, 50px);
  line-height: 1.15;
}
.stats b small {
  font-size: 0.45em;
  margin-left: 4px;
}
.stats span {
  display: block;
  font-size: 16px;
  font-weight: 500;
  margin-top: 6px;
}
.stats em {
  display: block;
  font-style: normal;
  font-size: 12px;
  color: var(--muted);
}

/* 市場の円図 */
.orbit {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  display: block;
}
.orbit a:hover circle.node {
  fill: var(--red-d);
}
.orbit a:focus-visible {
  outline: none;
}
.orbit a:focus-visible circle.node {
  stroke: var(--amber);
  stroke-width: 5;
}

/* 通貨ペアの帯 */
.marquee {
  overflow: hidden;
  mask-image: linear-gradient(
    90deg,
    transparent,
    #000 8%,
    #000 92%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    90deg,
    transparent,
    #000 8%,
    #000 92%,
    transparent
  );
  margin-top: 18px;
}
.marquee ul {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 6px 0;
  width: max-content;
  animation: slide 48s linear infinite;
}
.marquee.rev ul {
  animation-direction: reverse;
  animation-duration: 56s;
}
.marquee:hover ul {
  animation-play-state: paused;
}
@keyframes slide {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}
.pair {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 16px 26px;
  min-width: 220px;
  white-space: nowrap;
}
.pair svg {
  width: 52px;
  height: 30px;
  flex: none;
}
.pair b {
  font-family: var(--head);
  font-size: 17px;
}
.pair small {
  display: block;
  font-size: 11px;
  color: var(--muted);
}

/* 計算機 */
.calc {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 0;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.08);
  background: #fff;
}
.calc form {
  padding: 40px 40px 34px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 20px;
  align-content: start;
}
.calc label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}
.calc input,
.calc select {
  width: 100%;
  font: inherit;
  font-size: 16px;
  padding: 12px 14px;
  border: 1px solid #cfcfd5;
  border-radius: 10px;
  background: #fff;
}
.calc .full {
  grid-column: 1/-1;
}
.calc .hint {
  font-size: 12px;
  color: var(--muted);
  margin: 4px 0 0;
}
.calc-out {
  background: var(--black);
  color: #fff;
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.calc-out h3 {
  margin: 0 0 14px;
  font-size: 18px;
  color: #fff;
}
.calc-out dl {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0;
}
.calc-out dt,
.calc-out dd {
  padding: 13px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  margin: 0;
  font-size: 14px;
}
.calc-out dt {
  color: #bfc1c8;
}
.calc-out dd {
  text-align: right;
  font-family: var(--head);
  font-weight: 700;
  font-size: 20px;
}
.calc-out dd.big {
  color: #ff5964;
  font-size: 26px;
}
.calc-out .gauge {
  height: 8px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  margin: 18px 0 6px;
  overflow: hidden;
}
.calc-out .gauge i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #ff5964, #ffb23d, #3fd08a);
  transition: width 0.3s;
}
.calc-out .warn {
  font-size: 12px;
  color: #bfc1c8;
  margin: 12px 0 0;
}
.calc-out .state {
  font-size: 13px;
  font-weight: 700;
}

/* 表 */
.table-scroll {
  overflow-x: auto;
  margin: 0 0 18px;
}
.tbl {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
  font-size: 15px;
  background: #fff;
}
.tbl th,
.tbl td {
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.tbl thead th {
  background: var(--black);
  color: #fff;
  font-weight: 500;
  font-size: 14px;
}
.tbl tbody th {
  font-weight: 700;
  width: 24%;
}
.tbl tbody tr:hover td,
.tbl tbody tr:hover th {
  background: #fbfbfc;
}
.stars {
  color: var(--red);
  letter-spacing: 0.1em;
}
.stars i {
  color: #d8d8dd;
  font-style: normal;
}
.flag-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}
.flag-cell svg {
  width: 30px;
  height: 20px;
  flex: none;
  border: 1px solid var(--line);
}
.note {
  font-size: 12.5px;
  color: var(--muted);
}

/* 特長 */
.feats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.feats li {
  background: #fff;
  border-radius: 18px;
  padding: 30px 26px;
  border: 1px solid var(--line);
}
.feats svg {
  width: 46px;
  height: 46px;
  color: var(--red);
}
.feats h3 {
  font-size: 18px;
  margin: 16px 0 8px;
  line-height: 1.5;
}
.feats p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

/* 勉強会の横送り */
.row-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}
.row-head .title {
  margin: 0;
}
.arrows {
  display: flex;
  gap: 10px;
}
.arrows button {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 0;
  background: var(--red);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.arrows button:hover {
  background: var(--red-d);
}
.arrows svg {
  width: 18px;
  height: 18px;
}
.slider {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 60px) / 4);
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding-bottom: 6px;
}
.slider::-webkit-scrollbar {
  display: none;
}
.event {
  scroll-snap-align: start;
  background: #fff;
  border: 1px solid var(--line);
  padding: 26px 24px 28px;
  display: flex;
  flex-direction: column;
}
.event time {
  font-family: var(--head);
  font-weight: 700;
  color: var(--red);
  font-size: 30px;
  line-height: 1;
}
.event time small {
  display: block;
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
  margin-top: 6px;
  font-family: var(--sans);
}
.event h3 {
  font-size: 17px;
  line-height: 1.6;
  margin: 18px 0 10px;
}
.event p {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 16px;
  flex: 1;
}
.tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.tag {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--red-soft);
  color: var(--red);
}
.tag.dark {
  background: var(--ink);
  color: #fff;
}

/* お知らせ・読み物 */
.two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
}
.list-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 24px;
  margin: 0 0 18px;
  padding-bottom: 14px;
  border-bottom: 2px solid var(--ink);
}
.list-title a {
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
}
.list-title a:hover {
  color: var(--red);
}
.plist {
  list-style: none;
  margin: 0;
  padding: 0;
}
.plist a {
  display: block;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}
.plist a:hover span {
  color: var(--red);
}
.plist time {
  display: block;
  font-size: 12px;
  color: var(--muted);
}
.plist span {
  font-weight: 500;
}

/* 黒い帯 */
.band {
  position: relative;
  background: var(--black);
  color: #fff;
  text-align: center;
  padding: 120px 0;
  overflow: hidden;
}
.band-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.55;
}
.band::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(8, 9, 11, 0.55);
}
.band .wrap {
  position: relative;
  z-index: 2;
}
.band h2 {
  font-weight: 700;
  font-size: clamp(28px, 4vw, 50px);
  line-height: 1.4;
  margin: 0 0 18px;
}
.band p {
  color: #c9cbd1;
  margin: 0 auto 34px;
  max-width: 36em;
}

/* 下層ヒーロー */
.page-hero {
  position: relative;
  background: var(--black);
  color: #fff;
  overflow: hidden;
  padding: 96px 0 84px;
}
.page-hero .hero-art {
  opacity: 0.6;
}
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(8, 9, 11, 0.95) 0%,
    rgba(8, 9, 11, 0.7) 55%,
    rgba(8, 9, 11, 0.35) 100%
  );
}
.page-hero .wrap {
  position: relative;
  z-index: 2;
}
.crumbs {
  font-size: 12px;
  color: #9c9ea6;
  margin: 0 0 22px;
}
.crumbs a {
  color: #c9cbd1;
  text-decoration: none;
}
.crumbs a:hover {
  color: #fff;
}
.page-hero h1 {
  font-size: clamp(32px, 4.8vw, 58px);
  line-height: 1.3;
  margin: 0 0 16px;
  font-weight: 700;
}
.page-hero p.lead {
  color: #c9cbd1;
  margin: 0;
}

/* 下層：見出しと本文 */
.prose {
  max-width: 860px;
}
.wrap.prose-wide {
  max-width: 1180px;
}
.prose > p,
.prose li {
  color: #3a3b40;
}
.prose h2 {
  font-size: clamp(24px, 2.6vw, 32px);
  line-height: 1.45;
  margin: 64px 0 18px;
}
.prose h2:first-child {
  margin-top: 0;
}
.prose h2::before {
  content: "";
  display: block;
  width: 44px;
  height: 4px;
  background: var(--red);
  border-radius: 4px;
  margin-bottom: 16px;
}
.prose h3 {
  font-size: 19px;
  margin: 34px 0 10px;
}
.prose ul,
.prose ol {
  padding-left: 1.4em;
  margin: 0 0 1.2em;
}
.prose li {
  margin-bottom: 0.45em;
}
.prose p {
  margin: 0 0 1.2em;
}
.dots {
  list-style: none;
  padding: 0 !important;
}
.dots li {
  position: relative;
  padding-left: 22px;
}
.dots li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.72em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
}
.risk-box {
  border-left: 5px solid var(--red);
  background: var(--red-soft);
  padding: 22px 26px;
  margin: 30px 0;
  border-radius: 0 12px 12px 0;
}
.risk-box h3 {
  margin: 0 0 6px;
  font-size: 16px;
  color: var(--red-d);
}
.risk-box p,
.risk-box ul {
  margin: 0;
  font-size: 14px;
}
.risk-box ul {
  padding-left: 1.2em;
}
.info-box {
  background: var(--soft);
  border-radius: 16px;
  padding: 24px 28px;
  margin: 26px 0;
  font-size: 14px;
}
.info-box h3 {
  margin: 0 0 6px;
  font-size: 16px;
}
.info-box p {
  margin: 0;
}
.formula {
  font-family: var(--head);
  font-weight: 700;
  background: #fff;
  border: 1px dashed #c9c9cf;
  border-radius: 12px;
  padding: 16px 20px;
  margin: 12px 0 20px;
  text-align: center;
  font-size: 17px;
}

/* 市場ページのタブ */
.tabs {
  position: sticky;
  top: 96px;
  z-index: 20;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.tabs ul {
  display: flex;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 14px 0;
  overflow-x: auto;
}
.tabs a {
  display: block;
  white-space: nowrap;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 14px;
  padding: 9px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
}
.tabs a:hover {
  border-color: var(--red);
  color: var(--red);
}
.market {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 56px;
  padding: 90px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 170px;
}
.market:last-child {
  border-bottom: 0;
}
.market .panel {
  width: 100%;
  aspect-ratio: 4/5;
  border-radius: 20px;
  position: sticky;
  top: 180px;
}
.mini-cond {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
  margin: 22px 0;
  border-radius: 14px;
  overflow: hidden;
}
.mini-cond div {
  padding: 18px 20px;
  border-left: 1px solid var(--line);
}
.mini-cond div:first-child {
  border-left: 0;
}
.mini-cond dt {
  font-size: 12px;
  color: var(--muted);
}
.mini-cond dd {
  margin: 2px 0 0;
  font-family: var(--head);
  font-weight: 700;
  font-size: 22px;
  color: var(--red);
}

/* 手順 */
.steps {
  list-style: none;
  counter-reset: s;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.steps li {
  counter-increment: s;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px 24px;
  position: relative;
}
.steps li::before {
  content: counter(s);
  display: flex;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  background: var(--red);
  color: #fff;
  font-family: var(--head);
  font-weight: 700;
  font-size: 18px;
  margin-bottom: 16px;
}
.steps h3 {
  font-size: 17px;
  margin: 0 0 6px;
}
.steps p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

.checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.checklist label {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 18px;
  cursor: pointer;
}
.checklist input {
  width: 20px;
  height: 20px;
  accent-color: var(--red);
  margin-top: 4px;
  flex: none;
}
.check-meter {
  font-weight: 700;
  margin: 16px 0 0;
}

.acct-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  align-items: stretch;
}
.acct {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 34px 30px;
  display: flex;
  flex-direction: column;
  scroll-margin-top: 120px;
  position: relative;
}
.acct.pick {
  border: 2px solid var(--red);
  box-shadow: 0 24px 50px rgba(200, 32, 46, 0.12);
}
.acct .badge {
  position: absolute;
  top: -14px;
  left: 30px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 999px;
}
.acct h3 {
  font-size: 22px;
  margin: 0 0 4px;
}
.acct .for {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 20px;
}
.acct .num {
  font-family: var(--head);
  font-weight: 700;
  color: var(--red);
  font-size: 44px;
  line-height: 1.1;
  margin: 0;
}
.acct .num small {
  font-size: 16px;
  margin-left: 4px;
  color: var(--ink);
}
.acct .unit {
  font-size: 12px;
  color: var(--muted);
  margin: 2px 0 20px;
}
.acct ul {
  list-style: none;
  margin: 0 0 26px;
  padding: 0;
  flex: 1;
}
.acct li {
  position: relative;
  padding: 9px 0 9px 26px;
  border-top: 1px solid var(--line);
  font-size: 14px;
}
.acct li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 15px;
  width: 12px;
  height: 7px;
  border-left: 2px solid var(--red);
  border-bottom: 2px solid var(--red);
  transform: rotate(-45deg);
}
.acct .btn {
  text-align: center;
}
.chooser {
  background: var(--black);
  color: #fff;
  border-radius: 24px;
  padding: 44px;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 44px;
  align-items: center;
}
.chooser h2 {
  color: #fff;
  font-size: clamp(24px, 3vw, 34px);
  margin: 0 0 6px;
}
.chooser > div > p {
  color: #bfc1c8;
  margin: 0 0 24px;
  font-size: 14px;
}
.chooser fieldset {
  border: 0;
  margin: 0 0 18px;
  padding: 0;
}
.chooser legend {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 8px;
}
.opts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.opts label {
  cursor: pointer;
}
.opts input {
  position: absolute;
  opacity: 0;
}
.opts span {
  display: block;
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 14px;
}
.opts input:checked + span {
  background: var(--red);
  border-color: var(--red);
}
.opts input:focus-visible + span {
  outline: 3px solid var(--amber);
}
.opts input:disabled + span {
  opacity: 0.35;
  cursor: not-allowed;
}
.result {
  background: #fff;
  color: var(--ink);
  border-radius: 18px;
  padding: 30px;
}
.result small {
  display: block;
  color: var(--muted);
  font-size: 13px;
}
.result b {
  display: block;
  font-family: var(--head);
  font-size: 28px;
  color: var(--red);
  margin: 4px 0 10px;
}
.result p {
  margin: 0 0 18px;
  font-size: 14px;
}
.chooser .wait {
  color: #bfc1c8;
  font-size: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.3);
  border-radius: 18px;
  padding: 30px;
  margin: 0;
}
.struct {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  align-items: center;
  margin: 24px 0;
}
.struct div {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  text-align: center;
}
.struct div b {
  display: block;
  font-family: var(--head);
}
.struct div small {
  color: var(--muted);
  font-size: 12px;
}
.struct .hub {
  grid-column: 1/-1;
  background: var(--red);
  color: #fff;
  border: 0;
}
.struct .hub small {
  color: #ffd9dc;
}

/* 用語集 */
.kana-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 40px;
  list-style: none;
  padding: 0;
}
.kana-nav a {
  display: flex;
  width: 46px;
  height: 46px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
}
.kana-nav a:hover {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}
.gloss {
  margin: 0 0 44px;
  scroll-margin-top: 120px;
}
.gloss h2 {
  font-size: 28px;
  color: var(--red);
  margin: 0 0 6px;
}
.gloss dl {
  margin: 0;
}
.gloss dt {
  font-weight: 700;
  font-size: 17px;
  padding-top: 18px;
  font-family: var(--head);
}
.gloss dt small {
  font-weight: 500;
  font-size: 12px;
  color: var(--muted);
  margin-left: 10px;
  font-family: var(--sans);
}
.gloss dd {
  margin: 4px 0 0;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  color: #3a3b40;
  font-size: 15px;
}
.gloss-search {
  width: 100%;
  max-width: 460px;
  font: inherit;
  padding: 14px 18px;
  border: 1px solid #cfcfd5;
  border-radius: 999px;
  margin: 0 0 20px;
}

/* 質問 */
.faq details {
  border-bottom: 1px solid var(--line);
}
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 22px 52px 22px 0;
  font-weight: 700;
  font-size: 16px;
  position: relative;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  width: 24px;
  height: 24px;
  margin-top: -12px;
  border-radius: 50%;
  background: var(--red)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 12h10M12 7v10' stroke='%23fff' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E")
    center/18px no-repeat;
}
.faq details[open] summary::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 12h10' stroke='%23fff' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
}
.faq details p {
  margin: 0 0 22px;
  color: var(--muted);
}
.faq-cat {
  font-size: 22px;
  margin: 56px 0 4px;
}
.faq-cat:first-child {
  margin-top: 0;
}

/* フォーム */
.form {
  display: grid;
  gap: 22px;
  max-width: 760px;
}
.form label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
  font-size: 15px;
}
.form .req {
  background: var(--red);
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  margin-left: 8px;
  border-radius: 999px;
  font-weight: 500;
}
.form input[type="text"],
.form input[type="email"],
.form input[type="tel"],
.form select,
.form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #cfcfd5;
  border-radius: 12px;
  font: inherit;
  background: #fff;
}
.form textarea {
  min-height: 180px;
}
.form .agree {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-weight: 400;
}
.contact-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 64px;
}
.contact-cards div {
  background: var(--soft);
  border-radius: 18px;
  padding: 28px;
}
.contact-cards h3 {
  margin: 0 0 8px;
  font-size: 15px;
  color: var(--muted);
  font-family: var(--sans);
  font-weight: 500;
}
.contact-cards p {
  margin: 0;
}
.contact-cards .big {
  font-family: var(--head);
  font-weight: 700;
  font-size: 24px;
}

/* 沿革 */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--line);
}
.timeline li {
  position: relative;
  padding: 0 0 26px 30px;
}
.timeline li::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 0.55em;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--red);
}
.timeline b {
  display: block;
  font-family: var(--head);
}

/* フッター */
.site-footer {
  position: relative;
  background: var(--black);
  color: #c9cbd1;
  padding: 80px 0 0;
  overflow: hidden;
  font-size: 14px;
}
.footer-map {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
  width: 1500px;
  max-width: none;
  height: 100%;
  opacity: 0.07;
  pointer-events: none;
}
.site-footer .wrap {
  position: relative;
  z-index: 2;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr 1.25fr;
  gap: 40px;
}
.footer-brand .brand {
  background: transparent;
  padding: 0;
  color: #fff;
}
.footer-brand .brand::before {
  display: none;
}
.footer-brand .brand-sub {
  color: #9c9ea6;
}
.footer-brand p {
  font-size: 13px;
  line-height: 2;
  margin: 18px 0 0;
}
.site-footer h3 {
  color: #fff;
  font-size: 20px;
  margin: 0 0 20px;
}
.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-footer li {
  margin: 0 0 12px;
}
.site-footer li a {
  color: #c9cbd1;
  text-decoration: none;
}
.site-footer li a:hover {
  color: #fff;
}
.site-footer address {
  font-style: normal;
  line-height: 2;
}
.site-footer address b {
  display: block;
  color: #fff;
  margin-top: 14px;
  font-size: 13px;
}
.disclosure {
  margin: 56px 0 0;
  padding: 22px 26px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  font-size: 12px;
  line-height: 1.95;
  color: #a9abb3;
}
.disclosure strong {
  color: #fff;
  font-weight: 700;
}
.disclosure a {
  color: #fff;
}
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  margin-top: 40px;
  padding: 24px 0 30px;
  text-align: center;
  font-size: 13px;
  color: #8e9099;
}
.to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  box-shadow: 0 10px 24px rgba(200, 32, 46, 0.35);
}
.to-top svg {
  width: 20px;
  height: 20px;
}

.cookie-bar {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 90;
  max-width: 520px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  padding: 22px 24px;
  display: none;
  font-size: 13px;
}
.cookie-bar.show {
  display: block;
}
.cookie-bar p {
  margin: 0 0 14px;
  line-height: 1.75;
}
.cookie-bar .actions {
  gap: 8px;
}

@media (max-width: 1100px) {
  .gnav > ul {
    gap: 20px;
    padding-left: 24px;
  }
  .gnav a {
    font-size: 14px;
  }
  .gnav .nav-cta a {
    padding: 12px 22px;
  }
}
@media (max-width: 980px) {
  .header-inner {
    min-height: 76px;
    gap: 12px;
  }
  .brand {
    padding-right: 24px;
  }
  .brand svg {
    width: 44px;
    height: 44px;
  }
  .menu-toggle {
    display: block;
  }
  .gnav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: #fff;
    display: none;
    border-bottom: 1px solid var(--line);
    max-height: calc(100vh - 76px);
    overflow: auto;
    padding: 0 24px 24px;
  }
  .gnav.open {
    display: block;
  }
  .gnav > ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0;
  }
  .gnav a {
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
  }
  .gnav .has-sub > a::after {
    display: none;
  }
  .gnav .sub {
    display: block;
    position: static;
    box-shadow: none;
    padding: 0 0 0 16px;
    min-width: 0;
    border-radius: 0;
  }
  .gnav li.nav-cta {
    margin: 16px 0 0;
  }
  .gnav .nav-cta a {
    text-align: center;
    border: 0;
  }
  .tabs {
    top: 76px;
  }
  .split,
  .two,
  .calc {
    grid-template-columns: 1fr;
  }
  .split {
    gap: 48px;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
    row-gap: 30px;
  }
  .stats li:nth-child(3) {
    border-left: 0;
    padding-left: 0;
  }
  .feats {
    grid-template-columns: 1fr 1fr;
  }
  .slider {
    grid-auto-columns: calc((100% - 20px) / 2);
  }
  .market {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 64px 0;
  }
  .market .panel {
    position: static;
    aspect-ratio: 16/9;
    max-width: 560px;
  }
  .steps {
    grid-template-columns: 1fr 1fr;
  }
  .contact-cards {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 620px) {
  .section {
    padding: 72px 0;
  }
  .hero {
    min-height: 0;
  }
  .hero .wrap {
    padding-top: 64px;
    padding-bottom: 64px;
  }
  .hero h1 {
    font-size: 38px;
  }
  .trust div {
    min-width: 0;
    flex: 1 1 100%;
  }
  .stats li {
    padding: 8px 0 8px 18px;
  }
  .stats li:nth-child(odd) {
    border-left: 0;
    padding-left: 0;
  }
  .feats,
  .steps {
    grid-template-columns: 1fr;
  }
  .slider {
    grid-auto-columns: 85%;
  }
  .calc form {
    grid-template-columns: 1fr;
    padding: 28px 22px;
  }
  .calc-out {
    padding: 28px 22px;
  }
  .mini-cond {
    grid-template-columns: 1fr;
  }
  .mini-cond div {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .mini-cond div:first-child {
    border-top: 0;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .row-head {
    flex-direction: column;
    align-items: flex-start;
  }
  .cookie-bar {
    left: 12px;
    right: 12px;
    bottom: 86px;
  }
  .pair {
    min-width: 180px;
    padding: 12px 18px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
  html {
    scroll-behavior: auto;
  }
  .marquee ul {
    animation: none;
  }
}
