/* =========================================
 Reset
========================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Montserrat', 'Hiragino Sans', 'ヒラギノ角ゴシック', 'Yu Gothic', 'メイリオ', sans-serif;
  background: #f7f9fb;
  color: #333;
  line-height: 1.6;
}

.container {
  width: 90%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 60px 0;
}

html, body { overflow-x: hidden; }

/* =========================================
 header
========================================= */

/* ===============================
   固定ヘッダー高の基準（PC/スマホ）
  =============================== */
:root{
  --header-login-h: 36px; /* 上部の緑帯 */
  --header-nav-h:   60px; /* ロゴ＋ナビ行 */
  --header-total: calc(var(--header-login-h) + var(--header-nav-h));
}

@media (max-width: 768px){
  :root{
    --header-login-h: 34px;
    --header-nav-h:   56px;
  }
}

/* ===============================
   Header（固定配置＋高さ固定）
  =============================== */
.header{
  position: fixed;
  top: 0; left: 0; width: 100%;
  z-index: 999;
  background:#fff;
  box-shadow: 0 2px 5px rgba(0,0,0,.05);
}

.header-login-bar{
  min-height: var(--header-login-h);
  display: flex;
  align-items: center;
  padding: 0 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.login-bar-inner{ width: 100%; display:flex; justify-content:space-between; gap: 12px; }
.login-bar-left{ overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.login-bar-right{ display:flex; align-items:center; gap:8px; }
.username-badge{ max-width: 40vw; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.login-btn{ min-width: 96px; text-align:center; }


.logo-nav{
  min-height: var(--header-nav-h);
  display:flex; justify-content:space-between; align-items:center;
  padding: 0.6rem 1.5rem;
  width: 100%;
}

.logo img{ 
  height: 60px; 
  width:auto; 
  display:block; 
  margin-left:20px; 
}

@media (max-width: 768px){
  .login-bar-left{ display:none; }
  .logo-nav{ padding: 0.6rem 1rem; }
  .logo img{ height: 48px; margin-left:20px; }
}


/* ===============================
  Heroセクション
=============================== */
.hero{
  position: relative;
  margin-top: 0 !important;
  min-height: calc(100vh - var(--header-total));
  min-height: calc(100svh - var(--header-total));
  padding-top: var(--header-total);
  overflow: hidden;
  display:flex; align-items:center; justify-content:center; flex-direction:column;
}

/* ===============================
  追加の小さな堅牢化
=============================== */

.header, .hero, .nav, .login-bar-inner{
  word-break: keep-all;
  text-wrap: balance;
}

.header .container {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

.header .container {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

/* =========================================
 ナビゲーション
========================================= */

.nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 70%;
  height: 100vh;
  background: #fff;
  z-index: 1000;
  flex-direction: column;
  padding: 5rem 1rem 1rem;
  transition: right 0.3s ease-in-out;
  display: flex;
  margin-right:50px;
  display: flex;
  gap: 30px;
  align-items: center;
}

.nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.nav a {
  text-decoration: none;
  color: #222;
  font-weight: 600;
  font-size: 0.95rem;
  text-align: center;
  display: block;
  line-height: 1.2;
  padding: 6px 10px;
  transition: color 0.2s;
}

.nav a span {
  display: block;
  font-size: 0.7rem;
  color: #666;
  font-weight: 400;
}


.nav.active {
  right: 0;
}

.nav{
  right: -120% !important;      
  pointer-events: none;       
  z-index: 1000;
}
.nav.active{
  right: 0 !important;
  pointer-events: auto;
}

.header-login-bar{
  position: relative;
  z-index: 1100;              
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2000;
}

.site-main {
  padding-top: 96px; 
  position: relative;
  z-index: 1;
}

.nav {
  pointer-events: none;
}

.nav.active {
  pointer-events: auto;
}

.logo-nav {
  display: flex;
  justify-content: space-between; 
  align-items: center;  
  padding: 0.6rem 1.5rem;
  width: 100%;
  min-height: 60px; 
  position: relative;
}

.logo img {
  height: 60px; 
  width: auto;
  display: block;
  margin-left:20px;
}

/* ---- レスポンシブ対応 ---- */
@media (max-width: 768px) {

  .login-bar-inner {
    justify-content: flex-end;
  }

  .logo-nav {
    padding: 0.6rem 1rem;
  }

  .hamburger {
    display: flex;
  }

  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    align-items: center;
    display: none !important; 
    padding: 25px 0 20px 0;
    z-index: 1000;
    border-top: 1px solid #eee;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    transition: all 0.5s cubic-bezier(0.77, 0, 0.175, 1);
  }

  .nav.active {
    display: flex !important;  
    animation: fadein .5s;
  }

  .nav ul {
    flex-direction: column;
    gap: 18px;
    width: 100%;
    align-items: center;
  }

  .nav li {
    width: 100%;
    text-align: center;
  }

  .nav li a {
    font-size: 1.1rem;
    padding: 12px 0;
    width: 100%;
    display: block;
  }

}

@keyframes fadein {
  0%   { opacity: 0; transform: translateY(-10px);}
  100% { opacity: 1; transform: translateY(0);}
}

/* =========================================
 ハンバーガーメニュー
========================================= */

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 38px;
  height: 38px;
  cursor: pointer;
  z-index: 1001;
  position: relative;
  transition: filter 0.2s;
}

.hamburger span {
  display: block;
  width: 28px;
  height: 4px;
  background: #333;
  transition: all 0.5s cubic-bezier(0.77, 0, 0.175, 1);
  border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(10px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0.6);
  transition-delay: 0.1s;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-10px) rotate(-45deg);
}

/* ---- レスポンシブ対応 ---- */
@media (max-width: 768px) {
  .logo-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.6rem 1rem;
    min-height: 60px;
  }
  .hamburger {
    display: flex;
  }
}

/* =========================================
 ログインバー
========================================= */
.login-status {
  position: absolute;
  top: 0;
  right: 0;
  padding: 5px 10px;
  font-size: 14px;
  z-index: 1000;
  background: #fff;
  border-radius: 4px;
}

.header-login-bar {
  background-color: #009966;
  color: white;
  padding: 5px 20px;
  font-size: 14px;
}

.login-bar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.login-bar-left {
  font-weight: bold;
  flex: 1;
}

.login-bar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.login-btn {
  background-color: white;
  color: #009966;
  padding: 6px 12px;
  border-radius: 20px;
  text-decoration: none;
  font-weight: bold;
  font-size: 13px;
  display: inline-block;
  line-height: 1.4;
  vertical-align: middle;
  transition: background 0.3s;
}


.login-btn:hover {
  background-color: #f0f0f0;
}

.login-btn.logout {
  background-color: #f44336;
  color: white;
}

.login-btn.logout:hover {
  background-color: #d32f2f;
}

.username-badge {
  background-color: rgba(255, 255, 255, 0.2);
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: bold;
  color: #fff;
}

#edit-profile-form input[type="text"],
#edit-profile-form input[type="email"],
#edit-profile-form textarea {
  width: 100%;
  padding: 8px 12px;
  margin: 8px 0 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

#edit-profile-form input[type="submit"] {
  background-color: #009966;
  color: white;
  border: none;
  padding: 8px 20px;
  border-radius: 20px;
  cursor: pointer;
}

#edit-profile-form input[type="submit"]:hover {
  background-color: #007d55;
}

/* =========================================
 共通
========================================= */
section h2 {
  font-size: 2rem;
  color: #002b7f;
  margin-bottom: 0.3rem;
  text-align: center;
  line-height: 1.4;
}

.section-sub {
  text-align: center;
  font-weight: bold;
  color: #333;
  margin: 1rem 0;
  font-size: 1rem;
  line-height: 1.4;
  display: inline-block;
  position: relative;
}

.section-sub::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background-color: #002b7f;
  margin: 8px auto 0 auto;
}

.container {
  text-align: center;
}


/* =========================
  HEROセクション
========================= */
.hero {
  position: relative;
  margin-top: 60px;              
  height: calc(100vh - 60px);   
  min-height: 540px;             
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1;
}

/* スライダー */
.hero-slider {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-slider .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  animation: fadeSlide 20s infinite;
  transition: opacity 1s ease-in-out;
}

.hero-slider .slide:nth-child(1) { animation-delay: 0s; }
.hero-slider .slide:nth-child(2) { animation-delay: 5s; }
.hero-slider .slide:nth-child(3) { animation-delay: 10s; }
.hero-slider .slide:nth-child(4) { animation-delay: 15s; }

@keyframes fadeSlide {
  0%   { opacity: 0; }
  5%   { opacity: 1; }
  25%  { opacity: 1; }
  30%  { opacity: 0; }
  100% { opacity: 0; }
}

/* テキストブロック */
.hero-text {
  position: relative;
  z-index: 2;
  color: #fff;
  text-align: center;
  padding: 0 1rem 0.5rem;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  max-width: 1000px;
  margin: 0 auto;
}

/* ─ 改行制御の基本 ─ */
.pc-br { display: inline; }            
.nbsp::after { content: "\00A0"; }     
.hero-text h2, .hero-text p {
  overflow-wrap: anywhere;
  text-wrap: balance;                    
}

/* 見出し */
.hero-text h2 {
  font-size: clamp(1.6rem, 3.2vw + 0.8rem, 2.8rem);
  margin-bottom: 0.6rem;
  font-weight: 700;
  color: #fff;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6);
  line-height: 1.35;
}

/* サブコピー */
.hero-text p {
  font-size: clamp(0.95rem, 1.2vw + 0.6rem, 1.15rem);
  line-height: 1.8;
  margin-bottom: 0.8rem;
}

/* ボタンエリア */
.hero-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ボタン */
.hero-buttons .btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: #00b88a;
  color: #fff;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  line-height: 1.3;
  transition: background 0.3s;
  text-align: center;
  min-width: 160px;
}

.hero-buttons .btn span {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
}

.hero-buttons .btn:hover { 
  background: #009f77;
}

/* =========================
  HEROセクション_レスポンシブ対応
========================= */

/* タブレット */
@media (max-width: 1024px) {
  .hero { min-height: 520px; }
}

/* スマホ（768px以下） */
@media (max-width: 768px) {
  .hero {
    margin-top: 0 !important;
    height: 100vh !important;
    height: 100svh !important;
    min-height: 100vh !important;
    min-height: 100svh !important;
  }

  .hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
  }

  .hero-slider .slide {
    background-size: cover;
    background-repeat: no-repeat;
  }

  .pc-br { display: none; }

  .hero-text {
    position: relative;
    z-index: 2;
  }

  .hero-text h2, 
  .hero-text p {
    word-break: keep-all;     
  }

  .hero-buttons {
    gap: 0.8rem;
  }

  .hero-buttons .btn {
    min-width: 140px;
    padding: 0.65rem 1.2rem;
  }
}

/* 小型端末 */
@media (max-width: 420px) {
  .hero-text p { 
    line-height: 1.7; 
    font-size: 0.9rem;
  }

  .hero-buttons .btn {
    min-width: 120px;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
  }
}

@media (min-width: 769px) {
  .hero{
    height: calc(100dvh + 1px) !important;
    height: calc(100svh + 1px) !important;
    height: calc(100vh  + 1px) !important;

    min-height: 0 !important;
    margin-top: calc(-1 * var(--header-total)) !important;
    padding-top: var(--header-total) !important;
    overflow: hidden;
    background-color: #000;
  }

  .hero .container{ padding: 0 !important; margin: 0 !important; }
}

/* =========================================================
  Awardsセクション
========================================================= */

.awards-2025{
  padding: clamp(36px, 6vw, 96px) 0;
  background: transparent;
}

.awards-2025__grid,
.awards-2025__list{
  max-width: min(1180px, 92vw);
  margin-inline: auto;
  display: flex;
  gap: clamp(20px, 2.8vw, 32px);
  justify-content: center;
  align-items: stretch;
  flex-wrap: nowrap;
}
.awards-2025__list{ list-style: none; margin: 0; padding: 0; }
.awards-2025__list > .awards-2025__item{ flex: 1 1 32%; min-width: 300px; }

.awards-2025__item{
  --wreathW: clamp(120px, 18vw, 170px);
  --gap:     clamp(12px, 2.2vw, 22px);

  flex: 1 1 32%;
  min-width: 300px;

  position: relative;
  display: grid;
  grid-template-columns: minmax(0, var(--wreathW)) 1fr minmax(0, var(--wreathW));
  grid-template-areas: "left center right";
  column-gap: var(--gap);
  align-items: center;
  justify-items: center;

  background: #EAFAF1;
  border-radius: 20px;
  padding: clamp(14px, 1.6vw, 18px);

  box-shadow:
    0 16px 42px rgba(0,0,0,.18),
    inset 0 1px 0 rgba(255,255,255,.18);
  overflow: hidden;
  isolation: isolate;

  transform: translateY(0);
  transition: transform .3s ease, box-shadow .3s ease;
}
.awards-2025__item:hover{
  transform: translateY(-4px);
  box-shadow:
    0 4px 10px rgba(0,0,0,.10),
    inset 0 1px 0 rgba(255,255,255,.22);
}

.awards-2025__item::before{
  content:"";
  position:absolute; inset:0;
  padding: 1.6px; border-radius: inherit;
  background: linear-gradient(135deg,
    #ffda69 0%, #ffc444 20%, #f5ad1e 45%, #d98f0f 65%, #b37209 82%, #8d5706 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events:none;
}

.awards-2025__item::after{
  content:"";
  position:absolute; inset:-10%;
  background:
    radial-gradient(80% 60% at 50% 0%, rgba(255,204,80,.18), transparent 60%),
    radial-gradient(70% 60% at 50% 100%, rgba(255,204,80,.10), transparent 70%),
    radial-gradient(40% 40% at 20% 20%, rgba(255,255,255,.22), transparent 60%),
    radial-gradient(40% 40% at 80% 80%, rgba(255,255,255,.12), transparent 60%),
    radial-gradient(2px 2px at 10% 30%, rgba(255,220,140,.16) 40%, transparent 41%),
    radial-gradient(2px 2px at 80% 70%, rgba(255,220,140,.16) 40%, transparent 41%),
    radial-gradient(2px 2px at 35% 80%, rgba(255,220,140,.12) 40%, transparent 41%),
    radial-gradient(2px 2px at 65% 25%, rgba(255,220,140,.14) 40%, transparent 41%);
  pointer-events:none;
}

.awards-2025__wreath{
  width: var(--wreathW);
  aspect-ratio: 1/1;
  display: grid;
  place-items: center;
  margin: 0; padding: 0; box-sizing: border-box;
  pointer-events: none;
}
.awards-2025__wreath > img,
.awards-2025__wreath > svg{
  width: 100%; height: 100%; object-fit: contain; display: block;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.35))
          drop-shadow(0 0 14px rgba(255,208,80,.24));
}
.awards-2025__wreath--left  { grid-area: left;  justify-self: end; }
.awards-2025__wreath--right { grid-area: right; justify-self: start; }

.awards-2025__copy{
  grid-area: center;
  width: max-content;
  max-width: 100%;
  margin-inline: auto;
  display: grid;
  place-items: center;
  gap: 10px;
  text-align: center;
  line-height: 1;
}
.awards-2025__copy i{
  font-size: clamp(18px, 1.8vw, 22px);
  color: #b37209;
  filter: drop-shadow(0 1px 0 rgba(255,255,255,.5));
}
.awards-2025__copy h3,
.awards-2025__copy p{
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0;
}

