:root {
  --bg: #f8fafc;
  --ink: #1e293b;
  --ink-light: #475569;
  --soft: #64748b;
  --line: #e2e8f0;
  --card: #ffffff;
  --hi: #2e7d32;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.04);
  --shadow-md: 0 8px 24px -4px rgba(0,0,0,0.07);
  --radius: 12px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  font-family: "Noto Sans JP", -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.85;
  letter-spacing: 0.02em;
}
a { color: inherit; text-decoration: none; transition: 0.2s ease; }
img { max-width: 100%; display: block; }

/* ヘッダー */
.gh {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px;
  padding: 0 20px; height: 68px;
}
.gh .logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; }
.gh .logo img { height: 34px; width: auto; }
.gh nav { display: none; margin-left: auto; gap: 24px; font-size: 14px; font-weight: 500; align-items: center; }
.gh nav a:hover { color: var(--hi); }
.sns { display: flex; gap: 12px; align-items: center; }
.sns svg { width: 18px; height: 18px; fill: currentColor; }
.gh .cta-btn {
  margin-left: auto; background: var(--hi); color: #fff;
  height: 42px; display: flex; align-items: center; padding: 0 16px;
  font-size: 13px; font-weight: 600; border-radius: 9999px;
  box-shadow: 0 2px 8px rgba(46,125,50,0.25);
  white-space: nowrap;
}
.gh .cta-btn:hover { background: #256629; }
.menu-btn { background: none; border: none; width: 44px; height: 44px; cursor: pointer; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.menu-btn i { display: block; width: 22px; height: 2px; background: var(--ink); }
@media(min-width: 900px){ .gh nav { display: flex; } .menu-btn { display: none; } }

/* ドロワー */
.drawer {
  position: fixed; top: 68px; inset-inline: 0; bottom: 0;
  background: #fff; z-index: 49; overflow-y: auto;
  padding: 24px 28px 48px; border-top: 1px solid var(--line);
  opacity: 0; pointer-events: none; transition: 0.25s;
}
body.open .drawer { opacity: 1; pointer-events: auto; }
.drawer h4 { font-size: 11px; letter-spacing: 0.1em; color: var(--hi); margin: 20px 0 8px; }
.drawer a { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.drawer a small { color: var(--soft); font-size: 12px; }

/* ヒーローセクション */
.hero {
  position: relative; min-height: 80svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  color: #fff; background: #111; overflow: hidden;
}
.hero .bg {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  filter: brightness(0.8);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,23,42,0.2) 0%, rgba(15,23,42,0.85) 90%);
}
.hero > *:not(.bg) { position: relative; z-index: 2; }
.hin { max-width: 1040px; width: 100%; margin: 0 auto; padding: 60px 24px 36px; }
.hlogo {
  display: inline-flex; align-items: center; gap: 10px;
  background: rgba(255,255,255,0.18); backdrop-filter: blur(8px);
  padding: 8px 18px; border-radius: 9999px; margin-bottom: 20px;
}
.hlogo img { width: 28px; height: 28px; }
.hin .en { color: #86efac; font-size: 12px; letter-spacing: 0.15em; }
.copy { font-size: clamp(32px, 5.5vw, 52px); font-weight: 700; line-height: 1.35; margin-top: 14px; }
.hero .hin h1.copy {
  color: #fff !important;
  font-size: clamp(32px, 5.5vw, 52px) !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
  margin: 14px 0 0 !important;
}
.hero .hin h1.copy .where {
  display: block;
  margin-top: 10px;
  font-size: 13px !important;
  font-weight: 500 !important;
  letter-spacing: 0.12em;
  color: #e2e8f0;
}
.acc {
  background: rgba(15,23,42,0.6); backdrop-filter: blur(8px);
  border-top: 1px solid rgba(255,255,255,0.12);
  padding: 14px 24px; font-size: 13px; color: #e2e8f0; text-align: center;
}

/* 共通セクション */
section.blk { padding: 80px 24px; max-width: 1080px; margin: 0 auto; }
.h { margin-bottom: 36px; }
.h .en { color: var(--hi); font-weight: 700; font-size: 12px; letter-spacing: 0.12em; }
.h h2 { font-size: 30px; font-weight: 700; color: var(--ink); margin-top: 6px; }
.h p { color: var(--soft); font-size: 15px; margin-top: 8px; }

/* 対象者導線 (ENTRY) */
.aud { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media(min-width: 900px){ .aud { grid-template-columns: repeat(4, 1fr); } }
.aud a {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 18px; box-shadow: var(--shadow-sm); font-weight: 700; font-size: 17px;
  display: flex; flex-direction: column; justify-content: center;
}
.aud a small { font-size: 12px; font-weight: 400; color: var(--soft); margin-top: 6px; }
.aud a:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--hi); }

/* 事業カード */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.sc {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); display: flex; flex-direction: column;
}
.sc:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.sc .th { aspect-ratio: 16/10; background-size: cover; background-position: center; background-color: #f1f5f9; }
.sc .th.t { display: flex; align-items: center; justify-content: center; }
.sc .bd { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.sc .nm { font-size: 19px; font-weight: 700; color: var(--ink); }
.sc .ct {
  display: inline-block; font-size: 11.5px; font-weight: 600;
  padding: 4px 10px; border-radius: 9999px; margin-top: 8px; align-self: flex-start;
  background: #f1f5f9; color: var(--ink-light);
}
.sc .ln { font-size: 14px; color: var(--ink-light); margin-top: 12px; line-height: 1.65; }

/* 下層ページ（RYDEENなど）の装飾 */
.hin h1, .hin h1.deco, .prose h1 {
  font-size: clamp(30px, 5vw, 44px) !important; font-weight: 800 !important;
  color: #0f172a !important; margin: 16px 0 !important;
}
.hin .plogo { width: 100px; height: 100px; border-radius: 20px; box-shadow: 0 8px 24px rgba(0,0,0,0.12); margin-bottom: 20px; }
.svc, .prose .svc {
  display: inline-block !important; background: #e0f2fe !important; color: #0369a1 !important;
  font-size: 13px !important; font-weight: 600 !important; padding: 4px 14px !important;
  border-radius: 9999px !important; border: 1px solid #bae6fd !important; margin: 8px 0 16px !important;
}
.prose h2, .blk h2:not(.h h2) {
  font-size: 26px !important; font-weight: 700 !important; color: #0f172a !important;
  border-left: 6px solid #2e7d32 !important; border-bottom: 1px solid var(--line) !important;
  padding: 4px 0 8px 16px !important; margin: 40px 0 16px !important;
}
.prose p {
  font-size: 16px !important; line-height: 2 !important; color: #334155 !important;
  margin-bottom: 20px !important;
}

/* ボタンとCTA */
.btn, .go {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 28px; border-radius: 8px; background: var(--ink); color: #fff;
  font-weight: 600; font-size: 14.5px;
}
.btn:hover, .go:hover { background: var(--hi); transform: translateY(-2px); }
.cta {
  background: #f1f5f9; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 80px 24px; text-align: center;
}
.cta .row { display: flex; gap: 14px; max-width: 440px; margin: 28px auto 0; }
.cta .row a { flex: 1; padding: 14px 0; border-radius: 8px; font-weight: 600; }
.cta .w { background: var(--hi); color: #fff; }
.cta .o { background: #fff; border: 1px solid var(--line); color: var(--ink); }
.cta .tnum { display: inline-block; margin-top: 18px; font-size: 24px; font-weight: 700; color: var(--ink); }

/* フッター */
.gf { background: #fff; border-top: 1px solid var(--line); padding: 60px 24px 80px; font-size: 13px; color: var(--ink-light); }
.gf .in { max-width: 1080px; margin: 0 auto; display: grid; gap: 36px; }
@media(min-width: 900px){ .gf .in { grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr; } }
.gf h5 { font-size: 12px; font-weight: 700; color: var(--ink); margin-bottom: 12px; }
.gf ul { list-style: none; }
.gf li { margin-bottom: 8px; }
.gf .cp { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 20px; color: var(--soft); }

/* フローティング相談ボタン */
.fab {
  position: fixed; right: 20px; bottom: 24px; z-index: 40;
  background: var(--hi); color: #fff; font-size: 15px; font-weight: 600;
  padding: 13px 26px; border-radius: 9999px; box-shadow: 0 6px 20px rgba(46,125,50,0.35);
}
@media(min-width: 900px){ .fab { display: none; } }

/* Restored subpage layout from 2f446d2 (v=20261102e).
   Scoped to body.sub-layout so the top page and hand-placed pages
   (レオ, 茶夢, leo/assessment, 梁山泊, 金斗雲) are unchanged. */
body.sub-layout { --sub-accent: #1f2937; }

body.sub-layout .hero .hin h1,
body.sub-layout .hero .hin h1.long {
  color: #fff !important;
  font-weight: 700 !important;
  font-size: 30px !important;
  letter-spacing: -0.01em !important;
  margin: 16px 0 !important;
  line-height: 1.2 !important;
}
@media (min-width: 900px) {
  body.sub-layout .hero .hin h1,
  body.sub-layout .hero .hin h1.long {
    font-size: 64px !important;
  }
}

body.sub-layout .hero.short { min-height: 72svh; }

body.sub-layout .h h2 { font-size: 28px; line-height: 1.3; }
@media (min-width: 900px) {
  body.sub-layout .h h2 { font-size: 36px; }
}

body.sub-layout .gal {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  max-width: 1040px;
  margin: 0 auto;
}
body.sub-layout .gal img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}
@media (min-width: 900px) {
  body.sub-layout .gal { grid-template-columns: repeat(4, 1fr); }
}

body.sub-layout dl.info {
  display: grid;
  grid-template-columns: 6.5em 1fr;
  border-top: 2px solid var(--ink);
  font-size: 14px;
}
body.sub-layout dl.info dt,
body.sub-layout dl.info dd {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
body.sub-layout dl.info dt {
  color: var(--soft);
  letter-spacing: 0.02em;
}
@media (min-width: 900px) {
  body.sub-layout dl.info { font-size: 18px; }
}

body.sub-layout .lst {
  list-style: none;
  border-top: 2px solid var(--ink);
}
body.sub-layout .lst li {
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
  font-size: 14px;
}
body.sub-layout .lst li b { display: block; font-size: 15px; }
body.sub-layout .lst a {
  text-decoration: none;
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
body.sub-layout .lst a:after { content: "→"; color: var(--hi); }
@media (min-width: 900px) {
  body.sub-layout .lst li { font-size: 18px; }
  body.sub-layout .lst li b { font-size: 19px; }
}

body.sub-layout .big30 {
  font-family: "Inter", "Noto Sans JP", sans-serif;
  font-weight: 600;
  letter-spacing: -0.01em;
  font-size: 40px;
  line-height: 1.2;
}
body.sub-layout .big30 em {
  font-style: normal;
  font-family: Inter, sans-serif;
  color: var(--hi);
}

body.sub-layout :is(.h h2, .hin .copy, .prose h2, .prose h3, section.blk > h2, section.blk > h3) {
  display: block !important;
  width: fit-content;
  max-width: 100%;
  border-left: 4px solid var(--sub-accent) !important;
  border-bottom: 2px solid var(--sub-accent) !important;
  padding: 0.06em 0.15em 0.28em 0.5em !important;
  margin-top: 0.4em !important;
  margin-bottom: 0.6em !important;
  text-wrap: balance;
}
body.sub-layout :is(.h h2, .prose h2, .prose h3, section.blk > h2, section.blk > h3):first-child {
  margin-top: 0 !important;
}

body.sub-layout :is(.hin .sub, .prose p, .prose li, .intro, .ans, .card p, dl.info dd, details p, .lst li, .h p, section.blk p:not(.big30):not(.nm):not(.ct):not(.en), blockquote, blockquote div) {
  line-height: 2 !important;
  color: #374151 !important;
}

body.sub-layout :is(.hin, .hero > .acc, section.blk:not(:has(.cards)), .rel) {
  max-width: 800px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
body.sub-layout section.blk:has(.cards) :is(.h p, .prose, .prose p) { max-width: 800px; }

@media (min-width: 900px) {
  body.sub-layout section.blk.wide:not(:has(.cards)),
  body.sub-layout .wide:not(section):not(:has(.cards)) {
    display: grid;
    grid-template-columns: max-content minmax(0, 800px);
    gap: 28px 40px;
    align-items: start;
    max-width: min(1120px, 100%) !important;
  }
  body.sub-layout section.blk.wide .h,
  body.sub-layout .wide .h { margin: 0; }
  body.sub-layout section.blk.wide .h p { max-width: 16em; }
  body.sub-layout section.blk.wide > :not(.h) { max-width: 800px; }
}
