@charset "UTF-8";
/* ==========================================================================
   株式会社えんじゅ 静的サイト 共通スタイル
   - HTML5 / CSS3（Baseline 2025 の範囲：カスタムプロパティ・CSS Nesting・
     :has()・:focus-within・aspect-ratio・inset・gap 等）
   - 元サイト（WordPress + Elementor）の見た目を再現
   ========================================================================== */

:root {
  --c-primary: #00B04C;
  --c-secondary: #28A353;
  --c-text: #58595B;
  --c-accent: #F47526;
  --c-copy: #D1E7C3;
  /* 元サイトは Adobe Fonts（kinuta-maruminkatura-stdn / maru-maru-gothic-bsr-stdn）。
     Adobe Fonts のキットはドメイン制限があるため、読めない環境では Google Fonts の近い書体へフォールバック */
  --f-main: kinuta-maruminkatura-stdn, "Kiwi Maru", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --f-menu: maru-maru-gothic-bsr-stdn, "Zen Maru Gothic", "Hiragino Maru Gothic ProN", sans-serif;
  --f-sans: "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --container: 700px;
  --gutter: 10px;
}

/* ---------- Reset（A Modern CSS Reset 相当） ---------- */
*, *::before, *::after { box-sizing: border-box; }

html:focus-within { scroll-behavior: smooth; }
body, h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
img, picture, svg { max-width: 100%; display: block; }
img { height: auto; }
input, button, textarea, select { font: inherit; }
a { color: inherit; text-decoration: none; }

body {
  min-height: 100vh;
  padding: 0 1em;
  background: #fff url("../uploads/2021/10/BG_IMAGE.png") center center / 200px auto repeat;
  color: var(--c-text);
  font-family: var(--f-main);
  font-size: 1rem;
  font-weight: 400;
  line-height: 2.5;
  overflow-x: clip;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 1000;
  background: #fff; color: #0073aa; padding: .75em 1.5em; line-height: 1.5;
  &:focus { left: 0; }
}

/* ---------- 汎用 ---------- */
.wrap {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding: var(--gutter);
}
.bleed { margin-inline: -1em; } /* body の左右 padding を打ち消して全幅に */

.section { margin-block: 6em; }
/* 下層ページの本文カラムは元サイト同様に内側余白なし（幅 700px） */
.page main > .wrap { padding: 0; }

/* 見出し（左に緑の縦線） */
.sec-title {
  margin: 0 0 2rem;
  padding-left: 1rem;
  border-left: 5px solid var(--c-secondary);
  color: var(--c-secondary);
  font-size: 1.5em;
  font-weight: 400;
  line-height: 1.5;
  &.is-lg { font-size: 2em; }
}

/* 本文 */
.text {
  text-align: justify;
  & p { margin: 0; }
  & u {
    text-decoration: none;
    border-bottom: .2em solid var(--c-primary);
    padding-bottom: 4px;
  }
  & ol { margin: 0 0 .9rem; padding-left: 2.5em; }
  & a { color: var(--c-primary); }
}
.text-sans { font-family: var(--f-sans); }

.wbr { display: inline; }

/* ---------- アニメーション（Elementor の fadeInUp 等を再現） ---------- */
@keyframes fadeInUp   { from { opacity: 0; transform: translate3d(0, 100%, 0); } to { opacity: 1; transform: none; } }
@keyframes fadeInDown { from { opacity: 0; transform: translate3d(0, -100%, 0); } to { opacity: 1; transform: none; } }
@keyframes fadeIn     { from { opacity: 0; } to { opacity: 1; } }
@keyframes zoomIn     { from { opacity: 0; transform: scale3d(.3, .3, .3); } 50% { opacity: 1; } }

/* JS が有効なときだけ初期状態で隠す（JS 無効でも内容は表示される） */
.js [data-anim]:not(.is-inview) { opacity: 0; }
.js [data-anim].is-inview {
  animation-duration: 1.25s;
  animation-fill-mode: both;
  animation-delay: var(--delay, 0s);
}
.js [data-anim="fade-up"].is-inview   { animation-name: fadeInUp; }
.js [data-anim="fade-down"].is-inview { animation-name: fadeInDown; }
.js [data-anim="fade-in"].is-inview   { animation-name: fadeIn; }
.js [data-anim="fade-in-slow"].is-inview { animation-name: fadeIn; animation-duration: 2s; }