.awards-2025__copy h3{
  font-weight: 900;
  font-size: clamp(1.05rem, 0.6vw + 0.9rem, 1.2rem);
  letter-spacing: .04em;
  background-image: linear-gradient(170deg,
    #ffcd55 0%, #ffb935 22%, #f2a219 45%, #d1850d 68%, #a86b09 85%, #834f05 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: 0 1px 0 rgba(255,255,255,.28), 0 2px 12px rgba(209,133,13,.22);
  line-height: 1.18;
}

.awards-2025__copy p{
  font-weight: 800;
  font-size: clamp(0.9rem, 0.4vw + 0.85rem, 1rem);
  color: #111;
  line-height: 1.28;
}

/* ---------------------------------------------------------
  Awardsセクション_レスポンシブ
--------------------------------------------------------- */
@media (max-width: 1100px){
  .awards-2025__grid{ flex-wrap: wrap; }
  .awards-2025__item{ flex: 1 1 calc(50% - 20px); min-width: 320px; }
}

@media (max-width: 768px){
  .awards-2025__grid{ gap: clamp(14px, 3.6vw, 22px); }

  .awards-2025__item{
    display: block;
    position: relative;
    padding-block: clamp(14px, 5vw, 22px);
    padding-inline: clamp(90px, 30vw, 120px);
    min-height: clamp(110px, 30vw, 150px);
  }

  .awards-2025__wreath{
    position: absolute;
    top: 50%; transform: translateY(-50%);
    width: clamp(76px, 24vw, 110px);
    aspect-ratio: 1/1;
    display: grid; place-items: center;
  }
  .awards-2025__wreath--left{  left: clamp(12px, 3vw, 16px); }
  .awards-2025__wreath--right{ right: clamp(12px, 3vw, 16px); }

  .awards-2025__copy{
    position: relative;
    width: 100%;
    margin: 0 auto;
    text-align: center;
    display: grid; place-items: center;
    gap: 8px;
  }

  .awards-2025__copy h3{ font-size: 1.05rem; }
  .awards-2025__copy p { font-size: 0.9rem;  }
}

@media (max-width: 380px){
  .awards-2025__item{ padding-inline: 84px; }
  .awards-2025__wreath{ width: 74px; }
  .awards-2025__copy h3{ letter-spacing: .02em; }
}

/* =========================================
  Problems セクション
========================================= */

#problems {
  background-color: #fafafa;
  padding: 60px 0;
  border-top: 1px solid #ddd;
  border-bottom: 1px solid #ddd;
}

#problems .container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
  text-align: center; 
}

.problems-title {
  font-size: clamp(1.2rem, 1.2vw + 1rem, 1.6rem);
  font-weight: 700;
  text-align: center;
  color: #2e7d32;
  margin-bottom: 20px;
  line-height: 1.5;
  text-wrap: balance; 
}

.problems-list {
  display: inline-block; 
  text-align: left; 
  list-style-position: outside; 
  list-style-type: disc;
  padding-left: 1.5em; 
  margin: 0 auto 20px;
}

/* 各項目 */
.problems-list li {
  font-size: clamp(0.95rem, 0.4vw + 0.85rem, 1rem);
  line-height: 1.8;
  margin: 0 0 10px 0;
  color: #333;
}

/* 解決コピー */
.problems-solution {
  font-size: clamp(1.05rem, 0.6vw + 0.9rem, 1.2rem);
  font-weight: 700;
  text-align: center;
  color: #2e7d32;
}

/* ロゴ */
#problems .problems-logo {
  height: clamp(1.8em, 1.2vw + 1.6em, 3.2em);
  vertical-align: middle;
  margin-left: 6px;
}


/* =========================
  Problemsセクション_レスポンシブ
========================= */

/* --- スマホ調整 --- */
@media (max-width: 768px) {
  #problems { padding: 44px 0; }
  .problems-title { 
    margin-bottom: 16px; 
    font-size: 1.2rem; 
  }
  .problems-list { 
    width: 100%; 
    padding-left: 1.2em; 
  }
  .problems-list li { 
    font-size: 0.9rem; 
    line-height: 1.6; 
    margin-bottom: 8px; 
  }
  .problems-solution { font-size: 1rem; }
}

/* 小型端末（iPhone SEなど） */
@media (max-width: 420px) {
  #problems { padding: 36px 0; }
  .problems-list li { 
    font-size: 0.85rem; 
    line-height: 1.5;
  }
}

/* =========================================
  Aboutセクション
========================================= */

#about {
  background: #fff;
  padding: 60px 20px;
}

#about h2 {
  font-size: 2.2rem;            
  text-align: center;
  margin-bottom: 0.5rem;
  color: #003366;
  font-weight: bold;
}

.section-sub {
  text-align: center;
  font-size: 0.95rem;
  color: #777;
  margin-bottom: 1.2rem;
}

.section-desc {
  text-align: center;
  font-size: 1rem;
  color: #555;
  max-width: 740px;
  margin: 0 auto 2.5rem auto;
  line-height: 1.8;
}

.highlight-box {
  background: #eafaf1;
  color: #007c59;
  border: 2px dashed #00a676;
  border-radius: 10px;
  padding: 1.8rem 1.2rem;
  font-size: 1rem;
  text-align: center;
  position: relative;
  line-height: 1.8;
  max-width: 900px;
  margin: 0 auto;
}

.highlight-box::before {
  content: "更に！";
  position: absolute;
  top: -15px;
  left: 20px;
  background: #ffe600;
  padding: 0.3rem 0.8rem;
  font-weight: bold;
  color: #000;
  border-radius: 5px;
  font-size: 0.85rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* =========================================
  Aboutセクション_レスポンシブ
========================================= */
@media (max-width: 768px) {

  #about { padding: 44px 16px; }

  #about h2 {
    font-size: 1.6rem;        
    line-height: 1.3;
    text-wrap: balance;       
  }

  .section-sub {
    font-size: 0.9rem;
    margin-bottom: 1rem;
  }

  .section-desc {
    font-size: 0.9rem;         
    line-height: 1.6;           
    margin-bottom: 1.8rem;
    padding: 0 2px;             
    word-break: keep-all;      
    text-wrap: balance;      
  }

  .section-desc br,
  .highlight-box br { display: none; }

  .highlight-box {
    padding: 1.2rem;       
    font-size: 0.9rem;          
    line-height: 1.6;
    word-break: keep-all;
    text-wrap: balance;
  }

  .highlight-box::before {
    top: -12px;                
    left: 14px;
    font-size: 0.8rem;
    padding: 0.28rem 0.7rem;
  }
}

@media (max-width: 420px) {
  #about { padding: 36px 14px; }
  .section-desc { font-size: 0.88rem; line-height: 1.55; }
  .highlight-box { font-size: 0.88rem; line-height: 1.55; }
  .highlight-box::before { top: -10px; left: 12px; }
}


/* =========================================
  UNIQUE STRENGTHS セクション
========================================= */
#strengths {
  background: #f9f9f9;
  padding: 60px 0;
}

#strengths h2 {
  font-size: 2rem;            
  text-align: center;
  margin-bottom: 0.5rem;
  color: #003366;
}

#strengths .section-sub {
  text-align: center;
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 2rem;
}

/* ---- layout ---- */
.strengths-circle-container {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
}

/* ---- circle/card ---- */
.strength-circle {
  background: #fff;
  border-radius: 50%;
  width: 280px;
  height: 280px;
  padding: 2rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;  
  align-items: center;
  gap: 0.5rem;
  box-sizing: border-box;
  transition: transform 0.3s;
  min-width: 0;                             
  -webkit-text-size-adjust: 100%;          
}

.strength-circle:hover {
  transform: translateY(-5px);
}

.strength-circle .number {
  font-size: 1.8rem;
  color: #00a676;
  font-weight: bold;
  margin: 0;
}

.strength-circle h3,
.strength-title {
  font-size: 1.05rem;
  color: #222;
  font-weight: bold;
  line-height: 1.4;
  margin: 0;
  min-height: calc(1.4em * 2);  
  display: -webkit-box;        
  -webkit-box-orient: vertical; 
  -webkit-line-clamp: 2;      
  overflow: hidden;            
  white-space: normal;       
  overflow-wrap: anywhere;     
  word-break: normal;          
  line-break: strict;          
  text-wrap: balance;
}


.strength-title-inner{
  display: block;               
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
  line-break: strict;
}


.strength-circle h3::after,
.strength-title::after {
  content: "";
  display: block;
  width: 50px;
  height: 2px;
  background-color: #00a676;
  margin: 0.4rem auto 0;
}

.underline { display: none; }


.strength-circle p {
  font-size: 0.9rem;
  color: #555;
  line-height: 1.5;
  max-width: 220px;
  margin: 0;
  white-space: normal;         
  overflow-wrap: anywhere;      
  word-break: normal;        
  line-break: strict;           
  text-wrap: pretty;
}

.x-symbol {
  font-size: 2rem;
  color: #ccc;
  align-self: center;
}


/* =========================================
  UNIQUE STRENGTHSセクション_レスポンシブ
========================================= */
@media (max-width: 768px) {
  /* --- About --- */
  #about { padding: 40px 15px; }

  #about h2 {
    font-size: 1.6rem;          
    line-height: 1.3;
    text-wrap: balance;       
  }

  .section-sub {
    font-size: 0.85rem;
    margin-bottom: 1rem;
  }

  .section-desc {
    font-size: 0.9rem;   
    line-height: 1.6;
    margin-bottom: 1.8rem;
    word-break: keep-all;     
    text-wrap: balance;         
  }

  .section-desc br,
  .highlight-box br { display: none; }

  .highlight-box {
    padding: 1.2rem;
    font-size: 0.9rem;
    line-height: 1.6;
    word-break: keep-all;
    text-wrap: balance;
  }

  /* --- Strengths --- */
  .x-symbol { display: none; }

  .strength-circle {
    border-radius: 16px;       
    width: 100%;
    height: auto;
    padding: 1.2rem;
    align-items: center;
    justify-content: flex-start;
    gap: 0.4rem;
    -webkit-text-size-adjust: 100%;   
  }

  .strength-circle .number {
    font-size: 1.5rem;
  }

  .strength-circle h3,
  .strength-title {
    font-size: 0.95rem;       
    line-height: 1.4;
    min-height: calc(1.4em * 2);
  }

  .strength-circle p {
    font-size: 0.85rem;       
    line-height: 1.5;
    max-width: 100%;
    white-space: normal;        
    overflow-wrap: anywhere;   
    word-break: normal;        
    text-wrap: pretty;        
  }
}

/* さらに小さい端末向け微調整 */
@media (max-width: 420px) {
  #about { padding: 36px 14px; }
  #strengths { padding: 44px 14px; }
}

/* btn */
.btn.green {
  display: inline-block;
  background-color: #007f3f;
  color: #fff;
  padding: 12px 32px;
  font-weight: bold;
  text-align: center;
  text-decoration: none;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
  transition: background-color 0.3s ease;
}

.btn.green::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
}

.btn.green:hover {
  background-color: #005f30;
}

.btn.green:hover::after {
  left: 100%;
}

/* =========================================
  HIGH TALENTセクション
========================================= */
#high-talent{
  background:#fff;
  padding:60px 0;
}
#high-talent h2{ 
  margin-bottom:.5rem; 
}

#high-talent .hl-lead{
  max-width:820px; 
  margin:0 auto 1rem; 
  color:#555; 
  line-height:1.8; 
  text-align:center;
  word-break: keep-all; 
  overflow-wrap: break-word; 
  line-break: strict; 
  text-wrap: balance;
}
#high-talent .hl-note{
  text-align:center; 
  font-weight:700; 
  color:#222; 
  margin:.5rem auto 1.2rem;
}

/* =========================================
  1) フローチャート（翻訳可のテキスト図）
========================================= */
#high-talent .hl-flow{
  --gap:16px;
  display:grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  grid-template-areas:
    "cand ar1 train ar2 hosp"
    ".    .   down  .   ."
    ".    .   school .   .";
  align-items:center; justify-items:center;
  gap: var(--gap);
  max-width: 1100px;
  margin: 0 auto 18px;
  padding: 8px 6px;
}
#high-talent .hl-node{
  background:#fff; border:2px solid #111; border-radius:12px;
  padding:14px 16px; text-align:center;
  min-width:220px; max-width:280px;
  box-shadow:0 4px 14px rgba(0,0,0,.06);
}
#high-talent .hl-node h3{ margin:0 0 .35rem; font-size:1.05rem; color:#0a2f73; line-height:1.3; }
#high-talent .hl-node .small{ font-size:.92rem; color:#333; line-height:1.6; margin:0; }
#high-talent .hl-node ul{ list-style:disc; padding-left:1.2em; margin:.25rem 0; text-align:left; }
#high-talent .hl-node .label{ margin:.25rem 0 0; font-size:.85rem; color:#444; }
#high-talent .hl-node .icon{ width:28px; height:28px; margin:0 auto .25rem; }
#high-talent .hl-node .icon svg{ width:100%; height:100%; display:block; }

#high-talent .candidate{ grid-area:cand; }
#high-talent .training { grid-area:train; }
#high-talent .hospital.only-desktop{ grid-area:hosp; }
#high-talent .school   { grid-area:school; }

/* 矢印 */
#high-talent .hl-arrow{ position:relative; }
#high-talent .right{ grid-row:1; height:44px; min-width:90px; }
#high-talent .right::before{
  content:""; position:absolute; left:0; right:12px; top:50%;
  height:4px; background:#111; transform:translateY(-50%);
}
#high-talent .right::after{
  content:""; position:absolute; top:50%; right:0;
  border-left:10px solid #111; border-top:8px solid transparent; border-bottom:8px solid transparent;
  transform:translateY(-50%);
}
#high-talent .right > span{ position:absolute; top:-18px; left:0; right:0; text-align:center; font-size:.85rem; color:#111; }

#high-talent .down{ grid-area:down; width:44px; height:84px; }
#high-talent .down::before{
  content:""; position:absolute; top:0; bottom:12px; left:50%;
  width:4px; background:#111; transform:translateX(-50%);
}
#high-talent .down::after{
  content:""; position:absolute; bottom:0; left:50%;
  border-top:10px solid #111; border-left:8px solid transparent; border-right:8px solid transparent;
  transform:translateX(-50%);
}
#high-talent .down > span{ position:absolute; left:calc(50% + 10px); top:30px; font-size:.85rem; color:#111; white-space:nowrap; }

#high-talent .a1{ grid-area:ar1; }
#high-talent .a2{ grid-area:ar2; }
#high-talent .only-desktop{ display:block; }
#high-talent .only-mobile { display:none; }

/* =========================================
  2) 比較エリア（表＋JLPT）…PC中央 & 同じ枠
========================================= */
#high-talent .hl-compare{
  display:grid; grid-template-columns: minmax(520px, 2fr) minmax(280px, 1fr);
  gap:18px; align-items:start; justify-content:center;
  max-width: 1100px;
  margin: 18px auto 0;
}

/* 表＋JLPTを同幅でひとまとめに（中央寄せしやすく） */
#high-talent .hl-table-wrap{
  width: 100%;
  max-width: 820px;                /* 表の最大幅 */
  margin-inline: auto;             /* 中央 */
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-self: start;
}

/* 表本体（“形を崩さない”） */
#high-talent .hl-table{
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;             /* 列幅を安定させる */
  background:#fff;
  border:1px solid #e8e8e8;
  border-radius:12px 12px 0 0;
  overflow:hidden;
  font-size: 0.95rem;
}
#high-talent .hl-table caption{
  text-align:left; font-weight:700; padding:12px 14px; color:#002b7f;
}
#high-talent .hl-table th, 
#high-talent .hl-table td{
  border:1px solid #eee; padding:12px 14px; vertical-align: middle;
  word-break: keep-all; overflow-wrap:anywhere; text-wrap: balance;
}
#high-talent .hl-table thead th{ background:#f7f7f7; color:#002b7f; }
#high-talent .hl-table tbody tr:nth-child(odd){ background:#fafafa; }

/* JLPTを“表のフッター”風に。孤立感をなくす */
#high-talent .hl-jlpt{
  background:#fff;
  border:1px solid #e8e8e8;
  border-top:0;                               /* 表とつなげる */
  border-radius:0 0 12px 12px;                /* 表と同じ角丸 */
  padding:14px 14px 16px;
}
#high-talent .hl-jlpt-scale{ display:flex; align-items:center; gap:10px; justify-content:space-between; }
#high-talent .hl-jlpt-bar{ flex:1; height:10px; border-radius:999px; background:linear-gradient(90deg,#bdbdbd 0%,#64b5f6 50%,#1e3a8a 100%); }
#high-talent .hl-jlpt-low,.hl-jlpt-high{ font-size:.9rem; white-space:nowrap; }
#high-talent .hl-jlpt-note{ font-size:.85rem; color:#666; margin:.5rem 0 0; }

/* =========================================
  スマホレスポンシブ
========================================= */
@media (max-width: 768px){
  /* フローチャートは縦並び */
  #high-talent .hl-flow{
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "cand cand"
      "ar1  ar1"
      "train train"
      "down down"
      "school school"
      "a3    a3"
      "hosp  hosp";
    gap:12px; padding:6px 10px; justify-items:stretch;
  }
  #high-talent .only-desktop{ display:none !important; }
  #high-talent .only-mobile{ display:block !important; }
  #high-talent .hl-node{ min-width:auto; max-width:100%; width:100%; }

  #high-talent .hl-compare{
    grid-template-columns: 1fr;
    gap:14px;
    justify-items:center;
  }

  #high-talent .hl-table-wrap{
    width: min(720px, 96vw);    
  }
  #high-talent .hl-table{
    font-size: clamp(12px, 3.6vw, 14px);
  }
  #high-talent .hl-table th, 
  #high-talent .hl-table td{
    padding: clamp(6px, 2.2vw, 10px) 10px;
  }
  #high-talent .hl-jlpt{ padding:12px; }

    #high-talent .hl-compare{
    grid-template-columns:1fr !important;
    gap:14px !important;
    justify-items:center !important;
  }
  #high-talent .hl-table-wrap{
    width:min(720px,96vw) !important;
  }

  /* ▼ “tableの見た目”を強制維持 */
  #high-talent .hl-table{ 
    font-size:clamp(12px,3.5vw,14px) !important;
  }
  #high-talent .hl-table caption{ padding:10px 12px !important; }
  #high-talent .hl-table th,
  #high-talent .hl-table td{
    padding:clamp(6px,2.2vw,10px) 10px !important;
  }

  /* 以前の display:block 等を打ち消し */
  #high-talent .hl-table thead{ display:table-header-group !important; }
  #high-talent .hl-table tbody{ display:table-row-group !important; }
  #high-talent .hl-table tr{    display:table-row !important; }
  #high-talent .hl-table th,
  #high-talent .hl-table td{    display:table-cell !important; }

  /* JLPTも同幅で一体表示 */
  #high-talent .hl-jlpt{
    width:100% !important;
    padding:12px !important;
  } 
}

/* さらに小さい端末 */
@media (max-width:420px){
  #high-talent{ padding:36px 0; }
  #high-talent .hl-lead{ font-size:.9rem; line-height:1.6; }
  #high-talent .hl-note{ font-size:.9rem; }
}

/* ===== HIGH TALENT：SPでも“表の形を崩さない”上書きパッチ ===== */
#high-talent .hl-compare{
  max-width:1100px;
  margin-inline:auto;
  align-items:start;
  justify-content:center;
}

#high-talent .hl-table-wrap{
  max-width:820px;
  margin-inline:auto;
  width:100%;
}

#high-talent .hl-table{
  width:100%;
  table-layout:fixed;
  border-collapse:collapse;
}

#high-talent .hl-jlpt{
  border-top:0;
  border-radius:0 0 12px 12px;
}


/* ===== HIGH TALENT：比較表を中央＆PC形のまま縮小 ===== */

/* 比較ブロック全体を中央に。PCでも1カラム運用（表+JLPTは同じ枠） */
#high-talent .hl-compare{
  display:block !important;
  max-width: 900px;            /* お好みで 820〜960px */
  margin: 18px auto 0 !important;
}

/* 表＋JLPT を同幅でひとまとめに */
#high-talent .hl-table-wrap{
  width: 100% !important;
  max-width: 900px !important;
  margin-inline: auto !important;
}

/* ---- “tableの形”を常に復元（他CSSのカード化を無効化） ---- */
#high-talent .hl-table{ 
  display: table !important;
  width: 100% !important;
  table-layout: fixed !important;
  border-collapse: collapse !important;
  border:1px solid #e8e8e8; background:#fff;
  border-radius:12px 12px 0 0; overflow:hidden;
  font-size: 0.95rem;
}
#high-talent .hl-table caption{ text-align:left; font-weight:700; padding:12px 14px; color:#002b7f; }
#high-talent .hl-table thead{ display: table-header-group !important; }
#high-talent .hl-table tbody{ display: table-row-group !important; }
#high-talent .hl-table tr   { display: table-row !important; }
#high-talent .hl-table th,
#high-talent .hl-table td   {
  display: table-cell !important;
  padding: 12px 14px !important;
  border: 1px solid #eee !important;
  vertical-align: middle !important;
  word-break: keep-all;
  overflow-wrap:anywhere;
  text-wrap: balance;
}

/* HIGH TALENT: フローチャート上の見出し */
#high-talent .hl-intro{
  text-align:center;
  margin: 8px auto 12px;           /* 上下の余白 */
  padding: 0 6px;
}

#high-talent .hl-intro__title{
  font-weight: 800;
  color: #0a2f73;
  font-size: clamp(1.05rem, 0.9vw + 1rem, 1.6rem);
  line-height: 1.28;
  text-wrap: balance;
}

#high-talent .hl-intro__tagline{
  margin-top: 4px;
  font-weight: 800;
  color: #008753;
  letter-spacing: .02em;
  font-size: clamp(0.95rem, 0.6vw + 0.9rem, 1.25rem);
  line-height: 1.3;
  text-wrap: balance;
}

/* 視覚的な下線 */
#high-talent .hl-intro::after{
  content:"";
  display:block;
  width: 72px;
  height: 3px;
  background: #e2f3ec;
  border-radius: 999px;
  margin: 8px auto 0;
}

/* 行配色など */
#high-talent .hl-table thead th{ background:#f7f7f7; color:#002b7f; }
#high-talent .hl-table tbody tr:nth-child(odd){ background:#fafafa; }

/* JLPTを表のフッターとして一体化 */
#high-talent .hl-jlpt{
  width: 100% !important;
  border:1px solid #e8e8e8; border-top:0;
  border-radius:0 0 12px 12px; background:#fff;
  padding:14px 14px 16px;
}
#high-talent .hl-jlpt-scale{ display:flex; align-items:center; gap:10px; }
#high-talent .hl-jlpt-bar{ flex:1; height:10px; border-radius:999px;
  background:linear-gradient(90deg,#bdbdbd 0%,#64b5f6 50%,#1e3a8a 100%); }

/* スマホ：形は崩さず、縮小だけ。横スクロール不要。 */
@media (max-width: 768px){
  #high-talent .hl-table{ font-size: clamp(12px, 3.6vw, 14px) !important; }
  #high-talent .hl-table th, 
  #high-talent .hl-table td{ padding: clamp(6px, 2.2vw, 10px) 10px !important; }
  #high-talent .hl-table-wrap{ width: min(720px, 96vw) !important; }
}

/* ===== HIGH TALENT：SPでもPCと同じ形を維持（横スクロール方式） ===== */
@media (max-width: 768px){

  /* 1) 既存の“縦積み化”を無効化してPCと同じエリア配置に戻す */
  #high-talent .hl-flow{
    /* 横スクロールで全体を見せる */
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 10px;               /* iOSでスクロールバー被り防止 */
    gap: 16px !important;
    justify-items: center !important;

    /* PCと同じ並び（固定幅トラックで形を固定） */
    grid-template-areas:
      "cand ar1 train ar2 hosp"
      ".    .   down  .   ."
      ".    .   school .   ." !important;

    /* トラック幅を固定して“PCの形”をそのまま作る */
    grid-template-columns: 280px 90px 280px 90px 280px !important;
  }

  /* 2) ノードの幅もPCと同じに固定（形崩れ防止） */
  #high-talent .hl-node{
    min-width: 280px !important;
    max-width: 280px !important;
  }
  #high-talent .right{  min-width: 90px !important; height: 44px !important; }
  #high-talent .down{   width: 44px !important; height: 84px !important; }

  /* 3) PC専用/モバイル専用の表示切替を“PCと同じ”に */
  #high-talent .only-desktop{ display: block !important; }
  #high-talent .only-mobile { display: none  !important; }
}

/* ===== HIGH TALENT：PCの形を維持しつつ“流動的に縮む”版 ===== */
@media (max-width: 768px){

  /* 可変スケール（ベースはPC幅）。必要なら数値調整OK */
  #high-talent .hl-flow{
    --boxW: clamp(220px, 34vw, 280px);   /* 各ボックス幅（最小↔最大） */
    --gapW: clamp(56px,  10vw,  90px);   /* 矢印の横間隔 */
    --gap:  clamp(10px, 2.4vw, 16px);    /* グリッドの隙間 */

    overflow-x: auto;                    /* どうしても収まらない時は横スクロール */
    -webkit-overflow-scrolling: touch;

    grid-template-areas:
      "cand ar1 train ar2 hosp"
      ".    .   down  .   ."
      ".    .   school .   ." !important;

    grid-template-columns:
      var(--boxW) var(--gapW) var(--boxW) var(--gapW) var(--boxW) !important;

    gap: var(--gap) !important;
    justify-items: center !important;
  }

  /* 各ボックスを可変に */
  #high-talent .hl-node{
    min-width: var(--boxW) !important;
    max-width: var(--boxW) !important;
    padding: clamp(10px, 2.6vw, 16px) clamp(12px, 3vw, 18px) !important;
    border-radius: clamp(10px, 2vw, 12px) !important;
  }

  /* タイトル・本文のフォントを流動的に */
  #high-talent .hl-node h3{
    font-size: clamp(14px, 3.6vw, 17px) !important;
    line-height: 1.3;
  }
  #high-talent .hl-node .small,
  #high-talent .hl-node ul{
    font-size: clamp(12px, 3.2vw, 15px) !important;
    line-height: 1.55;
  }
  #high-talent .hl-node .label{
    font-size: clamp(11px, 2.8vw, 14px) !important;
  }

  /* 右矢印のサイズも縮小 */
  #high-talent .right{ min-width: var(--gapW) !important; height: clamp(36px, 6vw, 44px) !important; }
  #high-talent .right::before{ height: clamp(3px, .5vw, 4px) !important; }
  #high-talent .right::after{
    border-left: clamp(8px, 1.6vw, 10px) solid #111;
    border-top:  clamp(6px, 1.2vw,  8px) solid transparent;
    border-bottom: clamp(6px, 1.2vw,  8px) solid transparent;
  }
  #high-talent .right > span{ font-size: clamp(11px, 2.8vw, 14px) !important; }

  /* 下矢印も縮小 */
  #high-talent .down{ width: clamp(36px, 5vw, 44px) !important; height: clamp(70px, 18vw, 84px) !important; }
  #high-talent .down::before{ width: clamp(3px, .5vw, 4px) !important; }
  #high-talent .down::after{
    border-top:  clamp(8px, 1.4vw, 10px) solid #111;
    border-left: clamp(6px, 1vw,   8px) solid transparent;
    border-right: clamp(6px, 1vw,   8px) solid transparent;
  }
  #high-talent .down > span{ font-size: clamp(11px, 2.8vw, 14px) !important; }

  /* PC専用/モバイル専用の出し分けは“PCと同じ”に固定 */
  #high-talent .only-desktop{ display: block !important; }
  #high-talent .only-mobile { display: none  !important; }
}

/* ===== 比較表（hl-table）も幅に合わせて文字＆余白を流動化 ===== */
@media (max-width: 768px){
  #high-talent .hl-table{
    font-size: clamp(13px, 2.8vw, 16px) !important;
  }
  #high-talent .hl-table th,
  #high-talent .hl-table td{
    padding: clamp(6px, 1.8vw, 14px) clamp(8px, 2.4vw, 16px) !important;
  }
  
  /* 一番左の列（項目列）を狭くする */
  #high-talent .hl-table thead th:first-child,
  #high-talent .hl-table tbody th {
    width: 20% !important;
    padding: clamp(6px, 1.8vw, 14px) clamp(4px, 1.2vw, 8px) !important;
  }
  
  #high-talent .hl-jlpt { padding: clamp(10px, 2.4vw, 16px) !important; }
  #high-talent .hl-jlpt-low,
  #high-talent .hl-jlpt-high { font-size: clamp(11px, 2.6vw, 14px) !important; }
}

/* HLフローをスケールで完全フィットさせるための器 */
#high-talent .hl-flow-fit{
  position: relative;
  overflow: hidden;           /* 変形時のはみ出しを隠す（横スクロール防止） */
  padding-inline: 8px;        /* 端に少しだけ余白（お好みで） */
}

#high-talent .hl-flow{
  transform-origin: left top; /* 左上基準で縮放 */
  will-change: transform;
}

/* モバイルでも“PCと同じ並び”を維持 */
@media (max-width: 768px){
  #high-talent .only-desktop{ display:block !important; }
  #high-talent .only-mobile { display:none  !important; }
}



/* =========================================
  Case セクション
========================================= */
.case-box.with-image {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  padding: 1.5rem;
}

.case-image {
  flex: 1 1 40%;
  max-width: 300px;
}

.case-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
}

.case-content {
  flex: 1 1 55%;
}

.case-content h3 {
  font-size: 1.1rem;
  color: #222;
  margin-bottom: 0.6rem;
  font-weight: bold;
  line-height: 1.5;
}

.case-content p {
  font-size: 0.95rem;
  color: #555;
  line-height: 1.6;
}

/* =========================================
  Case セクション_レスポンシブ
========================================= */

@media (max-width: 768px) {
  .case-box.with-image {
    flex-direction: column;   
    align-items: center;     
    text-align: left;         
    gap: 1rem;
    padding: 1.25rem;
  }

  .case-image {
    flex: 0 1 auto;
    width: 100%;
    max-width: 420px;         
    margin: 0 auto;        
    display: flex;
    justify-content: center;  
  }

  .case-image img {
    width: 100%;
    height: auto;
    display: block;
  }

  .case-content {
    flex: 0 1 auto;
    width: 100%;
    margin-top: 0.5rem;
  }
}

/* さらに小さい端末の微調整（任意） */
@media (max-width: 420px) {
  .case-box.with-image { padding: 1rem; }
  .case-content h3 { font-size: 1.05rem; }
  .case-content p  { font-size: 0.92rem; }
}


/* =========================================
  Flow セクション
========================================= */
.flow-list {
  list-style: none;
  padding: 0;
  margin: 40px 0;
  display: flex;
  flex-direction: column;
  gap: 24px;
  counter-reset: step;
}