@media (prefers-reduced-motion: reduce) {
  html:focus-within { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}

/* ==========================================================================
   ヘッダー（下層ページ）
   ========================================================================== */
.site-header {
  position: relative;
  z-index: 100;
  margin: 2em 0;
  padding: 0 2em;
}
.site-header__inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
}
.site-logo img { width: 71px; max-width: 200px; }

.gnav {
  font-family: var(--f-menu);
  line-height: 1.25;
  & ul { list-style: none; margin: 0; padding: 0; }
  & a { display: block; }
}
.gnav__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  & > li { position: relative; }
  & > li > a,
  & > li > .gnav__parent > a {
    padding: 15px;
    color: var(--c-text);
    transition: color .2s;
  }
  & > li > a:hover,
  & > li > .gnav__parent > a:hover,
  & > li.is-current > a,
  & > li.is-current > .gnav__parent > a,
  & > li.is-ancestor > .gnav__parent > a { color: var(--c-primary); }
  /* 表示中ページに下線 */
  & > li.is-current,
  & > li.is-ancestor { border-bottom: .2em solid var(--c-primary); }
}
.gnav__parent {
  display: flex;
  align-items: center;
  & > a { padding-right: 4px !important; }
}
.gnav__subtoggle {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  margin-right: 11px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--c-text);
  cursor: pointer;
  & svg { width: 10px; height: 10px; fill: currentColor; transition: transform .2s; }
  .is-ancestor & , .is-current & , .gnav__parent:hover & { color: var(--c-primary); }
}
.gnav__sub {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 10;
  width: 220px;
  background: #fff;
  border-radius: 5px;
  box-shadow: 0 4px 10px -2px rgba(0, 0, 0, .1);
  overflow: hidden;
  visibility: hidden;
  opacity: 0;
  transition: opacity .2s, visibility .2s;
  & a {
    padding: 15px 15px 15px 35px;
    color: var(--c-primary);
    &:hover, &[aria-current="page"] { background: var(--c-primary); color: #fff; }
  }
}
.gnav__list > li:hover > .gnav__sub,
.gnav__list > li:focus-within > .gnav__sub,
.gnav__list > li.is-sub-open > .gnav__sub { visibility: visible; opacity: 1; }

.gnav__toggle {
  display: none;
  width: 40px;
  height: 40px;
  margin-left: auto;
  padding: 5px;
  border: 0;
  background: none;
  color: var(--c-primary);
  cursor: pointer;
  & svg { width: 30px; height: 30px; fill: currentColor; }
  & .icon-close { display: none; }
}

@media (max-width: 1024px) {
  .gnav__list > li > a,
  .gnav__list > li > .gnav__parent > a,
  .gnav__sub a { font-size: 1.2em; }
}

@media (max-width: 767px) {
  .site-logo img { width: 60px; }
  .gnav__toggle { display: block; position: relative; z-index: 3; }
  .gnav__panel {
    display: none;
    position: absolute;
    top: 100%;
    left: calc(50% - 50vw);
    z-index: 2;
    width: 100vw;
    background: #fff;
    border-radius: 5px;
    overflow: hidden;
  }
  .gnav__list {
    display: block;
    & > li { border-bottom: 1px solid #fff; }
    & > li.is-current, & > li.is-ancestor { border-bottom: 1px solid #fff; }
    & > li > a,
    & > li > .gnav__parent > a { padding: 15px; color: var(--c-primary); }
    & > li.is-current > a { background: var(--c-primary); color: #fff; }
    & > li > a:hover, & > li > .gnav__parent > a:hover { background: var(--c-primary); color: #fff; }
  }
  .gnav__parent {
    justify-content: space-between;
    & > a { flex: 1; }
  }
  .gnav__subtoggle {
    width: 44px; height: 44px; margin: 0;
    color: var(--c-primary) !important;
    & svg { width: 12px; height: 12px; }
  }
  .gnav__sub {
    position: static;
    width: auto;
    display: none;
    visibility: visible;
    opacity: 1;
    border-radius: 0;
    box-shadow: none;
  }
  .gnav__list > li:hover > .gnav__sub,
  .gnav__list > li:focus-within > .gnav__sub { display: none; }
  .gnav__list > li.is-sub-open > .gnav__sub { display: block; }
  .gnav__list > li.is-sub-open .gnav__subtoggle svg { transform: rotate(180deg); }

  .site-header.is-open {
    & .gnav__panel { display: block; }
    & .gnav__toggle .icon-open { display: none; }
    & .gnav__toggle .icon-close { display: block; }
    &::before {
      content: "";
      position: fixed;
      inset: 0;
      z-index: 1;
      background: #00000082;
    }
  }
  /* JS が無効な場合はメニューを常時表示 */
  html:not(.js) .gnav__panel { display: block; position: static; width: auto; }
  html:not(.js) .gnav__toggle { display: none; }
}

/* ==========================================================================
   下層ページ共通
   ========================================================================== */
.header-spacer { height: 50px; }

.page-head__box {
  padding: 3em 1em;
  border: 2px solid var(--c-primary);
  background: #fff;
  text-align: center;
  & h1 {
    margin: 0 0 1rem;
    color: var(--c-primary);
    font-size: 2em;
    font-weight: 400;
    line-height: 1;
  }
  & p { line-height: 1.5; }
}

/* 画像 */
.img-cover { width: 100%; object-fit: cover; object-position: center; }
.img-h300 { height: 300px; }
.img-h200 { height: 200px; }
.mt-2 { margin-top: 2em; }

.grid-2, .grid-3 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 2em;
  & > * { padding: 10px; }
}
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* カード（トップ「ページ紹介」・実績「主な製品」） */
.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1em;
  &.is-3col { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.card {
  display: block;
  padding: 1em;
  border: 2px solid var(--c-primary);
  border-radius: 5px;
  background: #fff;
  text-align: justify;
  transition: opacity .3s;
  &:hover { opacity: .8; }
  & img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
  &.is-product img { aspect-ratio: auto; height: 200px; object-fit: contain; }
  & h3 {
    margin: 1em 0 .5em;
    color: var(--c-primary);
    font-size: 1.2em;
    font-weight: 400;
    line-height: 1;
  }
  & p { font-size: .8em; line-height: 2; }
}

/* 写真キャプション */
.photo figcaption {
  margin-top: .5em;
  font-family: var(--f-sans);
  font-size: .9em;
  font-style: italic;
  line-height: 1.5;
  text-align: center;
}

/* 商品リーフレット */
.leaflet {
  display: block;
  margin-bottom: 1em;
  cursor: zoom-in;
}

/* 会社概要：定義リスト */
.meta-list {
  & > div {
    display: grid;
    grid-template-columns: 5em 1fr;
    gap: 0 1.5em;
    padding: 1em;
    line-height: 1.5;
  }
  & > div:nth-child(odd) { background: #F2F2F2; }
  & dt { color: var(--c-secondary); }
  & dd { margin: 0; }
  & a { text-decoration: underline; }
}

/* 代表あいさつ */
.greeting {
  display: grid;
  grid-template-columns: 40% 60%;
  & > div { padding: 10px; }
  & .greeting__img { margin-bottom: 1em; }
  & .greeting__role { margin-bottom: .5em; line-height: 1.5; }
  & .greeting__name { font-size: 2em; font-weight: 400; line-height: 1; }
}

/* アクセス */
.map {
  display: block;
  width: 100%;
  height: 400px;
  border: 0;
}
.access-text { margin-top: 1em; line-height: 2; }

/* お問い合わせ */
.tel-link {
  display: inline-flex;
  align-items: center;
  gap: .3em;
  font-size: 1.1em;
  line-height: 1;
  text-decoration: underline;
  & svg { width: 1.5em; height: 1.5em; fill: var(--c-secondary); }
  & small { font-size: .8em; }
}
.contact-form {
  margin-top: 1em;
  line-height: 1.5;
  & .field { margin-bottom: 1.2em; }
  & label, & .label {
    display: block;
    margin: .8em 0 .5em;
    color: var(--c-secondary);
    font-size: 1.1em;
    font-weight: 700;
  }
  & .req {
    color: var(--c-accent);
    font-size: .8rem;
    font-weight: 400;
  }
  & input[type="text"], & input[type="email"], & input[type="tel"], & textarea {
    display: block;
    width: 100%;
    padding: .4em 1em;
    border: 1.5px solid green;
    border-radius: 2px;
    background: #fff;
    color: #333;
    font-family: var(--f-sans);
  }
  & textarea { min-height: 11em; resize: vertical; }
  & .email-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1em;
    & label.sub {
      margin: .2em 0 0;
      color: var(--c-text);
      font-size: .7em;
      font-weight: 400;
    }
  }
  & .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
  & .actions { margin-top: 3em; }
}
.send_btn {
  padding: .5em 2em;
  border: none;
  border-radius: 5px;
  background: var(--c-secondary);
  color: #fff;
  font-family: var(--f-sans);
  line-height: 2;
  cursor: pointer;
  &:hover, &:focus-visible { background: var(--c-primary); }
}
.privacy-note { margin-top: 1em; font-family: var(--f-sans); text-align: justify; & a { color: var(--c-primary); text-decoration: underline; } }
.form-result {
  padding: 1.5em;
  border: 2px solid var(--c-primary);
  border-radius: 5px;
  background: #fff;
  line-height: 2;
  &.is-error { border-color: var(--c-accent); }
  & ul { margin: .5em 0; padding-left: 1.5em; color: var(--c-accent); }
  & .back { margin-top: 1em; & a { color: var(--c-primary); text-decoration: underline; } }
}

/* ==========================================================================
   フッター（下層ページ）
   ========================================================================== */
.footer-spacer { height: 50px; }
.site-footer {
  position: relative;
  margin-inline: -1em;
  background: url("../uploads/2021/10/footer.png") center bottom / 200px auto repeat-x;
}
.site-footer__inner { padding: var(--gutter); text-align: center; }
.footer-catch {
  position: absolute;
  bottom: 50%;
  left: 0;
  width: 100%;
  & .wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 0;
  }
  & p {
    padding: 10px;
    color: var(--c-primary);
    line-height: 1;
  }
  & p:first-child { text-align: start; }
  & p:last-child { text-align: end; }
}
.footer-tree {
  position: relative;
  height: 250px;
  width: auto;
  margin: 0 auto;
  object-fit: contain;
}
.copyright {
  position: absolute;
  right: 15px;
  bottom: 23px;
  color: var(--c-copy);
  font-family: var(--f-main);
  font-size: .5em;
  line-height: 1;
}

/* ページトップへ（葉っぱ） */
.to-top {
  position: fixed;
  right: 40px;
  bottom: 34px;
  z-index: 100;
  & img {
    width: 100px;
    opacity: .3;
    transition: opacity .2s, transform .3s;
  }
  &:hover img, &:focus-visible img { opacity: 1; transform: translateY(-8px); }
}

@media (max-width: 1024px) {
  .footer-catch p:first-child { padding-left: 1em; }
  .footer-catch p:last-child { padding-right: 1em; }
}

@media (max-width: 767px) {
  .page-head { margin-block: -3em; }
  .page-head__box { padding: 2em 1em; }
  .wbr { display: inline-block; }
  .greeting, .grid-2, .grid-3, .cards, .cards.is-3col { grid-template-columns: minmax(0, 1fr); }
  .contact-form .email-pair { grid-template-columns: 1fr; gap: 0; }
  .footer-spacer { height: 16px; }
  .footer-catch {
    position: relative;
    bottom: auto;
    left: auto;
    margin-bottom: 2em;
    & .wrap { grid-template-columns: 1fr; }
  }
  .to-top { right: 10px; bottom: 10px; }
}

/* ==========================================================================
   トップページ
   ========================================================================== */
.home {
  /* ヒーロー */
  & .hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 100vh;
    margin-inline: -1em;
  }
  & .hero__cols {
    display: flex;
    width: 100%;
  }
  & .hero__spacer { width: 23.642%; }
  & .hero__title {
    width: 25.69%;
    padding: 10px;
  }
  & .hero__logo img { width: 100%; max-width: 100px; }
  & .hero__catch {
    margin-top: 1em;
    color: var(--c-text);
    font-size: 1.2em;
    font-weight: 400;
    line-height: 2;
  }
  & .hero__tree-col { width: 50%; }

  /* 固定表示の木 */
  & .tree {
    position: fixed;
    bottom: 0;
    left: calc(49.332% + 10px);
    z-index: 10;
    width: calc(50.668% - 10px);
    padding-top: 2em;
    pointer-events: none;
    & img {
      width: 80%;
      margin-inline: auto;
      object-position: 50% 100%;
      filter: drop-shadow(0 3px 6px #00000030);
    }
  }

  /* 理念（緑のグラデーション） */
  & .mission {
    margin-inline: -1em;
    padding: 8em 0;
    background-image: linear-gradient(200deg, #3E8B59 0%, var(--c-primary) 100%);
    color: #fff;
  }
  & .mission .wrap,
  & .origin .wrap,
  & .home-footer .wrap { display: flex; padding: 0; }
  & .mission__col { width: 50%; padding: 10px; }
  & .mission h2 {
    margin-left: -1rem;
    color: #fff;
    font-size: 1.3em;
    font-weight: 400;
    line-height: 1.5;
  }
  & .mission p {
    margin-top: 1em;
    line-height: 2;
    text-align: justify;
  }

  /* ページ紹介 */
  & .pages {
    position: relative;
    z-index: 20;
    margin-inline: -1em;
    padding: 4em 0;
    background: #fff;
    & .cards { gap: 1em; }
    & .cards .card + .card { margin: 0; }
  }

  /* えんじゅの由来 */
  & .origin {
    display: flex;
    align-items: center;
    min-height: 100vh;
    padding: 4em 0;
    & .origin__col { width: 50%; padding: 10px; }
    & .text { line-height: 2; }
  }

  /* フッター（トップ専用） */
  & .home-footer {
    display: flex;
    align-items: center;
    min-height: 100vh;
    margin-inline: -1em;
    padding: 4em 1em;
    background: url("../uploads/2021/10/footer.png") center bottom / 300px auto repeat-x;
    & .home-footer__col { width: 50%; padding: 10px; }
    & .home-footer__logo { padding-bottom: 2em; & img { width: 100%; max-width: 100px; } }
  }
  & .address {
    list-style: none;
    margin: 0;
    padding: 0;
    line-height: 1.5;
    & li { margin-bottom: .5em; }
    & a {
      display: flex;
      align-items: center;
      color: var(--c-text);
      transition: color .3s;
      &:hover { color: var(--c-primary); }
    }
    & svg {
      flex: none;
      width: 18px;
      height: 18px;
      margin: 0 calc(18px * .125) 0 0;
      fill: var(--c-primary);
    }
    & .address__text { padding-left: 5px; }
  }
  & .copyright {
    position: fixed;
    right: 29px;
    bottom: 20px;
    z-index: 1;
    font-size: .5em;
  }
}

@media (max-width: 1024px) and (min-width: 768px) {
  .home .hero__title { width: 50%; }
  .home .hero__tree-col { width: 30%; }
  .home .hero__spacer { width: 20%; }
}
@media (max-width: 1024px) {
  .home .tree img { width: 30%; }
}

@media (max-width: 767px) {
  .home {
    & .hero { height: 100vh; }
    & .hero__cols { display: block; }
    & .hero__spacer, & .hero__tree-col { display: contents; }
    & .hero__title {
      position: relative;
      z-index: 20;
      width: auto;
      padding: 0 1em;
    }
    & .hero__box {
      width: fit-content;
      margin: auto;
      padding: 8em 1em;
      border: 1px solid var(--c-primary);
      background: #fff;
      text-align: center;
    }
    & .hero__logo img { margin-inline: auto; }
    & .hero__catch {
      display: inline-flex;
      flex-direction: column;
      font-size: 1em;
      line-height: 2.1;
      & br { display: none; }
    }
    & .tree {
      left: 0;
      width: 100%;
      & img { width: 90%; margin-inline: auto; opacity: .2; }
    }
    & .mission__col, & .origin .origin__col, & .home-footer .home-footer__col { width: 100%; }
    & .mission .wrap, & .origin .wrap, & .home-footer .wrap { display: block; }
    & .home-footer { padding: 4em 1em; }
    & .origin, & .home-footer { min-height: 0; }
  }
  .js .home [data-anim-sp="zoom-in"].is-inview { animation-name: zoomIn; }
}

/* ---------- ライトボックス（<dialog>） ---------- */
.lightbox {
  max-width: 95vw;
  max-height: 95vh;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
  &::backdrop { background: rgba(0, 0, 0, .85); }
  & img { max-width: 95vw; max-height: 95vh; width: auto; object-fit: contain; }
}
.lightbox__close {
  position: fixed;
  top: 10px;
  right: 15px;
  z-index: 1;
  width: 44px;
  height: 44px;
  border: 0;
  background: none;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

.mt-1 { margin-top: 1em; }