.flow-list li {
  position: relative;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 24px 24px 24px 64px; 
  background-color: #f9f9f9;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
  min-height: 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.flow-list li:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.flow-list li::before {
  counter-increment: step;
  content: counter(step); /* 1,2,3 */
  position: absolute;
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  background: #00b88a;
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  text-align: center;
  line-height: 32px;
  font-weight: bold;
  font-size: 1rem;
}

.flow-list li h3 {
  margin-top: 0;
  font-size: 1.2rem;
  margin-bottom: 8px;
  color: #333;
  line-height: 1.4;
  text-wrap: balance;
  word-break: keep-all;
  min-height: calc(1.4em * 2); 
}

.flow-list li p {
  margin: 0;
  font-size: 1rem;
  color: #555;
  line-height: 1.6;
  text-wrap: pretty;
  word-break: keep-all;
}

/* =========================================
  Flow セクション_レスポンシブ
========================================= */
@media (max-width: 768px) {
  .flow-list {
    gap: 16px;
    margin: 28px 0;
  }

  .flow-list li {
    padding: 16px 16px 16px 56px; 
    min-height: 72px;
    box-shadow: 0 1px 3px rgba(0,0,0,.05);
  }

  .flow-list li::before {
    left: 16px;
    width: 28px;
    height: 28px;
    line-height: 28px;
    font-size: 0.95rem;
  }

  .flow-list li h3 {
    font-size: 1.05rem;     
    line-height: 1.35;
    min-height: calc(1.35em * 2);
    margin-bottom: 6px;
  }

  .flow-list li p {
    font-size: 0.9rem;     
    line-height: 1.55;
  }
}

/* さらに小さい端末 */
@media (max-width: 420px) {
  .flow-list li {
    padding: 14px 14px 14px 52px;
  }
  .flow-list li::before {
    left: 14px;
    width: 26px;
    height: 26px;
    line-height: 26px;
    font-size: 0.9rem;
  }
  .flow-list li h3 {
    font-size: 1rem;
    min-height: calc(1.35em * 2);
  }
  .flow-list li p {
    font-size: 0.88rem;
  }
}


/* =========================================
  Flow セクション_調整用
========================================= */

/* 汎用フィット用ラッパー */
.fitbox {
  position: relative;
  width: 100%;
  overflow: hidden;       /* スクロールバーを出さない */
  padding-inline: 8px;    /* 端の安全余白（お好みで 0〜16px） */
}
.fitbox > .fit-target {
  transform-origin: left top;   /* 左上を基準に scale/translate を当てる */
  will-change: transform;
}

/* デスクトップは等倍でくっきり表示（PCの見た目は変えない） */
@media (min-width: 769px){
  .fitbox { overflow: visible; padding-inline: 0; }
  .fitbox > .fit-target { transform: none !important; }
}

/* 念のため：スマホでもPCと同じ5カラムグリッドを維持 */
@media (max-width: 768px){
  #high-talent .hl-flow{
    grid-template-columns: 1fr auto 1fr auto 1fr !important;
    grid-template-areas:
      "cand ar1 train ar2 hosp"
      ".    .   down  .   ."
      ".    .   school .   ."
      !important;
  }
  /* “右寄り”対策：表ブロックは必ず中央に */
  #high-talent .hl-compare,
  #high-talent .hl-table-wrap { margin-left:auto !important; margin-right:auto !important; }
}

/* ── HLフロー：スマホでもPCと同じ要素を表示 ── */
@media (max-width: 768px){
  #high-talent .hl-flow .only-desktop{ display: block !important; }
  #high-talent .hl-flow .only-mobile { display: none  !important; }
  /* 念のため横切れ防止（計測時に幅が潰れないように） */
  #high-talent .hl-flow{ overflow: visible !important; }
}




/* =========================================
  News セクション
========================================= */

.news-section {
  padding: 60px 0;
  background-color: #fff;
  text-align: center;
}

.news-section h2 {
  font-size: 2rem;
  color: #002b7f;
  margin-bottom: 0.3rem;
}

.news-section .section-sub {
  color: #222;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.news-tabs {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 30px;
}

.news-tabs button {
  border: none;
  background: #e0e0e0;
  color: #333;
  font-weight: bold;
  padding: 8px 16px;
  border-radius: 20px;
  cursor: pointer;
  transition: background 0.3s;
}

.news-tabs button.active {
  background: #00a676;
  color: #fff;
}

.news-list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 800px;
  text-align: left;
}

.news-list p {
  text-align: center;
  margin-top: 20px;
  color: #555;
}

.news-item {
  border-bottom: 1px solid #eee;
  padding: 16px 0;
}

.news-item a {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column; /* PC現状維持 */
  gap: 6px;
}

.news-date {
  font-size: 0.9rem;
  color: #888;
}

.news-label {
  background: #002b7f;
  color: #fff;
  font-size: 0.75rem;
  padding: 3px 8px;
  display: inline-block;
  border-radius: 2px;
}

.news-title {
  font-size: 1rem;
  font-weight: bold;
}

.news-title .new {
  background: #ff3b30;
  color: #fff;
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 2px;
  margin-left: 8px;
}

/* ボタン下部 */
.news-btn-wrapper {
  margin-top: 30px;
}

/* =========================================
  News セクション_レスポンシブ
========================================= */
@media (max-width: 768px) {
  .news-section { padding: 44px 0; }

  .news-section h2 {
    font-size: 1.6rem;         
    line-height: 1.3;
    text-wrap: balance;      
  }

  .news-section .section-sub {
    font-size: 0.9rem;
    margin-bottom: 1.2rem;
  }

  .news-tabs {
    gap: 8px;
    margin: 0 auto 20px;
    padding: 0 12px;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
  .news-tabs button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 14px;       
    font-size: 0.9rem;
  }

  .news-list { padding: 0 12px; }

  .news-item { padding: 12px 0; }

  .news-item a { gap: 4px; }

  .news-date {
    font-size: 0.85rem;
    color: #777;
    line-height: 1.3;
    word-break: keep-all;      
    text-wrap: balance;
  }

  .news-label {
    font-size: 0.7rem;
    padding: 3px 6px;
    line-height: 1.2;
  }

  .news-title {
    font-size: 0.95rem;        
    line-height: 1.5;
    word-break: keep-all;
    text-wrap: pretty;      
    display: -webkit-box;     
    -webkit-line-clamp: 2;   
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .news-title .new {
    font-size: 0.6rem;
    padding: 1px 5px;
    margin-left: 6px;
  }

  .news-btn-wrapper { margin-top: 22px; }
}

/* 極小端末（iPhone SE等）向け微調整 */
@media (max-width: 420px) {
  .news-section h2 { font-size: 1.5rem; }
  .news-tabs { padding: 0 10px; }
  .news-tabs button { padding: 9px 12px; font-size: 0.88rem; }
  .news-title { font-size: 0.92rem; -webkit-line-clamp: 2; }
}


/* =========================================
  Contact セクション
========================================= */
.contact-section {
  background: #fff;
  padding: 60px 0;
  text-align: center;
}

.contact-section h2 {
  font-size: 2rem;
  color: #002b7f;
  margin-bottom: 0.5rem;
}

.contact-section .section-sub {
  font-size: 0.95rem;
  color: #222;
  margin-bottom: 1rem;
}

.contact-desc {
  margin-bottom: 2rem;
  font-size: 0.95rem;
  color: #333;
  line-height: 1.6;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  /* 改行を綺麗に */
  text-wrap: balance;
  word-break: keep-all;
}

.contact-grid {
  display: flex;
  gap: 20px;
}

.contact-box {
  height: 100%;
  padding: 20px;
  border: 1px solid #ccc;
  border-radius: 12px;
  text-align: center;
  background-color: #fff;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-box:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.icon-svg {
  margin-bottom: 1rem;
}

.contact-box p {
  font-size: 1.1rem;
  color: #008753;
  font-weight: bold;
  margin-bottom: 0.8rem;
}

/* 新しいボタンデザイン */
.contact-box h3 {
  font-size: 1.3rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  margin-top: 0.5rem;
}

.jobseeker-contact-box h3 {
  color: #00a676;
}

.company-contact-box h3 {
  color: #002b7f;
}

.jobseeker-contact-box p {
  color: #00a676;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.company-contact-box p {
  color: #002b7f;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.contact-arrow {
  font-size: 1.2rem;
  font-weight: bold;
  color: #666;
  transition: transform 0.3s ease, color 0.3s ease;
}

.jobseeker-contact-box:hover .contact-arrow {
  transform: translateX(5px);
  color: #00a676;
}

.company-contact-box:hover .contact-arrow {
  transform: translateX(5px);
  color: #002b7f;
}

.jobseeker-contact-box:hover {
  border-color: #00a676;
  box-shadow: 0 4px 15px rgba(0, 166, 118, 0.15);
}

.company-contact-box:hover {
  border-color: #002b7f;
  box-shadow: 0 4px 15px rgba(0, 43, 127, 0.15);
}

.contact-details p {
  font-size: 0.9rem;
  color: #333;
  margin: 0.4rem 0;
  text-wrap: pretty;
  word-break: keep-all;
}

.contact-details a {
  color: #00a676;
  text-decoration: none;
}

.contact-details a:hover { 
  text-decoration: underline;
}

.contact-box-link {
  text-decoration: none;
  color: inherit;
  display: block;
  flex: 1;
}
.contact-box-link:hover .contact-box {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

/* =========================================
  Responsive（スマホのみ調整）
========================================= */
@media (max-width: 768px) {
  .contact-section { padding: 44px 0; }

  .contact-section h2 {
    font-size: 1.6rem;          
    line-height: 1.3;
    text-wrap: balance;
  }

  .contact-section .section-sub {
    font-size: 0.9rem;
    margin-bottom: 0.9rem;
  }

  .contact-desc {
    font-size: 0.9rem;          
    line-height: 1.6;
    padding: 0 14px;
  }

  .contact-desc br { display: none; }

  /* グリッド：縦1列にしてタップしやすく */
  .contact-grid {
    flex-direction: column;
    gap: 14px;
    padding: 0 14px;
  }

  .contact-box {
    padding: 18px 16px;
    border-radius: 14px;
  }

  .icon-svg svg {
    width: 36px;
    height: 36px;
  }

  .contact-box p {
    font-size: 1rem;             
    margin-bottom: 0.6rem;
  }

  .contact-details p {
    font-size: 0.9rem;
    line-height: 1.5;
  }

  .contact-details svg {
    width: 14px;
    height: 14px;
  }

  /* タップ可視性：リンク領域の余白を少し増やす */
  .contact-box-link { padding: 2px 0; }
}

/* 極小端末（iPhone SE等）微調整 */
@media (max-width: 420px) {
  .contact-section { padding: 36px 0; }
  .contact-desc { font-size: 0.88rem; }
  .contact-box { padding: 16px 14px; }
  .contact-details p { font-size: 0.88rem; }
}




/* =========================================
  Footer
========================================= */
.footer {
  text-align: center;
  padding: 2rem 1rem;
  background-color: #f7f7f7;
}

.sns-links {
  display: flex;
  justify-content: center;
  align-items: center; /* ← 縦方向中央揃え */
  gap: 20px;
  margin-bottom: 10px;
}

/* 全アイコン共通の見た目 */
.sns-icon {
  height: 30px;
  width: 30px;
  object-fit: cover;
  display: inline-block;
  vertical-align: middle;
}

/* YouTubeアイコンだけ横長に */
.youtube-icon {
  height: 30px;
  width: auto;
  aspect-ratio: 16 / 11;
  object-fit: contain;
}

/* noteアイコン用スタイル */
.note-icon {
  height: 30px;
  width: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}

.note-icon svg {
  width: 20px;
  height: 20px;
}

.note-icon:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
  background: #f8f9fa;
}

.sns-icon:hover {
  opacity: 0.7;
}


/* =========================================
  Fadein アニメーション
========================================= */
.fadein {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fadein.show {
  opacity: 1;
  transform: translateY(0);
}

@keyframes fadein {
  from {
    opacity: 0;
  transform: translateY(40px);
}

to {
  opacity: 1;
  transform: translateY(0);
}
}


/* ==============================
  レスポンシブ調整（全体）
============================== */

@media (max-width: 600px) {
  .news-item {
    padding: 14px 0;
  }

  .news-title {
    font-size: 0.95rem;
  }

  .news-label {
    font-size: 0.7rem;
    padding: 2px 6px;
  }

  .news-tabs {
    gap: 6px;
  }

  .news-tabs button {
    padding: 6px 12px;
    font-size: 0.85rem;
  }
}



@media screen and (max-width: 768px) {
  .header {
    width: 100%;
    overflow-x: hidden;
  }
}


@media screen and (max-width: 768px) {
  .strengths-circle-container {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }

  .strength-circle {
    width: 90%;
    max-width: 320px;
    height: auto;
    border-radius: 20px;
    padding: 1.5rem 1.2rem;
    box-sizing: border-box;
    text-align: center;
  }

  .strength-circle h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }

  .strength-circle p {
    font-size: 0.9rem;
    line-height: 1.5;
    word-break: break-word;
  }

  .x-symbol {
    display: none;
  }
}



@media screen and (max-width: 768px) {
  .nav {
    display: none;
    flex-direction: column;
    background-color: #fff;
    position: absolute;
    top: 60px; /* ヘッダー下に配置 */
    right: 0;
    width: 100%;
    padding: 1em;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 999;
  }

  .nav.active {
    display: flex;
  }

  .nav ul {
    flex-direction: column;
    gap: 1em;
  }

  .nav ul li a {
    color: #333;
    font-weight: bold;
    padding: 0.5em;
  }
}

/* モバイル用 */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;
    background: #fff;
    z-index: 1000;
    flex-direction: column;
    padding: 5rem 1rem 1rem;
    transition: right 0.3s ease-in-out;
  }

  .nav.active {
    right: 0;
  }

  body.no-scroll {
    overflow: hidden;
  }
}


@media (min-width: 769px) {
  .header {
    height: auto;
  }

  .logo-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: auto;
    padding: 1rem 0;
  }

  .nav {
    display: block !important;
    position: static;
    height: auto !important;
    width: auto;
    background: none;
    padding: 0;
  }

  .nav ul {
    display: flex;
    flex-direction: row;
    gap: 2rem;
    padding: 0;
    margin: 0;
  }

  .nav ul li {
    margin: 0;
  }

  .nav ul li a {
    padding: 0.5rem 0;
    display: block;
  }

  .hamburger {
    display: none;
  }
}


/* ==============================
  調整用（全体）
============================== */


/* ========= 固定ページの横幅（page.phpの .page-container を使うなら） ========= */
.page-container { max-width: 1100px; margin: 0 auto; padding: 24px 16px 96px; }
.page-narrow .page-container { max-width: 600px; }

/* ========= 会員登録フォーム（ID:68 / class: reg68） 送信ボタン中央 ========= */
/* 1) 送信ボタンが入っている行そのものを中央寄せにする */
#user-registration-form-68 .ur-form-row:has(.ur-submit-button),
#user-registration-form-68 .ur-form-row:has(input[type="submit"]),
form.register.reg68 .ur-form-row:has(.ur-submit-button),
form.register.reg68 .ur-form-row:has(input[type="submit"]) {
  display: flex !important;
  justify-content: center !important;
}

/* 2) その行の内側ボックス幅を自動に（左寄りの原因を無効化） */
#user-registration-form-68 .ur-form-row:has(.ur-submit-button) .ur-field-item,
#user-registration-form-68 .ur-form-row:has(input[type="submit"]) .ur-field-item,
form.register.reg68 .ur-form-row:has(.ur-submit-button) .ur-field-item,
form.register.reg68 .ur-form-row:has(input[type="submit"]) .ur-field-item {
  width: auto !important;
}

/* 3) ボタン自体の見た目と中央寄せの保険 */
#user-registration-form-68 .ur-submit-button,
#user-registration-form-68 input[type="submit"],
form.register.reg68 .ur-submit-button,
form.register.reg68 input[type="submit"] {
  display: inline-block !important;
  margin: 16px auto 0 !important;
  min-width: 180px;
}

/* 4) フォーム直下に余白（フッターにくっつかないように） */
#user-registration-form-68,
form.register.reg68 { margin-bottom: 120px; }

/* スマホでは縦一列＆順序崩れ対策（列幅指定を打ち消し） */
@media (max-width: 768px) {
  #user-registration-form-68 .ur-form-row,
  form.register.reg68 .ur-form-row { display: block !important; }
  #user-registration-form-68 .ur-field-item,
  form.register.reg68 .ur-field-item { width: 100% !important; float: none !important; }
}

/* ========= ログインフォーム (/login) 送信ボタン中央 ========= */
body.page-slug-login .ur-frontend-form .ur-form-row:has([type="submit"]) {
  display: flex !important;
  justify-content: center !important;
}
body.page-slug-login .ur-frontend-form [type="submit"] {
  margin: 12px auto !important;
  min-width: 180px;
}

/* ログインフォーム下の余白 */
body.page-slug-login .ur-frontend-form { margin-bottom: 120px; }

/* --- 会員登録フォーム: Submit ボタン中央寄せ（クラス直指定） --- */
/* プラグインの「Submit Button Class」に入れた btn-center をそのまま使う */
.user-registration .btn-center {
  display: block !important;
  margin: 16px auto 0 !important;  /* 左右 auto で中央 */
  float: none !important;
  min-width: 180px;               /* お好み */
}

/* 念のため: ID/クラス経由の保険 */
#user-registration-form-68 .ur-submit-button,
#user-registration-form-68 [type="submit"],
form.register.reg68 .ur-submit-button,
form.register.reg68 [type="submit"] {
  display: block !important;
  margin: 16px auto 0 !important;
  float: none !important;
}

/* 送信行がカラム割りのままでも中央寄せにする保険 */
form.register.reg68 .ur-form-row:last-child .ur-field-item {
  width: 100% !important;
  text-align: center !important;
}

/* フォーム直下の余白（フッターとくっつかないように） */
#user-registration-form-68,
form.register.reg68 { margin-bottom: 120px; }

/* --- ログインページのボタン中央寄せ --- */
body.page-slug-login .ur-frontend-form [type="submit"] {
  display: block !important;
  margin: 12px auto !important;
  float: none !important;
  min-width: 180px;
}
body.page-slug-login .ur-frontend-form { margin-bottom: 120px; }



/* === UR: 送信ボタンを確実に中央に（登録/ログイン共通） === */
.user-registration .ur-submit-button-item,
.ur-frontend-form .ur-submit-button-item {
  width: 100% !important;                  /* 行のカラム割りを打ち消す */
  display: flex !important;
  justify-content: center !important;
  text-align: center !important;           /* 旧マークアップ保険 */
}

.user-registration .ur-submit-button,
.ur-frontend-form .ur-submit-button,
.user-registration [type="submit"],
.ur-frontend-form [type="submit"] {
  display: inline-block !important;        /* インラインで中央 */
  margin: 16px auto 0 !important;          /* 左右 auto で中央 */
  float: none !important;
  min-width: 180px;                        /* お好みで */
}

/* ID/フォームクラスに対しても保険（あなたの環境のID/クラス） */
#user-registration-form-68 .ur-submit-button-item,
form.register.reg68 .ur-submit-button-item {
  display: flex !important;
  justify-content: center !important;
}

#user-registration-form-68 .ur-submit-button,
form.register.reg68 .ur-submit-button {
  margin: 16px auto 0 !important;
}

/* フォーム直下の余白（フッターとくっつかないように） */
#user-registration-form-68,
.ur-frontend-form { margin-bottom: 120px; }


/* ヘッダー系を最前面へ */
.header-login-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 10050; }
.header            { position: fixed; top: 44px; left: 0; right: 0; z-index: 10040; }
.header, .header * { pointer-events: auto; }

/* コンテンツはヘッダー高さぶん下げる（被り防止・数値は実際の高さに合わせて調整） */
.site-main { padding-top: 120px; }  /* 緑帯+白ヘッダーの合計高さに合わせて調整 */

/* もし上にかぶる全幅の要素がある場合の保険（オーバーレイ無効化） */
.page-container, .site-main, .hero { position: relative; z-index: 1; }
.hero::before, .page-overlay { pointer-events: none !important; }


/* ヘッダーは“まとめて”固定。中のバーは固定しない */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10050;
}

/* ログインバーは header の一部として流す（←固定を外すのがポイント） */
.header-login-bar {
  position: static;   /* 以前 fixed にしていたら上書き */
  margin: 0;
}

/* 余計な上マージンのリセット（間が空くのを防止） */
.logo-nav { margin-top: 0; }

/* コンテンツは header の高さぶんだけ下げる（JSで実測セット） */
:root { --header-h: 120px; }       /* フォールバック値（仮） */
.site-main { padding-top: var(--header-h); }

/* クリック不可対策の保険（上にかぶる要素があった場合） */
.site-main, .page-container, .hero { position: relative; z-index: 1; }


/* ===== Hero：常に1画面いっぱい（ヘッダー＋ログインバー分を考慮） ===== */
.hero{
  position: relative;
  min-height: 100svh;          /* アドレスバーの伸縮にも強い */
  overflow: hidden;
}

/* スライダー全面フィット */
.hero-slider{
  position: absolute;
  inset: 0;
}
.hero-slider .slide{
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  will-change: transform, opacity; /* アニメがあっても滑らかに */
}

/* テキストブロックは前面＆ヘッダーの下から始まる */
.hero .hero-text{
  position: relative;
  z-index: 1;
  min-height: 100%;
  display: grid;
  align-content: center;  /* デフォルトは中央（PC/スマホで個別に上書き） */
  padding-top: 0;
  padding-bottom: 10px;
  text-align: center;
}

/* モバイルでの余白・文字サイズ微調整（必要なら） */
@media (max-width: 768px){
  /* テキストサイズは削除（後続のメディアクエリで上書き） */
}

/* ===== スマホ時：ログインバーを隠し、ハンバーガー内に複製して表示 ===== */
/* ログインバーの実体をスマホでは非表示（中身はJSでメニューへ複製） */
@media (max-width: 768px){
  .login-bar, #login-bar { display: none !important; }
}

/* ハンバーガー内に入れたログイン項目の最小スタイル（必要に応じて調整） */
.login-merged-item > a,
.login-merged-item > button{
  display: block;
  padding: 12px 16px;
  width: 100%;
  text-align: left;
}


/* =========================================================
   Mobile fixes: wrap overflow (about/flow/news) & tidy hero breaks
   ※ PCの見た目は一切変えません
========================================================= */
@media (max-width: 768px){

  /* 端の安全余白（notch対策も） */
  #about .container,
  #flow  .container,
  .news-section .container{
    padding-left:  max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  /* ─ Hero：句読点やダッシュが単体で改行されないように上書き ─ */
  .hero-text .pc-br{ display:none; } /* 手動改行はスマホで無効 */
  .hero-text h2,
  .hero-text p{
    word-break: normal;           /* 途中でむやみに割らない */
    overflow-wrap: break-word;    /* どうしても長い時だけ語末で折返し */
    line-break: strict;           /* 禁則処理（日本語） */
    hanging-punctuation: allow-end; /* 句読点を行末にぶら下げ可（対応ブラウザ） */
    text-wrap: balance;           /* 行のバランス優先（対応ブラウザ） */
  }

  /* ─ About：文章/ハイライトは安全に折返し。手動 <br> は無効化 ─ */
  #about .section-desc,
  #about .highlight-box{
    word-break: normal;
    overflow-wrap: break-word;
    line-break: strict;
    text-wrap: pretty;
  }
  #about .section-desc br,
  #about .highlight-box br{ display:none; }

  /* ─ Flow：カード幅を100%に固定しつつ文を安全に折返し ─ */
  .flow-list{ margin-inline: 0; }
  .flow-list li{
    width: 100%;
    box-sizing: border-box;
  }
  .flow-list li h3,
  .flow-list li p{
    word-break: normal;
    overflow-wrap: break-word;
    line-break: strict;
    text-wrap: pretty;
  }

  /* ─ News：タイトル等のはみ出し抑制（英字が長い時も安全） */
  .news-list{ max-width: 100%; }
  .news-item{ overflow: hidden; }
  .news-item a{ max-width: 100%; }
  .news-title{
    word-break: normal;
    overflow-wrap: break-word;
    line-break: strict;
    text-wrap: pretty;
  }
}



/* ── SP：ログアウト時は会員登録／ログインを右側へ ───────────────── */
@media (max-width: 768px){
  /* WPはログイン中だと body に .logged-in が付く → 付いていない＝ログアウト */
  body:not(.logged-in) .header-login-bar .login-bar-left{
    display: none !important;              /* 左側の文言は隠す */
  }
  body:not(.logged-in) .header-login-bar .login-bar-inner{
    justify-content: flex-end !important;  /* 右寄せ（子要素1個でも左に寄らない） */
  }
  body:not(.logged-in) .header-login-bar .login-bar-right{
    margin-left: auto;                     /* 念のため保険 */
    display: flex;
    gap: 10px;
  }
}


/* PC：ログインボタンの右側に余白を取って馴染ませる */
.header .lang-switch { margin-left: 10px; }
.header .lang-switch select { padding: 6px 10px; border-radius: 16px; font-size: 13px; }

/* スマホ：ログインバー側は隠し、ハンバーガー内だけ表示 */
@media (max-width: 768px){
  .header-login-bar .lang-switch { display: none; }
  .nav .nav-lang-mobile { width: 100%; padding: 10px 0; }
  .nav .nav-lang-mobile .lang-switch { text-align: center; width: 100%; }
  .nav .nav-lang-mobile .lang-switch select { width: 90%; font-size: 16px; padding: 10px 12px; }
}

/* 余計なラベルが出る場合は非表示（設定で “Select language label” を空にできない時） */
.gtranslate_wrapper label { display: none !important; }

/* ナビとの間隔を広げる */
.header .header-lang { 
  margin-left: clamp(14px, 2vw, 28px);
}

/* 横幅を狭める（どの表示モードでも効くように網羅） */
.header .header-lang .switcher,
.header .header-lang .gt_switcher,
.header .header-lang select {
  width: 140px;            /* ←お好みで 120–160px 程度に */
  max-width: 140px;
}

/* ラベルが長い言語名のときに省略表示してハミ出し防止 */
.header .header-lang .gt_selected,
.header .header-lang .switcher .selected {
  max-width: 100%;
}
.header .header-lang .gt_selected span,
.header .header-lang .switcher .selected span,
.header .header-lang .switcher .option span {
  display: inline-block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

/* 旗+言語名の隙間を少し詰めたい場合（任意） */
.header .header-lang .gt_selected .flag,
.header .header-lang .switcher .selected .flag { 
  margin-right: 6px;
}

/* スマホ時：さらにコンパクトに */
@media (max-width: 768px){
  .header .header-lang { margin-left: 10px; }
  .header .header-lang .switcher,
  .header .header-lang .gt_switcher,
  .header .header-lang select {
    width: 120px;
    max-width: 120px;
  }
}

/* GTranslate 本体の幅（セレクト/スイッチャ両対応） */
.header .gt_switcher,
.header .gt_switcher_wrapper,
.header .gt_selector,
.header .gtranslate_wrapper select#gtranslate_selector {
  width: 118px !important;   /* ←お好みで 100〜130px くらい */
  max-width: 118px !important;
}

/* スイッチャ内部の文字・余白を少しタイトに */
.header .gt_switcher a,
.header .gt_switcher .gt_selected {
  padding: 6px 8px !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
  white-space: nowrap;
}
.header .gt_switcher .gt_options { min-width: 118px !important; }

/* スマホ時はさらに細めに */
@media (max-width: 768px){
  .header .gt_switcher,
  .header .gt_switcher_wrapper,
  .header .gt_selector,
  .header .gtranslate_wrapper select#gtranslate_selector {
    width: 108px !important;
    max-width: 108px !important;
  }
}

/* デスクトップ：GTranslate とナビの“距離”を広げる */
@media (min-width: 769px){
  .header .logo-nav .nav-right > .gtranslate_wrapper,
  .header .logo-nav .nav-right > .lang-switch,
  .header .logo-nav .nav-right > .gt_switcher_wrapper {
    margin-right: 24px !important;   /* ← ここで距離を調整（例: 24〜40px） */
  }

  /* もし“全体の間隔”自体も少しだけ詰めたいなら（任意） */
  .header .logo-nav .nav-right{
    gap: 8px !important;             /* ← inline の gap:12px を上書き */
  }
}


/* =======================================================================
   OVERRIDE: モバイルナビを「右から出るオフキャンバス」に統一（他は変更なし）
   - 既存の display:none や left:0 指定を上書きするために !important を最小限使用
   - JS は .hamburger → .nav に .active を付け外しする実装のままでOK
======================================================================= */
@media (max-width: 1024px){
  .nav{
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;                 /* 既存の left:0 を無効化 */
    width: min(84vw, 420px) !important;    /* 横幅はお好みで */
    height: 100dvh !important;
    margin-right: 0 !important;
    padding: 5rem 1rem 1.25rem !important; /* 既存レイアウトは維持 */
    background: #fff !important;
    box-shadow: -12px 0 24px rgba(0,0,0,.12) !important;
    display: flex !important;              /* transformで隠すので常にflex */
    flex-direction: column !important;
    align-items: center !important;
    gap: 30px !important;

    transform: translateX(100%) !important;/* 右の画面外に隠す */
    transition: transform .28s ease !important;

    z-index: 10060 !important;             /* ヘッダー(10050)より前面に */
    pointer-events: none !important;       /* 非表示時の誤タップ防止 */
  }
  .nav.active{
    transform: translateX(0) !important;   /* スライドイン */
    pointer-events: auto !important;
  }

  /* 既存の“ヘッダー下にドロップするメニュー”指定を無効化 */
  .logo-nav .nav{ top: 0 !important; }
}


/* =========================================================
   [追加] Mobile: Languageタブを横長＆選択が分かる見た目に
   （ナビ内のGTranslate/セレクト両対応）
========================================================= */
@media (max-width: 768px){
  /* select 型 */
  .nav .nav-lang-mobile .lang-switch select,
  .nav .nav-lang-mobile .gtranslate_wrapper select#gtranslate_selector {
    width: 92% !important;
    max-width: none !important;
    min-width: 220px;
    padding: 12px 16px !important;
    border-radius: 22px !important;
    border: 1px solid #ddd !important;
    background: #f7f9fb !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    text-align: center;
  }

  /* スイッチャ（a要素）型 */
  .nav .nav-lang-mobile .gt_switcher,
  .nav .nav-lang-mobile .switcher {
    width: 92% !important;
    max-width: none !important;
    min-width: 220px;
  }
  .nav .nav-lang-mobile .gt_switcher .gt_selected,
  .nav .nav-lang-mobile .switcher .selected {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 100% !important;
    padding: 10px 14px !important;
    border-radius: 22px !important;
    border: 1px solid #ddd !important;
    background: #eef3f7 !important; /* 選択状態が視認できる淡色 */
    font-size: 16px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
  }
  .nav .nav-lang-mobile .gt_selected span,
  .nav .nav-lang-mobile .switcher .selected span {
    max-width: 100% !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

/* =========================================================
   [追加] ハンバーガーは常に表示（≤1024px）
========================================================= */
@media (max-width: 1024px){
  .hamburger{ display:flex !important; }
}

/* =========================================================
   [追加] オフキャンバスNavを“ボワッ”と表示（fadein同速0.8s）
   - transform + opacity で自然に
   - 既存のオフキャンバス指定を上書き
========================================================= */
@media (max-width: 1024px){
  .nav{
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    width: min(84vw, 420px) !important;
    height: 100dvh !important;
    margin-right: 0 !important;
    padding: 5rem 1rem 1.25rem !important;
    background: #fff !important;
    box-shadow: -12px 0 24px rgba(0,0,0,.12) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 30px !important;
    z-index: 10060 !important;

    /* ← “ボワッ” */
    opacity: 0;
    visibility: hidden;
    transform: translateX(100%);
    transition:
      transform .8s ease-out,
      opacity   .8s ease-out,
      visibility 0s linear .8s;
    pointer-events: none !important;
  }
  .nav.active{
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    transition:
      transform .8s ease-out,
      opacity   .8s ease-out,
      visibility 0s;
    pointer-events: auto !important;
  }

  /* 背景の“薄い暗幕”をボディ疑似要素で（JSで body.nav-open を付与するなら） */
  body.nav-open::after{
    content:"";
    position: fixed; inset: 0;
    background: rgba(0,0,0,.25);
    z-index: 10055;            /* nav(10060)の下、コンテンツの上 */
    animation: fadein .8s ease-out;
  }
}

/* =========================================================
   [追加] ハンバーガーのアニメ速度を合わせる（任意）
========================================================= */
.hamburger span{
  transition: transform .8s cubic-bezier(0.77,0,0.175,1),
              opacity   .8s ease-out;
}

/* =========================================================
   Mobile: ドロワーメニューを半透明＆フェードスライドで表示
   - ハンバーガーの位置はそのまま（header上）
   - メニュー全体を透過（blur付き）
   - 表示中もハンバーガーは常に見える
========================================================= */
@media (max-width: 1024px){

  /* 直前提案の“固定ハンバーガー＋丸背景”を無効化 */
  .hamburger{
    position: static !important;
    top: auto !important;
    right: auto !important;
    z-index: 2001 !important;       /* nav より上 */
  }
  .hamburger::after{ content: none !important; }

  /* header を nav より上に（ハンバーガー常時見える） */
  .header{ z-index: 2000 !important; }

  /* ドロワー自体を半透明＋blur。右から「ボワッ」と */
  .nav{
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    height: 100vh !important;
    width: min(78%, 420px) !important;

    /* 透過＆ぼかし（iOS含む） */
    background: rgba(255,255,255,0.88) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    /* header分だけ中身を下げる（重なり防止） */
    padding: calc(var(--header-total, 100px) + 16px) 16px 24px !important;

    display: flex !important;
    flex-direction: column;
    gap: 20px;

    /* スライド＆フェード（他のfadeinと同速 0.8s） */
    transform: translateX(100%);
    opacity: 0;
    transition: transform .8s ease-out, opacity .8s ease-out;

    /* 後ろをクリック不可に */
    pointer-events: none;
    z-index: 1000 !important;        /* header(2000)より下 */
  }

  .nav.active{
    transform: translateX(0);
    opacity: 1;
    pointer-events: auto;
  }

  /* モバイルのリスト体裁（必要な場合だけ上書き） */
  .nav ul{
    flex-direction: column !important;
    gap: 18px !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  .nav li a{
    display: block;
    padding: 12px 8px;
    text-align: left;
    color: #222;
    font-weight: 600;
    text-decoration: none;
  }
}

/* === HERO（PCのみ）：ヘッダー分だけ下げ、残りをピッタリ表示 === */
@media (min-width: 769px){
  .hero{
    /* 旧指定の打ち消し */
    margin-top: 0 !important;
    height: auto !important;

    /* 画面の高さ - ヘッダー高 = ちょうど1画面に収まる */
    min-height: calc(100dvh - var(--header-total)) !important;
    padding-top: var(--header-total) !important;

    /* 念のための安全策 */
    overflow: hidden;
  }
  /* ヒーロー内の余白はゼロ（はみ出しや段差防止） */
  .hero .container{
    padding: 0 !important;
    margin: 0 !important;
  }
}

/* === HERO（PC）：全画面をやめ、ヘッダーの下から開始＋画像は全体表示 === */
@media (min-width: 769px){
  /* 既存の 100vh 強制や負マージンを無効化 */
  .hero{
    margin-top: 0 !important;
    padding-top: var(--header-total) !important; /* ← ヘッダー分だけ下げる */
    height: auto !important;
    min-height: 0 !important;
    background-color: transparent !important;
    overflow: visible !important;
  }

  /* ヒーローの可視高さを“画面幅ベース”で程よく（好みで数値調整OK） */
  .hero-slider{
    position: relative !important;
    inset: auto !important;
    width: 100% !important;
    height: clamp(420px, 48vw, 720px) !important;
  }

  /* 画像はトリミングしない（上下に余白が出てもOK） */
  .hero-slider .slide{
    inset: 0 !important;
    background-size: contain !important;      /* ★全部見せる */
    background-position: top center !important;/* 上基準（中央が良ければ center に） */
    background-repeat: no-repeat !important;
    opacity: 0;
    animation: fadeSlide 20s infinite;
    transition: opacity 1s ease-in-out;
  }

  /* オーバーレイが余白部分まで被らないよう薄めにする場合（任意） */
  .hero::before{
    background: rgba(0,0,0,0.35) !important;
  }
}

/* ==== HERO（PC）：画像を全部見せつつ中央にテキスト ====
   画像の縦横比をここで設定（例：16/9, 3/2, 4/3 など）
*/
@media (min-width: 769px){
  :root{ --hero-ratio: 16/9; } /* ←あなたのヒーロー画像の比率に合わせて調整 */

  /* ヘッダーの下から開始（重なり防止） */
  .hero{
    position: relative;
    margin-top: var(--header-total) !important;
    padding-top: 0 !important;
    background: transparent !important;
    overflow: visible !important;
  }
  /* 旧オーバーレイは画像領域外にもかかるので無効化 */
  .hero::before{ display: none !important; }

  /* 画像領域＝ヒーローの実高さ（比率で決定／灰色が出ない） */
  .hero-slider{
    position: relative !important;
    width: 100% !important;
    aspect-ratio: var(--hero-ratio) !important; /* ←ここが肝 */
    margin: 0 auto !important;
    overflow: hidden !important;
    z-index: 0;
    background: #000; /* 万一の誤差用（黒帯。気になるならお好みの色に） */
  }
  /* オーバーレイは画像領域の中だけに */
  .hero-slider::after{
    content:"";
    position:absolute; inset:0;
    background: rgba(0,0,0,.45);
    z-index: 1;
    pointer-events: none;
  }

  /* スライド画像：全体表示（トリミングなし） */
  .hero-slider .slide{
    position: absolute;
    inset: 0;
    background-size: contain !important;         /* ★全部見せる */
    background-position: center center !important;
    background-repeat: no-repeat !important;
    z-index: 0;
    opacity: 0;
    animation: fadeSlide 20s infinite;
    transition: opacity 1s ease-in-out;
  }

  /* テキスト＆ボタンを"画像の下ギリギリ"に */
  .hero .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    padding: 0 16px 10px !important;
    z-index: 2 !important;
    text-align: center;
  }
  /* .container のデフォルト余白を打ち消し（中央にズレないように） */
  .hero .container{ padding: 0 !important; margin: 0 auto !important; }

  .hero .hero-buttons{ justify-content: center; }
}

/* ==== HERO：PCは「全部画像」＋中央テキスト（高さは比率ベースのまま） ==== */
@media (min-width: 769px){
  :root{
    --hero-ratio: 16/9; /* ← ヒーロー画像の比率に合わせて変更OK */
  }

  /* ヘッダーに隠れないように、開始位置だけ下げる */
  .hero{
    position: relative;
    margin-top: var(--header-total) !important;
    padding-top: 0 !important;
    background: transparent !important;
    overflow: visible !important;
  }

  /* 画像領域＝ヒーローブロックの見た目の高さ（比率で決める＝前回の高さ感） */
  .hero-slider{
    position: relative !important;
    width: 100% !important;
    aspect-ratio: var(--hero-ratio) !important; /* ← 高さはこの比率で確定 */
    margin: 0 auto !important;
    overflow: hidden !important;
    z-index: 0;
    background: transparent !important; /* 下地の黒/灰は消す */
  }

  /* 画像は全面フィル（帯なし）。＝一部トリミングは発生します */
  .hero-slider .slide{
    position: absolute;
    inset: 0;
    background-size: cover !important;           /* ★ 全部が画像（帯なし） */
    background-position: center center !important;
    background-repeat: no-repeat !important;
    z-index: 0;
    opacity: 0;
    animation: fadeSlide 20s infinite;
    transition: opacity 1s ease-in-out;
  }

  /* 読みやすさのための薄いオーバーレイは画像領域の中だけに */
  .hero::before{ display:none !important; }      /* 旧オーバーレイ無効化 */
  .hero-slider::after{
    content:"";
    position:absolute; inset:0;
    background: rgba(0,0,0,.30);                 /* 濃ければ数値↑/薄くは↓ */
    z-index: 1; pointer-events: none;
  }

  /* テキスト＆ボタンを下ギリギリに */
  .hero .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    padding: 0 16px 10px !important;
    z-index: 2 !important;
    text-align: center;
  }
  /* containerの余白は打ち消してズレ防止 */
  .hero .container{ padding: 0 !important; margin: 0 auto !important; }
  .hero .hero-buttons{ justify-content: center !important; }
}

/* ==== HERO（PC）：全画像を“そのまま”見せる＋中央テキスト＋ヘッダーに被らない ==== */
@media (min-width: 769px){
  :root{
    /* ← ここだけ変えれば高さが変わります（例 16/9, 3/2, 4/3 など） */
    --hero-ratio: 16/9;
  }

  /* ヘッダーの下から開始（被り防止） */
  .hero{
    position: relative;
    margin-top: var(--header-total) !important; /* ← 固定ヘッダーぶん下げる */
    padding-top: 0 !important;
    background: transparent !important;
  }

  /* 旧オーバーレイは無効化（暗くならないように） */
  .hero::before{ display:none !important; }

  /* 画像の入れ物＝比率で高さ決定（余白や黒帯を作らない） */
  .hero-slider{
    position: relative !important;
    width: 100% !important;
    aspect-ratio: var(--hero-ratio) !important; /* ← 高さはココで決まる */
    margin: 0 auto !important;
    overflow: hidden !important;
    background: transparent !important;
    z-index: 0;
  }

  /* 画像は“全部表示”（contain）。入れ物の比率が同じなので帯は出ません */
  .hero-slider .slide{
    position: absolute;
    inset: 0;
    background-size: contain !important;          /* ★ 全部見せる（トリミングなし） */
    background-position: center center !important;
    background-repeat: no-repeat !important;
    opacity: 0;
    animation: fadeSlide 20s infinite;
    transition: opacity 1s ease-in-out;
    z-index: 0;
  }

  /* テキスト＆ボタンを下ギリギリに */
  .hero .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    padding: 0 16px 10px !important;
    text-align: center;
    z-index: 2 !important;
  }

  /* containerの余白は打ち消し（わずかなズレ防止） */
  .hero .container{ padding: 0 !important; margin: 0 auto !important; }
  .hero .hero-buttons{ justify-content: center !important; }
}

/* ===== HERO：全画面フルブリード（黒/グレー帯なし）＆中央テキスト ===== */
.hero{
  position: relative !important;
  margin: 0 !important;
  padding: 0 !important;
  height: 100svh !important;      /* 全画面 */
  min-height: 100svh !important;
  overflow: hidden !important;
  background: transparent !important;
}

/* オーバーレイは消す（暗くならない） */
.hero::before{ display:none !important; }

/* 画像を“cover”で敷き詰め（はみ出しOK＝トリミング可） */
.hero-slider{
  position: absolute !important;
  inset: 0 !important;
  z-index: 0;
}
.hero-slider .slide{
  position: absolute; inset: 0;
  background-size: cover !important;          /* ← グレー/黒帯が出ない */
  background-position: center center !important;
  background-repeat: no-repeat !important;
  opacity: 0;
  animation: fadeSlide 20s infinite;
  transition: opacity 1s ease-in-out;
}

/* テキスト＆ボタンは画像の下ギリギリに配置
   人物の顔に被らないように下寄せ */
.hero .hero-text{
  position: absolute !important;
  inset: 0 !important;
  display: grid !important;
  align-items: end !important;
  justify-items: center !important;
  padding: 0 16px 10px !important;
  z-index: 2;
  text-align: center;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,.35);      /* 可読性のためにごく薄く */
}
.hero .container{ padding: 0 !important; margin: 0 auto !important; }

/* もし古い指定で .hero に margin-top / height などがある場合の保険 */
.hero{ margin-top: 0 !important; }

/* （任意）ヘッダーの白帯も透過して“画面ぜんぶ画像”にしたい場合は下2行をON
.home .header{ background: transparent !important; box-shadow:none !important; }
.home .header-login-bar{ background: transparent !important; color:#fff !important; }
*/


/* ===== HERO：ヘッダー分だけ下げて、その分だけ高さを引く（全画面） ===== */
:root{ --hero-offset-top: 0px; }

.hero{
  position: relative !important;
  margin: 0 !important;
  /* ヘッダーの高さだけ下に開始 */
  margin-top: var(--hero-offset-top) !important;

  /* 画面高 − ヘッダー高 ＝ ちょうど1画面に収まる */
  height: calc(100svh - var(--hero-offset-top)) !important;
  min-height: calc(100svh - var(--hero-offset-top)) !important;

  overflow: hidden !important;
  background: transparent !important;
}

/* 余計なオーバーレイ・余白を殺す */
.hero::before{ display:none !important; }
.hero .container{ padding:0 !important; margin:0 auto !important; }

/* スライダーは全面フィット（黒/グレー帯を出さない） */
.hero-slider{
  position: absolute !important;
  inset: 0 !important;
  z-index: 0 !important;
}
.hero-slider .slide{
  position: absolute !important;
  inset: 0 !important;
  background-size: cover !important;         /* ← 画面いっぱい＆トリミングOK */
  background-position: center center !important;
  background-repeat: no-repeat !important;
  opacity: 0;
  animation: fadeSlide 20s infinite;
  transition: opacity 1s ease-in-out;
}

/* ========================================
   PC専用：テキスト＆ボタンを下ギリギリに配置
======================================== */
@media (min-width: 769px){
  .hero .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    align-content: end !important;
    z-index: 2 !important;
    text-align: center;
    color: #fff;
    text-shadow: 0 2px 6px rgba(0,0,0,.35);
    padding: 0 16px 40px !important; /* 下に余白を追加 */
    margin: 0 auto !important;
  }
  
  .hero .hero-buttons{
    margin: 0;
    margin-top: 0 !important;
    margin-bottom: 20px !important; /* ボタンの下に余白を追加 */
  }
  
  /* PC専用：ボタンとキャッチコピーの間隔調整 */
  .hero .hero-text h2{
    margin-bottom: 0.8rem !important;
  }
  
  .hero .hero-text p{
    margin-bottom: 1rem !important;
  }
}

/* ========================================
   スマホ専用：テキストとボタンの配置
   ※このセクションは削除され、ファイル末尾に移動しました
======================================== */

/* 旧指定の打ち消し（保険） */
.hero{ background-color: transparent !important; }

/* === HOMEだけに効かせる最終パッチ（CSSの一番下に置く） === */
.home .site-main{ padding-top: 0 !important; }  /* 二重オフセットを殺す */

@media (min-width:1025px){
  .home .hero{
    /* 旧: margin-top:60px / height:calc(100vh - 60px) を無効化 */
    margin-top: 0 !important;
    /* 固定ヘッダーの実寸（JSで --header-total に入る）だけ中身を下げる */
    padding-top: var(--header-total, 120px) !important;

    /* 画面高 − ヘッダー高 ＝ 1画面ピッタリ */
    height:     calc(100dvh - var(--header-total,120px)) !important;
    min-height: calc(100dvh - var(--header-total,120px)) !important;

    overflow: hidden !important;
    background: #000; /* 1px隙間の保険 */
  }
  /* ヒーロー内の共通余白を無効化（containerの60pxが入らないように） */
  .home .hero .container{ padding:0 !important; margin:0 !important; }

  /* スライダーを全面フィット＋“やや上寄せ”で顔を切りにくく */
  .home .hero-slider{ position:absolute !important; inset:0 !important; }
  .home .hero-slider .slide{
    position:absolute; inset:0 !important;
    background-size: cover !important;           /* 画面いっぱい（白帯なし） */
    background-position: 50% 15% !important;     /* ← 上寄せ。必要なら 0〜25% で微調整 */
    background-repeat: no-repeat !important;
  }
}

/* ── 画像を「全体表示」にしたいスライドだけ：.hero に .hero--contain を付与 ──
   （上下に黒帯が出ても良い＝1ピクセルも切りたくない場合の専用モード）
*/
@media (min-width:1025px){
  .home .hero.hero--contain .hero-slider .slide{
    background-size: contain !important;
    background-position: center center !important;
    background-color: #000 !important; /* 白帯を出さない */
  }
}

/* ===== HOMEヒーロー：PCで「1画面いっぱい」＋テキストど真ん中 ===== */
.home .site-main{ padding-top:0 !important; }  /* 二重オフセット防止 */

@media (min-width:1025px){
  .home .hero{
    margin:0 !important;
    padding:0 !important;
    /* 画面高 − 固定ヘッダー高 = 1画面ピッタリ */
    height:     calc(100dvh - var(--header-total,120px)) !important;
    min-height: calc(100dvh - var(--header-total,120px)) !important;
    overflow:hidden !important;
  }

  /* オーバーレイは有効（読みやすさ） */
  .home .hero::before{
    content:""; position:absolute; inset:0;
    background: rgba(0,0,0,.45) !important; z-index:1;
  }

  /* ← ここが左寄りの犯人：margin を auto に戻す */
  .home .hero .container{
    width:90% !important; max-width:1100px !important;
    padding:0 !important;
    margin:0 auto !important;   /* 中央寄せ */
    text-align:center !important;
  }

  /* テキストを常に“ど真ん中”（ヘッダー分だけ上に余白） */
  .home .hero .hero-text{
    position:absolute !important; inset:0 !important;
    display:grid !important; place-items:center !important;
    padding: calc(var(--header-total,120px) + 8px) 16px 24px !important;
    z-index:2 !important; text-align:center !important;
  }

  /* 画像は全面フィット（白帯なし）。必要なら y を 10〜25% に調整 */
  .home .hero-slider{ position:absolute !important; inset:0 !important; z-index:0 !important; }
  .home .hero-slider .slide{
    position:absolute; inset:0;
    background-size: cover !important;
    background-position: 50% 18% !important; /* 上寄せ気味 */
    background-repeat:no-repeat !important;
  }
}

/* ===== HOME / HERO を本当に「画面いっぱい」にする最終パッチ ===== */
@media (min-width: 1025px){
  .home .hero{
    margin:0 !important;
    padding:0 !important;
    position: relative !important;
    /* フルブリード（ヘッダーの下に隠れてもOKならこちら） */
    height: 100svh !important;
    height: 100dvh !important;
    height: 100vh  !important;
    min-height: 0 !important;
    overflow: hidden !important;
    background: transparent !important;
  }

  /* ★ これで“比率固定”や相対配置を打ち消す */
  .home .hero-slider{
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    aspect-ratio: auto !important;
    z-index: 0 !important;
  }

  .home .hero-slider .slide{
    position: absolute !important;
    inset: 0 !important;
    background-size: cover !important;               /* 余白なしで全面表示 */
    background-position: 50% 18% !important;         /* 上寄せ気味。必要なら 10〜25% で調整 */
    background-repeat: no-repeat !important;
    opacity: 0;                                       /* 既存のフェード用 */
    transition: opacity 1s ease-in-out;
  }

  /* 読みやすさ用の薄いオーバーレイ（画像の中だけ） */
  .home .hero::before{
    content:"" !important;
    position: absolute !important;
    inset: 0 !important;
    background: rgba(0,0,0,.40) !important;
    z-index: 1 !important;
  }

  /* テキストは画像の下ギリギリに配置（人物の顔に被らないように） */
  .home .hero .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    padding: 0 16px 10px !important;
    z-index: 2 !important;
    text-align: center !important;
  }

  /* 念のため container の中央寄せも固定 */
  .home .hero .container{
    width: 90% !important; max-width: 1100px !important;
    margin: 0 auto !important; padding: 0 !important;
    text-align: center !important;
  }
}

/* ▼“ヘッダーの下から始めたい（見える部分をピッタリ1画面）”ならこの1行だけに切替
.home .hero{ height: calc(100svh - var(--header-total)) !important; }
*/

/* === HERO：画像を“全体表示（トリミングなし）”にする切替 === */

/* A) .hero に .hero--contain を付けたとき（ページ全体） */
.home .hero.hero--contain .hero-slider .slide{
  background-size: contain !important;          /* ← 全体表示 */
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-color: #000 !important;            /* 余白は黒で目立たせない */
}
/* オーバーレイは画像領域の中だけに（見た目は今のまま暗め） */
.home .hero.hero--contain::before{ display: none !important; }
.home .hero.hero--contain .hero-slider::after{
  content:""; position:absolute; inset:0;
  background: rgba(0,0,0,.35); z-index:1; pointer-events:none;
}

/* B) 特定スライドだけ全体表示（.slide に .slide--contain を付ける） */
.home .hero-slider .slide.slide--contain{
  background-size: contain !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-color: #000 !important;
}

/* === PCだけ：固定ヘッダーに被らないようにヒーローを下げる === */
@media (min-width: 769px){
  .home .hero{
    /* ヘッダー高さぶんだけ開始位置を下げる */
    margin-top: var(--header-total) !important;

    /* その分だけ高さを引いて、結果として1画面ぴったり */
    height:     calc(100svh - var(--header-total)) !important;
    min-height: calc(100svh - var(--header-total)) !important;
    padding-top: 0 !important; /* 余計な内側余白はゼロ */
  }
  .home .hero .hero-text{ padding-top: 0 !important; } /* 念のため */
}

/* 変数が使えない環境向けフォールバック（必要なら数値調整） */
@supports not (height: calc(100svh - var(--header-total))){
  @media (min-width: 769px){
    .home .hero{
      margin-top: 120px !important;
      height:     calc(100svh - 120px) !important;
      min-height: calc(100svh - 120px) !important;
    }
  }
}

/* =========================================
   iPad 幅だけ：ヒーロー画像を“本当の全画面”に
   - 画像レイヤーは padding に影響されないよう 0〜0 固定
   - テキストだけヘッダー分下げる
========================================= */
@media (min-width: 768px) and (max-width: 1194px) {
  .hero{
    /* 画面いっぱい（dvh→svh→vh の順でフォールバック） */
    height: 100dvh !important;
    height: 100svh !important;
    height: 100vh  !important;

    /* 画像を縮める原因の padding を外す（テキスト側で付け直す） */
    margin-top: 0 !important;
    padding-top: 0 !important;

    /* 念のため */
    overflow: hidden;
    background-color: #000;
  }

  /* 背景（オーバーレイ＆スライダー）は常に 0〜0 で全面に */
  .hero::before,
  .hero .hero-slider{
    position: absolute;
    top: 0 !important; right: 0; bottom: 0; left: 0;
  }

  /* テキストだけヘッダー分を確保（--header-total 未設定時は 60px） */
  .hero .hero-text{
    padding-top: var(--header-total, 60px) !important;
  }
}

/* =========================================
   iPad系（縦768〜横1366あたり）もPCと同じく
   ヘッダーを跨いで“本当の全画面”ヒーローに
========================================= */
@media (min-width: 768px) and (max-width: 1366px) {
  .hero{
    /* 画面いっぱい（新→旧の順にフォールバック） */
    height: calc(100dvh + 1px) !important;
    height: calc(100svh + 1px) !important;
    height: calc(100vh  + 1px) !important;

    /* ヘッダーぶんだけ上に引き上げて、本文は下げる */
    margin-top: calc(-1 * var(--header-total)) !important;
    padding-top: var(--header-total) !important;

    min-height: 0 !important;   /* 以前の min-height を無効化 */
    overflow: hidden;
    background-color: #000;      /* 万一のスキマを目立たせない */
  }

  /* 背景レイヤーは常に全面 */
  .hero::before,
  .hero .hero-slider{
    position: absolute;
    inset: 0 !important;  /* top/right/bottom/left = 0 */
  }
}

/* ===== SPEED VARS ===== */
:root{
  --burger-speed: .22s;   /* ← 0.5s → 0.22s に短縮（お好みで .18〜.26） */
  --menu-speed:   .28s;   /* メニューのスライド速度 */
}

/* ハンバーガーの変形をキビキビさせる */
.hamburger span{
  transition:
    transform var(--burger-speed) cubic-bezier(.4,0,.2,1),
    opacity   calc(var(--burger-speed) - 0.04s) linear !important;
}

/* ====== SP（～1024px）：“右からだけ”出るオフキャンバスに統一 ====== */
@media (max-width:1024px){
  .nav{
    position: fixed !important;
    top: 0 !important; right: 0 !important; left: auto !important;
    width: min(84vw, 420px) !important;
    height: 100dvh !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 30px !important;
    padding: 5rem 1rem 1.25rem !important;
    margin: 0 !important;
    background: #fff !important;
    box-shadow: -12px 0 24px rgba(0,0,0,.12) !important;
    z-index: 10060 !important;

    /* ← ここで"右の画面外"に隠す（下から出す指定を完全無効化） */
    transform: translateX(100%) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: transform var(--menu-speed) cubic-bezier(.4,0,.2,1) !important, opacity var(--menu-speed) cubic-bezier(.4,0,.2,1) !important, visibility 0s linear var(--menu-speed) !important;
  }
  .nav.active{
    transform: translateX(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transition-delay: 0s,0s,0s !important;
  }

  /* “ヘッダーの下に落とす”旧指定を念のため打ち消し */
  .logo-nav .nav{ top: 0 !important; }
}

/* 背景の薄い暗幕（任意／JSで body.nav-open を付け外し） */
body.nav-open::after{
  content:"";
  position: fixed; inset: 0;
  background: rgba(0,0,0,.25);
  z-index: 10055;
}

/* ===== KEEP HAMBURGER VISIBLE OVER THE SLIDE-IN MENU ===== */
@media (max-width:1024px){
  /* .nav(=10060)より上に配置して、隠れないようにする */
  .header{ z-index: 10120 !important; }

  /* ハンバーガーを画面右上に“固定”＆最前面へ */
  .hamburger{
    position: fixed !important;
    right: max(12px, env(safe-area-inset-right)) !important;
    top:  calc(var(--header-login-h, 0px) + 10px) !important; /* 緑帯の下あたり */
    z-index: 10130 !important; /* .nav と暗幕より上 */
    pointer-events: auto !important;
  }

  /* メニューの中身がボタンの下に潜らないよう少し余白を足す（お好みで） */
  .nav{
    padding-top: calc(var(--header-login-h, 0px) + 64px) !important;
  }
}

/* ===== Mobile: hamburger is centered in the white header, language kept ===== */
@media (max-width:1024px){

  /* 白帯(.logo-nav)を基準に絶対配置できるように */
  .logo-nav{ position: relative !important; }

  /* ハンバーガー：白帯の中央に固定。常にメニューより前面 */
  .hamburger{
    position: absolute !important;
    top: 50% !important;
    right: max(12px, env(safe-area-inset-right)) !important;
    transform: translateY(-50%) !important;
    width: 40px; height: 40px;
    background: transparent !important;
    border: 0 !important; box-shadow: none !important;
    z-index: 11000 !important;     /* .nav(≒10060)より上 */
  }
  .hamburger span{ width: 26px; height: 3px; }

  /* ハンバーガーの“ぶんの場所”を確保して、言語セレクタと重ならないように */
  .logo-nav .nav-right{ padding-right: 56px !important; }

  /* 言語セレクタはヘッダーに表示のまま（被り防止だけする） */
  .logo-nav .lang-switch,
  .logo-nav .gtranslate_wrapper,
  .logo-nav .gt_switcher_wrapper{
    display: block !important;
    z-index: 10900;               /* ハンバーガーよりは下 */
  }

  /* ドロワーは右から。ボタンと視覚的に重なっても、ボタンが上に来る */
  .nav{
    transform: translateX(100%) !important;
    transition: transform .28s ease !important;
    z-index: 10060 !important;
    padding-top: calc(var(--header-login-h,34px) + var(--header-nav-h,56px) + 10px) !important;
  }
  .nav.active{ transform: translateX(0) !important; }
}

/* =========================================================
   FIX: ログイン時も含めて「ヘッダー直下にヒーロー」を常に密着
========================================================= */

/* 管理バー高さの変数（未ログイン=0 / ログイン時: PC=32px, SP=46px） */
:root { --adminbar-h: 0px; }
body.logged-in { --adminbar-h: 32px; }
@media (max-width: 782px) {
  body.logged-in { --adminbar-h: 46px; }
}

/* ログインバーを header 内で流す（固定を無効化して二重固定のズレを防止） */
.header-login-bar { position: static !important; margin: 0 !important; }

/* ヘッダーは管理バーの下に固定（既存の固定指定を統一） */
.header {
  position: fixed !important;
  top: var(--adminbar-h) !important;
  left: 0; right: 0;
  z-index: 10050; /* 既存値より上にしたい場合は調整 */
}

/* コンテンツ全体は「管理バー＋ヘッダー合計高さ」ぶんだけ下げる */
.site-main {
  padding-top: calc(var(--adminbar-h) + var(--header-total)) !important;
}

/* ただし“最初のヒーローだけ”はその余白を打ち消してヘッダー直下に密着 */
.site-main > .hero:first-child {
  margin-top: calc(-1 * (var(--adminbar-h) + var(--header-total))) !important;
}

/* ヒーローは全画面のまま（100svh）。余計な上パディング/マージンは撤廃 */
.hero {
  min-height: 100svh !important;
  height: 100svh !important;
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* （保険）上のどこかに margin-top:60px; 等が残っていても打ち消す */
@media (min-width: 769px) {
  .hero { margin-top: 0 !important; }
}

/* ==== HAMBURGER: 正確な「×」にする上書き ==== */
.header .hamburger{
  position: relative;
  width: 38px; height: 38px;
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0 !important; /* 既存のgapを無効化 */
}
.header .hamburger span{
  position: absolute;
  left: 6px; right: 6px;
  height: 3px; background: #333;
  border-radius: 2px;
  top: 50%; transform: translateY(-50%);
  transform-origin: center;
  transition: transform .28s cubic-bezier(0.77,0,0.175,1), opacity .28s ease;
}
.header .hamburger span:nth-child(1){ top: calc(50% - 8px); }
.header .hamburger span:nth-child(2){ top: 50%; }
.header .hamburger span:nth-child(3){ top: calc(50% + 8px); }

.header .hamburger.active span:nth-child(1){
  top: 50%; transform: translateY(-50%) rotate(45deg);
}
.header .hamburger.active span:nth-child(2){
  opacity: 0; transform: translateY(-50%) scaleX(.6);
}
.header .hamburger.active span:nth-child(3){
  top: 50%; transform: translateY(-50%) rotate(-45deg);
}

@media (min-width: 1025px){
  .hamburger { display: none !important; }
}

/* 任意の保険：モバイルのドロワー内に言語セレクターが紛れ込んだら隠す */
@media (max-width: 1024px){
  .nav .gtranslate_wrapper,
  .nav .gt_switcher_wrapper,
  .nav .header-lang,
  .nav .lang-switch,
  .nav #gtranslate_selector {
    display: none !important;
  }
}

/* ▼ ログイン画面だけ：フッター下の空白をゼロにして底に固定 */
@supports selector(body:has(*)) {
  /* ログイン系フォームが1つでもあるページだけ有効化 */
  body:has(.ur-frontend-form),
  body:has(form#loginform),
  body:has(.wpum-login-form) {
    min-height: 100svh;
    display: flex;
    flex-direction: column;
  }
  body:has(.ur-frontend-form) .site-main,
  body:has(form#loginform) .site-main,
  body:has(.wpum-login-form) .site-main {
    flex: 1 0 auto;
    padding-bottom: 0 !important; /* 念のため */
  }
  /* 既存の “フォームの下に 120px 余白” を打ち消し */
  body:has(.ur-frontend-form) .ur-frontend-form,
  body:has(form#loginform) #loginform,
  body:has(.wpum-login-form) .wpum-login-form {
    margin-bottom: 0 !important;
  }
  /* フッターを最下部へ */
  body:has(.ur-frontend-form) .footer,
  body:has(form#loginform) .footer,
  body:has(.wpum-login-form) .footer {
    margin-top: auto !important;
  }
}

/* ==== FINAL OVERRIDE: header最上部 / heroと隙間ゼロ / 画面いっぱい ==== */

/* ヘッダーは“まとめて”固定。ログインバーは中で流す */
.header { position: fixed !important; top: 0 !important; left: 0; right: 0; z-index: 2000 !important; }
.header-login-bar { position: static !important; }  /* ← 途中にあった fixed/top:44px を無効化 */

/* ヒーロー：ヘッダー分だけ中身を下げ、残りを全て占有 */
.hero{
  margin-top: 0 !important;                            /* 旧: margin-top:60px を打ち消し */
  padding-top: var(--header-total, 96px) !important;   /* ヘッダー実高ぶんだけ下げる */
  min-height: calc(100dvh - var(--header-total, 96px)) !important;
  min-height: calc(100svh - var(--header-total, 96px)) !important;
  min-height: calc(100vh  - var(--header-total, 96px)) !important;
  height: auto !important;
  overflow: hidden;
}
.hero .container{ padding: 0 !important; margin: 0 !important; } /* 余白で白帯が出ないように */

/* ヒーローの下に通常コンテンツが来るページは自動で余白ゼロにする（ホーム想定） */
.home .site-main, .front-page .site-main { padding-top: 0 !important; }

/* ナビのドロワー等が被ってもヘッダーが最前面になるよう保険 */
.nav{ z-index: 1500; }

/* ===== 管理バーを一切考慮しない（レイアウトを押し下げさせない） ===== */
/* WP が html に入れる margin-top:32/46px を無効化 */
html { margin-top: 0 !important; }
@media (max-width: 782px){ html { margin-top: 0 !important; } }

/* 管理バーは上に“重ねる”だけ（ページを押し下げない） */
#wpadminbar { position: fixed !important; top: 0; }

/* ヘッダーは常に画面の一番上から */
.header { position: fixed; top: 0 !important; left: 0; width: 100%; }

/* hero はヘッダー直下から開始し、残りをぴったり埋める（管理バーは無視） */
.hero{
  margin-top: 0 !important;
  padding-top: var(--header-total) !important;            /* ← ヘッダー分だけ下げる */
  min-height: calc(100svh - var(--header-total)) !important; /* ← 1画面−ヘッダー高 */
  height: auto !important;
  overflow: hidden;
}

/* ================================
   HERO：全端末で「ヘッダー直下から残りを全部」
   ＋ テキスト/ボタンは中央揃え
   管理バーは完全に無視（画面に重ねるだけ）
================================ */

/* 管理バーは押し下げさせない（すでに入っていれば重複OK） */
html { margin-top: 0 !important; }
@media (max-width: 782px){ html { margin-top: 0 !important; } }
#wpadminbar { position: fixed !important; top: 0; }

/* 1) ヒーロー本体：全画面表示（ヘッダー分だけ差し引く） */
.hero{
  /* ブロック表示 */
  display: block !important;

  /* ヘッダーの下から開始（余白ゼロ） */
  margin-top: 0 !important;
  padding-top: var(--header-total) !important;
  padding-bottom: env(safe-area-inset-bottom, 0); /* iOS下部の安全域だけ確保 */
  height: auto !important;

  /* 画面の残りをピッタリ埋める（対応の広い順に上書き） */
  min-height: calc(100vh  - var(--header-total)) !important;
  min-height: calc(100svh - var(--header-total)) !important;
  min-height: calc(100dvh - var(--header-total)) !important;

  overflow: hidden;
}

/* 2) テキスト/ボタンは中央に（PC/タブレットのみ） */
@media (min-width: 769px){
  .hero .hero-text{
    text-align: center !important;
    margin: 0 auto !important;
    display: grid !important;
    gap: 1rem;
  }
  .hero .hero-buttons{
    display: flex !important;
    justify-content: center !important;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
}

/* 3) 背景スライダーは常に全面に敷く */
.hero-slider{
  position: absolute !important;
  inset: 0 !important;
  height: auto !important;
}

/* 4) 既存のモバイル向け高さ/余白指定を打ち消す（タブレット含む） */
@media (max-width: 1024px){
  .hero{
    padding-top: var(--header-total) !important;
  }
}
@media (max-width: 768px){
  .hero{
    min-height: calc(100vh  - var(--header-total)) !important;
    min-height: calc(100svh - var(--header-total)) !important;
    min-height: calc(100dvh - var(--header-total)) !important;
    padding-top: var(--header-total) !important;
    padding-bottom: env(safe-area-inset-bottom, 0) !important;
  }
}

/* =========================================================
   FINAL OVERRIDE: Hero = 画面高 − ヘッダー実寸（スマホ/タブレット）
========================================================= */
:root {
  /* JSが上書きしますが、念のためのフォールバック */
  --header-total: calc(var(--header-login-h, 34px) + var(--header-nav-h, 56px));
}

/* まず余計なマージンを確実に消す */
.hero { margin-top: 0 !important; }

@media (max-width: 1024px) {
  .hero {
    /* 画面の見えている高さ（--vh）からヘッダーの実寸を引いた分だけに */
    height: calc(var(--vh, 1vh) * 100 - var(--header-total)) !important;
    min-height: calc(var(--vh, 1vh) * 100 - var(--header-total)) !important;

    /* 旧スタイルの影響排除 */
    padding-top: var(--header-total) !important;
    padding-bottom: 0 !important;

    display: block !important;
    overflow: hidden !important;
  }

  /* 背景は全面フィットさせる */
  .hero-slider { position: absolute !important; inset: 0 !important; }
  .hero-slider .slide {
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background-size: cover !important;
    background-position: center !important;
  }

  /* テキスト＆ボタンは下ギリギリに配置 */
  .hero .hero-text {
    margin: 0 auto !important;
    width: min(1000px, 92vw) !important;
    text-align: center !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    min-height: 0 !important; /* 旧100%指定を打ち消す */
    padding: 0 16px 10px !important;
  }
  .hero .hero-buttons { justify-content: center !important; }
}

/* ================================
   UNIQUE STRENGTHS：SP溢れ対策パッチ
   （CSSの一番最後に追記）
================================ */
@media (max-width: 768px){

  /* 枠の内側に必ず収める（左右に少し余白） */
  .strengths-circle-container{ padding-inline: 12px; }

  .strength-circle{
    width: 100%;
    max-width: 560px;          /* 余裕を持たせて可変 */
    height: auto;
    border-radius: 16px;
    padding: 1.2rem 1rem;
    box-sizing: border-box;
    overflow: hidden;          /* 念のため */
    -webkit-text-size-adjust: 100%;
  }

  /* タイトルは“2行まで＋省略”を確実に（iOS対応） */
  .strength-circle h3,
  .strength-title{
    max-width: 100%;
    min-width: 0;              /* ★ flex 子のはみ出しを許さない */
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.4;
    display: -webkit-box;      /* ★ 行数制限 */
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    white-space: normal;
  }
  .strength-title-inner{
    display: block;
    max-width: 100%;
    overflow-wrap: anywhere;    /* 長語・記号（+ 等）での折返し */
    word-break: break-word;     /* Safari/Fallback 用 */
    line-break: strict;
    -webkit-text-size-adjust: 100%;
  }

  /* 本文も安全に折返し */
  .strength-circle p{
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  /* 乗算記号は非表示のままでOK */
  .x-symbol{ display: none; }
}

/* 念のため（SP/PC共通）：flex 子の横はみ出し保険 */
.strength-circle h3,
.strength-title{ min-width: 0; }

:root{ --fixed-top: 0px; --vh: 1vh; }

/* スマホでヒーローを確実に全画面表示＋ヘッダー分オフセット */
@media (max-width:768px){
  .hero{
    position: relative !important;
    margin-top: var(--fixed-top) !important;
    min-height: calc(var(--vh, 1vh)*100 - var(--fixed-top)) !important;
    display: block !important;
    overflow: hidden !important;
  }
  .hero-slider{ position:absolute !important; inset:0 !important; z-index:0; }
  .hero-slider .slide{
    position:absolute !important; inset:0 !important;
    background-size: cover !important;
    background-position: 50% 22% !important; /* 好みで 15〜30% */
    background-repeat: no-repeat !important;
  }
  .hero::before{
    content:""; position:absolute; inset:0; z-index:1;
    background: rgba(0,0,0,.25);
  }
  /* ←ここが今回の“左寄り”の犯人。margin:0 をやめ、中央寄せを明示 */
  .hero .container{
    position: relative; z-index:2;
    margin: 0 auto !important;                 /* 中央 */
    padding-inline: clamp(16px,4vw,24px) !important;
    text-align: center !important;
  }
  .hero h2,.hero p{ margin-left:auto; margin-right:auto; }
}

/* ヒーロー直下の余白ダブり防止（テーマによっては不要） */
.home .site-main, .front-page .site-main { padding-top:0 !important; }

/* アンカーずれ防止（任意） */
[id]{ scroll-margin-top: var(--fixed-top); }



/* iPhone SE（375×～700）縦向きだけ、背景の表示位置を最上部へ */
@media only screen and (max-width: 375px) and (max-height: 700px) and (orientation: portrait){
  .hero-slider .slide{
    background-position: center top !important; /* 上寄せ */
    background-size: cover !important;          /* 余白を出さない */
    background-repeat: no-repeat !important;
  }
}

/* iPhone SE（375×〜700）縦向きだけ：背景を下にずらして顔をヘッダー下に出す */
@media only screen and (max-width: 375px) and (max-height: 700px) and (orientation: portrait){
  /* 微調整用のオフセット。必要なら 90～140px くらいで調整してください */
  :root{ --se-face-offset: 120px; }

  .hero-slider .slide{
    /* ヘッダー分だけ背景を下へ（＝画像の上側が下に降りて見える） */
    background-position: center var(--se-face-offset) !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
  }
}

/* ===== Awards：見た目そのまま＋全文表示 ===== */

/* 中央カラムが潰れないよう 1fr に戻す（縦並びの原因を解消） */
.awards-2025__item{
  grid-template-columns:
    minmax(0, var(--wreathW))  /* left */
    1fr                         /* ★ center: 最小が0にならない */
    minmax(0, var(--wreathW))  /* right */
  !important;
}

/* テキスト容器は普通に広がるように（max-content をやめる） */
.awards-2025__copy{
  min-width: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  justify-self: center !important;
  text-align: center !important;
}

/* 見出し／本文：省略や縦箱を解除して自然に改行＝全文表示 */
.awards-2025__copy h3,
.awards-2025__copy p{
  white-space: normal !important;      /* nowrap を解除 */
  overflow: visible !important;
  text-overflow: clip !important;      /* … を消す */
  word-break: normal !important;
  overflow-wrap: anywhere !important;  /* 英語の長語も安全に折返し */
  -webkit-line-clamp: unset !important;
  display: block !important;
}

/* スマホも同じ見た目で全文表示（字が大きすぎる場合だけ少し縮める） */
@media (max-width: 768px){
  .awards-2025__copy h3{ font-size: clamp(1rem, 3.6vw, 1.2rem) !important; }
  .awards-2025__copy p { font-size: clamp(0.9rem, 3.2vw, 1rem) !important; }
}

/* ===== Awards：中央テキストを横書き・全文表示に固定 ===== */

/* 中央カラムを十分広く確保（最小 220px） */
.awards-2025__item{
  grid-template-columns:
    minmax(0, var(--wreathW))
    minmax(220px, 1fr)      /* ★ここを確保 */
    minmax(0, var(--wreathW))
  !important;
}

/* “1文字幅”に潰れる原因（width:max-content）を打ち消し */
.awards-2025__item .awards-2025__copy{
  width: auto !important;
  min-width: 0 !important;
  max-width: none !important;
  justify-self: center !important;
  text-align: center !important;

  /* 念のため：横書きを明示 */
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
}

/* 見出し/本文は省略せず自然に折り返す（…や縦積みを禁止） */
.awards-2025__item .awards-2025__copy h3,
.awards-2025__item .awards-2025__copy p{
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  -webkit-line-clamp: unset !important;
  display: block !important;
}

/* スマホでも同じ。文字が大きすぎる場合だけ少し自動縮小 */
@media (max-width: 768px){
  .awards-2025__item{
    grid-template-columns:
      minmax(0, var(--wreathW))
      minmax(200px, 1fr)
      minmax(0, var(--wreathW))
    !important;
  }
  .awards-2025__item .awards-2025__copy h3{
    font-size: clamp(1rem, 3.6vw, 1.2rem) !important;
  }
  .awards-2025__item .awards-2025__copy p{
    font-size: clamp(0.9rem, 3.2vw, 1rem) !important;
  }
}

/* ========================================
   【最優先】スマホ専用：ヒーローのテキストとボタン配置
   ※他のスタイルを上書きするため、ファイルの最後に配置
======================================== */
@media (max-width: 768px){
  /* ヒーローコンテナの設定 */
  body .hero,
  .hero{
    justify-content: flex-end !important;
    display: block !important;
  }
  
  /* 背景画像の位置調整（顔が見えやすいように上寄せ） */
  body .hero-slider .slide,
  .hero-slider .slide{
    background-position: center 22% !important;
  }
  
  /* テキストブロックの配置（詳細度を上げて確実に適用） */
  body .hero .hero-text,
  .hero .hero-text,
  .hero .container .hero-text{
    position: absolute !important;
    inset: 0 !important;
    display: grid !important;
    align-items: end !important;
    justify-items: center !important;
    align-content: end !important;
    z-index: 2 !important;
    text-align: center !important;
    color: #fff !important;
    text-shadow: 0 2px 6px rgba(0,0,0,.35) !important;
    padding: 0 20px 80px !important; /* 長方形ボタンの高さ分調整 */
    margin: 0 auto !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  
  /* テキストの子要素も中央配置 */
  body .hero .hero-text h2,
  body .hero .hero-text p,
  .hero .hero-text h2,
  .hero .hero-text p{
    margin-left: auto !important;
    margin-right: auto !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  
  /* ボタンエリアの配置（詳細度を上げて確実に適用） */
  body .hero .hero-buttons,
  .hero .hero-buttons{
    position: absolute !important;
    left: 0 !important;
    right: 0 !important;
    bottom: calc(8px + env(safe-area-inset-bottom)) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 0.75rem !important;
    padding: 0 20px !important; /* 左右均等な余白(20px) */
    margin: 0 auto !important;
    flex-wrap: nowrap !important; /* 横並び固定 */
    width: 100% !important;
  }
  
  /* スマホ専用：PCと同じ長方形ボタンスタイル（透過） */
  body .hero .hero-buttons .btn,
  .hero .hero-buttons .btn{
    display: inline-block !important;
    padding: 0.7rem 1.2rem !important;
    background: rgba(0, 184, 138, 0.85) !important; /* 85%の不透明度（15%透過） */
    backdrop-filter: blur(4px) !important; /* 背景ぼかし効果 */
    -webkit-backdrop-filter: blur(4px) !important;
    color: #fff !important;
    border-radius: 6px !important;
    font-size: 0.9rem !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    line-height: 1.3 !important;
    transition: all 0.3s !important;
    text-align: center !important;
    min-width: 140px !important;
    width: auto !important;
    height: auto !important;
    max-width: none !important;
    flex-shrink: 1 !important;
  }
  
  body .hero .hero-buttons .btn br,
  .hero .hero-buttons .btn br{
    display: block !important; /* 改行を有効に */
  }
  
  body .hero .hero-buttons .btn span,
  .hero .hero-buttons .btn span{
    display: block !important;
    font-size: 0.75rem !important;
    font-weight: 400 !important;
    letter-spacing: normal !important;
  }
  
  body .hero .hero-buttons .btn:hover,
  .hero .hero-buttons .btn:hover{
    background: rgba(0, 159, 119, 0.9) !important; /* ホバー時は少し濃く */
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
  }
  
  /* スマホ専用：テキストサイズ調整 */
  body .hero .hero-text h2,
  .hero .hero-text h2{
    font-size: clamp(1.35rem, 5.2vw, 1.75rem) !important;
    line-height: 1.3 !important;
    margin-bottom: .5rem !important;
  }
  
  body .hero .hero-text p,
  .hero .hero-text p{
    font-size: .92rem !important;
    line-height: 1.5 !important;
    margin-bottom: .4rem !important;
  }
}

/* ========================================
   スマホ専用設定の再適用（念のため2回目）
======================================== */
@media (max-width: 768px){
  body .hero .hero-text{
    padding-bottom: 80px !important; /* 長方形ボタンの高さ分 */
    padding-left: 20px !important;
    padding-right: 20px !important;
  }
  
  body .hero .hero-buttons{
    padding-left: 12px !important;
    padding-right: 12px !important;
    flex-wrap: nowrap !important; /* 横並び固定 */
    gap: 0.5rem !important;
  }
  
  body .hero .hero-buttons .btn{
    min-width: 130px !important;
    padding: 0.7rem 1rem !important;
    font-size: 0.85rem !important;
    flex: 1 1 auto !important;
    max-width: 45% !important; /* 画面幅の45%まで */
  }
  
  body .hero .hero-buttons .btn span{
    font-size: 0.7rem !important;
  }
}
