/* ===== SEARCH BOX ===== */
.header-search {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 20px;
  overflow: hidden;
  margin-right: 8px;
  transition: background .2s;
}
.header-search:focus-within {
  background: rgba(255,255,255,0.22);
}
.header-search input {
  background: transparent;
  border: none;
  outline: none;
  color: white;
  font-size: 0.78rem;
  padding: 6px 12px;
  width: 160px;
  font-family: inherit;
}
.header-search input::placeholder { color: rgba(255,255,255,0.6); }
.header-search button {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px 10px 6px 4px;
  color: white;
  display: flex;
  align-items: center;
}
.header-search button:hover { opacity: 0.8; }
header.solid .header-search {
  background: rgba(0,60,130,0.08);
  border: 1px solid rgba(0,80,160,0.2);
}
header.solid .header-search input { color: var(--navy); }
header.solid .header-search input::placeholder { color: rgba(0,60,130,0.4); }
header.solid .header-search button { color: var(--navy); }
@media (max-width: 768px) {
  .header-search { display: none; }
}

/* ===== CSS VARIABLES ===== */
:root {
  --sky:       #00B4D8;
  --sky-light: #90E0EF;
  --sky-pale:  #CAF0F8;
  --sky-dark:  #0077B6;
  --navy:      #023E8A;
  --bg:        #F0F9FF;
  --text:      #1a2e3b;
  --muted:     #5a7a8a;
  --radius:    12px;
  --shadow:    0 4px 20px rgba(0,120,180,0.10);
  --shadow-lg: 0 8px 40px rgba(0,120,180,0.18);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Noto Sans JP', sans-serif; background: var(--bg); color: var(--text); line-height: 1.7; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
section { padding: 88px 24px; }

/* ===== HEADER ===== */
header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  transition: background .35s, box-shadow .35s;
}
header.solid,
header.transparent {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(12px);
  box-shadow: 0 2px 20px rgba(0,120,180,0.12);
}
.header-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 32px;
}
.logo-wrap img { height: 65px; width: auto; transition: filter .3s; }
.header-tel { font-size: 1rem; font-weight: 700; color: var(--sky-dark); letter-spacing: 0.04em; text-align: right; transition: color .3s; }
.header-tel small { font-size: 0.73rem; color: var(--muted); display: block; transition: color .3s; }

/* ===== NAV ===== */
nav { background: var(--sky-dark); }
header.transparent nav { background: rgba(0,50,100,0.55); backdrop-filter: blur(6px); }
.nav-inner { max-width: 1280px; margin: 0 auto; display: flex; }
.nav-inner a {
  display: block; padding: 7px 22px;
  color: #fff; font-size: 0.86rem; font-weight: 500; letter-spacing: 0.06em;
  position: relative; transition: background .2s;
}
.nav-inner a::after {
  content: ''; position: absolute; bottom: 0; left: 50%; right: 50%;
  height: 3px; background: var(--sky-light); transition: left .25s, right .25s;
}
.nav-inner a:hover, .nav-inner a.active { background: rgba(255,255,255,0.1); }
.nav-inner a:hover::after, .nav-inner a.active::after { left: 12px; right: 12px; }

/* ===== MEGA MENU ===== */
nav { position: relative; }
.nav-has-mega { position: relative; }
.nav-has-mega > a::before { content: ' ▾'; font-size: 0.7rem; vertical-align: middle; }
.mega-menu {
  display: none; position: absolute; top: 100%; left: 0;
  padding-top: 6px;
  width: max-content; min-width: 580px;
  z-index: 1000;
}
.mega-menu-inner {
  background: rgba(18,28,48,0.96);
  box-shadow: 0 10px 40px rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  overflow: hidden;
  display: flex; align-items: stretch; width: 100%;
}
.nav-has-mega:hover .mega-menu { display: block; }
.mega-menu-left {
  width: 130px; flex-shrink: 0;
  padding: 18px 16px;
  border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
  background: rgba(0,0,0,0.15);
}
.mega-menu-left-title {
  font-size: 1rem; font-weight: 800; color: white; line-height: 1.4; margin-bottom: 4px;
}
.mega-menu-left-en { font-size: 0.65rem; color: var(--sky-light); letter-spacing: .1em; opacity: 0.6; }
.mega-menu-right {
  flex: 1; padding: 10px 20px;
  display: grid; grid-template-columns: 1fr 1fr; align-content: start;
}
.mega-menu-section-label {
  grid-column: 1/-1; font-size: 0.6rem; font-weight: 700;
  letter-spacing: .12em; color: var(--sky-light);
  padding: 8px 0 3px; opacity: 0.6;
  border-bottom: 1px solid rgba(255,255,255,0.1); margin-bottom: 2px;
}
.mega-menu a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 10px; text-decoration: none; border: none;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  transition: background .18s;
}
.mega-menu a::after { display: none; }
.mega-menu a:hover { background: rgba(255,255,255,0.07); }
.mm-text .mm-title { font-size: 0.84rem; font-weight: 700; color: white; margin-bottom: 1px; }
.mm-text .mm-en { font-size: 0.62rem; color: var(--sky-light); letter-spacing: .06em; opacity: 0.6; }
.mm-arrow { color: var(--sky-light); font-size: 0.75rem; opacity: 0.6; flex-shrink: 0; margin-left: 8px; }
@media (max-width: 768px) {
  .mega-menu { display: none !important; }
  .nav-has-mega > a::before { content: '' !important; }
  .nav-has-mega { position: relative; }
}

/* ===== HERO (top page) ===== */
.hero {
  position: relative; height: 520px; min-height: 420px; overflow: hidden;
  margin-top: 80px;
}
.slides-track {
  display: flex; height: 100%;
  transition: transform 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}
.slide { min-width: 100%; height: 100%; position: relative; overflow: hidden; }

.slide-photo {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  transform: scale(1.0);
  transition: transform 9s linear;
}
.slide.is-active .slide-photo { transform: scale(1.07); }

.slide-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(
    110deg,
    rgba(1, 22, 56, 0.90) 0%,
    rgba(0, 55, 115, 0.70) 35%,
    rgba(0, 100, 170, 0.28) 62%,
    rgba(0, 150, 210, 0.05) 100%
  );
}

/* Slide content — left-aligned */
.slide-content {
  position: absolute; left: 8%; top: 50%; transform: translateY(-50%);
  z-index: 2; max-width: 660px;
  opacity: 0;
}
.slide.is-active .slide-content {
  animation: slideUp 0.85s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.15s forwards;
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(calc(-50% + 30px)); }
  to   { opacity: 1; transform: translateY(-50%); }
}

.slide-badge {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 14px;
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.18em;
  color: rgba(255,255,255,0.7); text-transform: uppercase;
}
.slide-badge-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sky); flex-shrink: 0; }

.slide-content h2 {
  font-size: clamp(1.7rem, 3.6vw, 3.0rem);
  font-weight: 900; line-height: 1.2; color: white;
  margin-bottom: 16px; letter-spacing: -0.01em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.28);
}
.slide-content h2 .cyan { color: var(--sky-light); }

.slide-content p {
  font-size: 0.86rem; line-height: 1.85;
  color: rgba(255,255,255,0.82); margin-bottom: 28px;
  text-shadow: 0 1px 8px rgba(0,0,0,0.25);
}

.slide-btns { display: flex; gap: 12px; flex-wrap: wrap; }

/* ===== SLIDE FOOTER BAR ===== */
.slide-footer {
  position: absolute; bottom: 22px; left: 8%; right: 8%;
  display: flex; align-items: flex-end; justify-content: space-between; z-index: 10;
}
.slide-lines { display: flex; gap: 10px; align-items: center; }
.slide-line {
  height: 2px; width: 42px; background: rgba(255,255,255,0.28);
  border-radius: 1px; cursor: pointer; transition: background .35s, width .35s;
}
.slide-line.active { background: var(--sky); width: 58px; }

.scroll-hint {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  font-size: 0.66rem; letter-spacing: 0.22em; color: rgba(255,255,255,0.48);
  text-transform: uppercase;
}
.scroll-hint-line {
  width: 1px; height: 52px; background: linear-gradient(to bottom, rgba(255,255,255,0.55), transparent);
  animation: scrollPulse 2.2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%   { opacity: 0; transform: scaleY(0);   transform-origin: top; }
  40%  { opacity: 1; transform: scaleY(1);   transform-origin: top; }
  70%  { opacity: 1; transform: scaleY(1);   transform-origin: bottom; }
  100% { opacity: 0; transform: scaleY(0.1); transform-origin: bottom; }
}

.slide-counter {
  font-size: 0.8rem; letter-spacing: 0.1em;
  color: rgba(255,255,255,0.55);
}
.slide-counter .cur { font-size: 1.15rem; font-weight: 900; color: white; margin-right: 2px; }

/* ===== BUTTONS ===== */
.btn-fill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 11px 24px; background: var(--sky); color: white;
  border-radius: 4px; font-weight: 700; font-size: 0.85rem;
  transition: background .2s, transform .2s; white-space: nowrap;
}
.btn-fill:hover { background: #008cb5; transform: translateY(-2px); }
.btn-line {
  display: inline-block; padding: 10px 24px;
  border: 2px solid rgba(255,255,255,0.65); color: white;
  border-radius: 4px; font-weight: 600; font-size: 0.85rem;
  transition: background .2s, border-color .2s, transform .2s; white-space: nowrap;
}
.btn-line:hover { background: rgba(255,255,255,0.1); border-color: white; transform: translateY(-2px); }
.btn-blue {
  display: inline-block; padding: 13px 32px;
  background: linear-gradient(135deg, var(--sky-dark), var(--sky));
  color: white; border-radius: 50px; font-weight: 700; font-size: 0.95rem;
  box-shadow: 0 4px 16px rgba(0,120,180,0.28);
  transition: transform .2s, box-shadow .2s;
}
.btn-blue:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,120,180,0.36); }

/* ===== PAGE HERO (sub pages) ===== */
.page-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--sky-dark) 55%, var(--sky) 100%);
  padding: 36px 24px 38px; margin-top: 120px;
  position: relative; overflow: hidden;
}
.page-hero::after {
  content: ''; position: absolute; right: -80px; top: -80px;
  width: 380px; height: 380px; border-radius: 50%; background: rgba(255,255,255,0.05);
}
.page-hero::before {
  content: ''; position: absolute; left: -40px; bottom: -60px;
  width: 200px; height: 200px; border-radius: 50%; background: rgba(255,255,255,0.04);
}
.page-hero-inner { max-width: 1100px; margin: 0 auto; position: relative; z-index: 1; }
.breadcrumb { font-size: 0.78rem; color: rgba(255,255,255,0.9); margin-bottom: 8px; letter-spacing: 0.06em; white-space: nowrap; }
.breadcrumb a { color: rgba(255,255,255,0.85); text-decoration: underline; text-underline-offset: 2px; transition: color .2s; }
.breadcrumb a:hover { color: white; }
.breadcrumb span { margin: 0 8px; }
.breadcrumb .nav-has-mega { display: inline-block; }
.page-hero h1 { font-size: clamp(1.4rem, 2.8vw, 2.0rem); font-weight: 900; color: white; white-space: nowrap; }
.page-hero .page-en { font-size: 0.7rem; letter-spacing: 0.2em; color: var(--sky-light); text-transform: uppercase; margin-top: 5px; }

/* ===== SECTION HEADER ===== */
.section-header { text-align: center; margin-bottom: 56px; }
.section-label {
  display: inline-block; padding: 4px 18px;
  background: var(--sky-pale); color: var(--sky-dark);
  border-radius: 50px; font-size: 0.76rem; font-weight: 700; letter-spacing: 0.12em;
  margin-bottom: 14px;
}
.section-header h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 800; color: var(--navy); margin-bottom: 10px; }
.section-header p { color: var(--muted); font-size: 0.93rem; }
.divider { width: 50px; height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--sky-dark), var(--sky-light)); margin: 18px auto 0; }

/* On-dark section headers — .on-dark is placed ON .section-header itself */
.on-dark .section-label { background: rgba(255,255,255,0.18); color: white; }
.on-dark h2 { color: white !important; }
.on-dark p { color: rgba(255,255,255,0.82) !important; }
.on-dark .divider { background: rgba(255,255,255,0.4) !important; }

/* ===== CARDS ===== */
.card {
  background: white; border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 34px 30px;
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }

/* Grid layouts */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; max-width: 940px; margin: 0 auto; }
.grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; max-width: 1100px; margin: 0 auto; }

/* ===== SERVICE CARD ===== */
.service-card {
  background: white;
  border-radius: var(--radius);
  padding: 36px 32px 32px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05), 0 4px 20px rgba(0,80,160,0.06);
  border: 1px solid rgba(0,120,180,0.09);
  transition: transform .28s, box-shadow .28s;
  position: relative;
  overflow: hidden;
}
.service-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--sky) 0%, var(--navy) 100%);
  border-radius: 4px 0 0 4px;
}
.service-card:hover { transform: translateY(-5px); box-shadow: 0 12px 36px rgba(0,80,160,0.13); }
.service-num {
  font-size: 0.68rem; font-weight: 700; letter-spacing: .18em;
  color: var(--sky); margin-bottom: 18px; text-transform: uppercase;
}
.service-icon {
  width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
  background: linear-gradient(135deg, #e8f4fb, #cce8f4);
  border-radius: 12px;
}
.service-icon svg { fill: none; stroke: var(--sky-dark); stroke-width: 1.7; }
.service-card h3 {
  font-size: 1.05rem; font-weight: 700; color: var(--navy);
  margin-bottom: 12px; line-height: 1.5;
}
.service-card p { color: var(--muted); font-size: 0.88rem; line-height: 1.9; }
.service-card .card-link {
  display: inline-flex; align-items: center; gap: 5px;
  margin-top: 22px; font-size: 0.82rem; font-weight: 600;
  color: var(--sky-dark); text-decoration: none;
  border-bottom: 1px solid rgba(0,119,182,0.3);
  padding-bottom: 2px;
  transition: gap .2s, color .2s, border-color .2s;
}
.service-card .card-link:hover { gap: 9px; color: var(--navy); border-color: var(--navy); }
.tag { display: inline-block; margin-top: 18px; margin-right: 6px; padding: 4px 12px; background: var(--sky-pale); color: var(--sky-dark); border-radius: 50px; font-size: 0.76rem; font-weight: 600; }

/* ===== PHIL CARD ===== */
.phil-card { background: var(--bg); border-radius: var(--radius); padding: 36px 32px; border-top: 4px solid var(--sky); box-shadow: var(--shadow); transition: transform .25s, box-shadow .25s; }
.phil-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.phil-icon { width: 52px; height: 52px; border-radius: 50%; background: linear-gradient(135deg, var(--sky), var(--sky-dark)); display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.phil-icon svg { fill: none; stroke: white; stroke-width: 2; }
.phil-card h3 { font-size: 1.15rem; font-weight: 700; color: var(--navy); margin-bottom: 12px; }
.phil-card p { color: var(--muted); font-size: 0.91rem; line-height: 1.88; }

/* ===== RESULT CARD ===== */
.result-card { background: var(--bg); border-radius: var(--radius); padding: 32px 24px; box-shadow: var(--shadow); text-align: center; transition: transform .25s; }
.result-card:hover { transform: translateY(-4px); }
.result-icon { width: 70px; height: 70px; border-radius: 50%; background: linear-gradient(135deg, var(--sky), var(--sky-dark)); display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.result-icon svg { fill: none; stroke: white; stroke-width: 1.8; }
.result-card h3 { font-size: 1rem; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.result-card p { color: var(--muted); font-size: 0.88rem; line-height: 1.8; }

/* ===== NEWS ===== */
.news-list { max-width: 860px; margin: 0 auto; display: flex; flex-direction: column; gap: 0; border: 1px solid rgba(0,100,160,0.18); border-radius: 12px; padding: 8px 28px; background: #fff; }
.news-item { display: flex; align-items: center; gap: 18px; padding: 16px 0; background: transparent; border-bottom: 1px dotted rgba(0,100,160,0.5); transition: background .2s; }
.news-item:last-child { border-bottom: none; }
.news-item:hover { background: transparent; }
.news-date { font-size: 0.77rem; font-weight: 500; color: var(--sky-dark); min-width: 82px; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.news-badge { display: inline-block; padding: 3px 12px; font-size: 0.68rem; font-weight: 700; background: var(--sky-dark); color: #fff; border-radius: 20px; white-space: nowrap; flex-shrink: 0; min-width: 68px; text-align: center; }
.news-text { font-size: 0.88rem; line-height: 1.6; }

/* ===== RECRUIT CARD ===== */
.recruit-card { background: white; border: 1px solid rgba(0,120,180,0.12); border-radius: var(--radius); padding: 32px 28px; box-shadow: 0 2px 12px rgba(0,80,160,0.07); transition: box-shadow .2s; }
.recruit-card:hover { box-shadow: 0 6px 24px rgba(0,80,160,0.12); }
.recruit-card h3 { font-size: 1.05rem; font-weight: 700; color: var(--navy); margin-bottom: 18px; }
.recruit-row { display: flex; gap: 10px; margin-bottom: 9px; font-size: 0.86rem; }
.recruit-label { min-width: 70px; color: var(--sky-dark); font-size: 0.78rem; font-weight: 600; }
.recruit-val { color: var(--muted); line-height: 1.6; }

/* ===== CONTACT FORM ===== */
.form-group { margin-bottom: 22px; }
.form-group label { display: block; font-size: 0.87rem; font-weight: 600; color: var(--navy); margin-bottom: 8px; }
.req { color: #e05; font-size: 0.73rem; margin-left: 4px; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 12px 16px;
  border: 1.5px solid #cce6f5; border-radius: 8px;
  font-family: inherit; font-size: 0.94rem; color: var(--text); background: #fafeff; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
  border-color: var(--sky); box-shadow: 0 0 0 3px rgba(0,180,216,0.15);
}
.form-group textarea { resize: vertical; min-height: 130px; }
.btn-submit {
  width: 100%; padding: 15px;
  background: linear-gradient(135deg, var(--sky-dark), var(--sky));
  color: white; border: none; border-radius: 50px;
  font-family: inherit; font-size: 1rem; font-weight: 700; cursor: pointer; letter-spacing: 0.06em;
  box-shadow: 0 4px 16px rgba(0,120,180,0.28); transition: transform .2s, box-shadow .2s;
}
.btn-submit:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,120,180,0.36); }

/* ===== INFO TABLE ===== */
.info-table { width: 100%; border-collapse: collapse; font-size: 0.91rem; }
.info-table th { padding: 15px 24px; background: #f0f9ff; color: var(--sky-dark); text-align: left; width: 30%; font-weight: 600; border-bottom: 1px solid #dceef9; white-space: nowrap; }
.info-table td { padding: 15px 24px; border-bottom: 1px solid #dceef9; }

/* ===== ACCESS BANNER ===== */
.access-banner { background: linear-gradient(90deg, var(--sky-pale) 0%, white 100%); padding: 24px; }
.access-inner { max-width: 1100px; margin: 0 auto; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.access-group { display: flex; align-items: center; gap: 12px; }
.access-icon { width: 42px; height: 42px; border-radius: 50%; background: var(--sky); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.access-icon svg { fill: none; stroke: white; stroke-width: 2; }
.access-info h4 { font-size: 0.76rem; color: var(--muted); margin-bottom: 1px; }
.access-info p { font-size: 0.93rem; font-weight: 700; color: var(--navy); }
.sep { width: 1px; height: 36px; background: rgba(0,120,180,0.15); }

/* ===== PRESIDENT MSG ===== */
.president-msg { max-width: 780px; margin: 48px auto 0; background: linear-gradient(135deg, var(--sky-dark), var(--sky)); border-radius: var(--radius); padding: 42px 48px; color: white; box-shadow: var(--shadow-lg); text-align: center; }
.president-msg h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 16px; opacity: 0.82; }
.president-msg p { font-size: 0.95rem; line-height: 1.95; opacity: 0.9; }
.president-msg .sig { margin-top: 24px; font-size: 0.88rem; opacity: 0.72; }

/* ===== FOOTER ===== */

/* ===== BACKGROUND WATERMARK ===== */
.site-watermark {
  display: none;
}
.site-watermark img {
  width: 100%;
  height: auto;
  display: block;
}

/* ===== 夢カード ===== */
.yume-wrap { display: flex; gap: 22px; align-items: flex-start; margin-top: 8px; }
.yume-img {
  width: 88px; height: 112px; flex-shrink: 0;
  border-radius: 4px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  object-fit: cover;
  object-position: center;
}
.yume-text { flex: 1; }


/* ===== お問い合わせページ 背景ロゴ ===== */
.contact-bg {
  background:
    url('images/%E8%83%8C%E6%99%AF%E3%83%AD%E3%82%B4.png') center/65% no-repeat,
    white !important;
  position: relative;
}
.contact-bg input,
.contact-bg select,
.contact-bg textarea,
.contact-bg .form-group,
.contact-bg > div {
  position: relative;
  z-index: 1;
}
.contact-bg input,
.contact-bg select,
.contact-bg textarea {
  background: white !important;
}

footer { background: var(--navy); color: rgba(255,255,255,0.7); padding: 56px 24px 24px; }
.footer-inner { max-width: 1100px; margin: 0 auto; display: grid; grid-template-columns: 1.5fr 1fr 1.4fr; gap: 56px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.08); align-items: start; position: relative; z-index: 1; }
.footer-brand img { height: 60px; filter: brightness(0) invert(1); margin-bottom: 10px; }
.footer-brand-en {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.32);
  margin-bottom: 16px;
  font-weight: 400;
  white-space: nowrap;
}
.footer-brand p { font-size: 0.84rem; line-height: 1.9; opacity: 0.6; max-width: 280px; }
.footer-col h4 { font-size: 0.76rem; letter-spacing: 0.14em; color: var(--sky-light); text-transform: uppercase; margin-bottom: 18px; padding-bottom: 10px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-col a { display: block; font-size: 0.86rem; color: rgba(255,255,255,0.75); margin-bottom: 10px; transition: color .2s; }
.footer-col a:hover { color: var(--sky-light); }
.footer-col .footer-tel { font-size: 1rem; font-weight: 700; color: white; letter-spacing: 0.04em; margin-bottom: 6px; text-decoration: none; cursor: default; pointer-events: none; }
@media (max-width: 768px) { .footer-col .footer-tel { pointer-events: auto; cursor: pointer; } }
.recruit-tel { pointer-events: none; cursor: default; text-decoration: none; }
@media (max-width: 768px) { .recruit-tel { pointer-events: auto; cursor: pointer; } }
.footer-col .footer-hours { font-size: 0.80rem; color: rgba(255,255,255,0.5); cursor: default; display: block; margin-bottom: 28px; }
.footer-col .footer-mail-btn {
  display: inline-block; padding: 10px 24px; width: 180px; text-align: center; box-sizing: border-box;
  background: var(--sky); color: white !important;
  border-radius: 50px; font-size: 0.82rem; font-weight: 700;
  transition: background .25s, transform .2s;
  margin-bottom: 0 !important;
}
.footer-col .footer-mail-btn:hover { background: var(--sky-dark); transform: translateY(-1px); }
.footer-bottom { max-width: 1100px; margin: 22px auto 0; display: flex; justify-content: space-between; font-size: 0.77rem; color: rgba(255,255,255,0.28); position: relative; z-index: 1; }

/* ===== FADE IN ON SCROLL ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeInUp 0.7s ease both; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ===== HAMBURGER BUTTON ===== */
.header-right { display: flex; align-items: center; gap: 16px; }
.hamburger {
  display: none; background: none; border: none; cursor: pointer;
  padding: 8px; flex-direction: column; gap: 5px; z-index: 1100;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--navy); border-radius: 2px;
  transition: transform .3s ease, opacity .3s ease;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== TABLET ===== */
@media (max-width: 960px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .service-detail-grid { grid-template-columns: 1fr !important; gap: 28px !important; }
  .service-detail-grid > div:last-child { order: -1; }
}

/* ===== MOBILE ===== */
@media (max-width: 768px) {
  /* Header */
  .header-inner { padding: 10px 16px; }
  .logo-wrap img { height: 50px; }
  .header-tel { display: none; }
  .hamburger { display: flex; }

  /* Nav — hidden by default, shown as dropdown */
  nav { display: none; position: absolute; top: 100%; left: 0; right: 0; z-index: 999; box-shadow: 0 8px 24px rgba(0,60,120,0.18); }
  nav.open { display: block; }
  .nav-inner { flex-direction: column; }
  .nav-inner a { padding: 15px 20px; font-size: 0.92rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
  .nav-inner a::after { display: none; }

  /* Hero */
  .hero { height: 380px; min-height: 320px; margin-top: 58px; }
  .slide-content { left: 5%; right: 5%; max-width: none; top: 46%; }
  .slide-content h2 { font-size: 1.55rem; margin-bottom: 10px; }
  .slide-content p { font-size: 0.8rem; margin-bottom: 18px; line-height: 1.75; }
  .slide-badge { display: none; }
  .slide-btns { gap: 10px; }
  .btn-fill, .btn-line { padding: 9px 18px; font-size: 0.8rem; }
  .slide-footer { bottom: 14px; left: 5%; right: 5%; }
  .scroll-hint { display: none; }
  .slide-lines .slide-line { width: 28px; }
  .slide-lines .slide-line.active { width: 36px; }

  /* Page hero */
  .page-hero { margin-top: 58px; padding: 18px 16px 14px; }
  .page-hero h1 { font-size: 1.3rem; }
  .page-hero .page-en { font-size: 0.65rem; }
  .breadcrumb { font-size: 0.72rem; }
  .breadcrumb { font-size: 0.68rem; margin-bottom: 6px; }

  /* Sections */
  section { padding: 52px 16px; }
  .section-header { margin-bottom: 36px; }
  .section-header h2 { font-size: 1.4rem; }

  /* Grids */
  .grid-2, .grid-3 { grid-template-columns: 1fr !important; gap: 16px; }
  .service-detail-grid { grid-template-columns: 1fr !important; gap: 20px !important; }
  .service-detail-grid img { height: 200px !important; }

  /* Cards */
  .service-card, .phil-card, .result-card { padding: 24px 20px; }
  .service-num { font-size: 2.2rem; }

  /* Services split layout */
  .services-split { grid-template-columns: 1fr !important; gap: 32px !important; }

  /* News */
  .news-item { flex-wrap: wrap; gap: 4px 10px; padding: 12px 4px; }
  .news-date { min-width: auto; font-size: 0.72rem; }
  .news-badge { font-size: 0.65rem; }
  .news-text { font-size: 0.82rem; width: 100%; margin-top: 2px; }

  /* Recruit */
  .recruit-card { padding: 24px 20px; }
  .recruit-row { flex-direction: column; gap: 3px; }
  .recruit-label { min-width: auto; }

  /* Contact form two-col */
  .contact-two-col { grid-template-columns: 1fr !important; }

  /* Access banner */
  .access-inner { flex-direction: column; align-items: flex-start; gap: 14px; }
  .access-group { width: 100%; }
  .sep { display: none; }
  .access-info p { font-size: 0.88rem; }

  /* President msg */
  .president-msg { padding: 28px 20px; }
  .president-msg p { font-size: 0.88rem; }

  /* Footer */
  .footer-inner { grid-template-columns: 1fr !important; gap: 28px; }
  .footer-bottom { flex-direction: column; gap: 6px; text-align: center; }

  /* Info table */
  .info-table th, .info-table td { padding: 12px 14px; font-size: 0.84rem; }
  .info-table th { width: 36%; }
  .initiative-card { flex-direction: column; align-items: flex-start; gap: 16px; padding: 20px; }
  .initiative-imgs { justify-content: center; width: 100%; }
  .clients-grid { grid-template-columns: 1fr; }

  /* results/services ページ 横並びカードを縦積みに */
  [style*="display:flex;align-items:stretch;overflow:hidden"] {
    flex-direction: column !important;
  }
  [style*="flex-shrink:0;width:220px"] {
    width: 100% !important;
    height: 180px !important;
  }
  [style*="padding:32px 36px;flex:1"] {
    padding: 20px !important;
  }
  [style*="padding-right:28px"] {
    padding: 0 0 16px 20px !important;
    justify-content: flex-start !important;
  }

  /* インラインgridのスマホ対応 */
  [style*="grid-template-columns:repeat(4"] { grid-template-columns: 1fr 1fr !important; gap: 14px !important; }
  [style*="grid-template-columns:repeat(3"] { grid-template-columns: 1fr !important; gap: 14px !important; }
  [style*="grid-template-columns:1fr 1fr 1fr"] { grid-template-columns: 1fr !important; gap: 14px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:48px"] { grid-template-columns: 1fr !important; gap: 24px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:20px"] { grid-template-columns: 1fr !important; gap: 14px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:12px"] { grid-template-columns: 1fr !important; gap: 10px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:32px"] { grid-template-columns: 1fr !important; gap: 16px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:24px"] { grid-template-columns: 1fr !important; gap: 16px !important; }
  [style*="grid-template-columns:1fr 1fr;gap:16px"] { grid-template-columns: 1fr !important; gap: 14px !important; }

  /* STEPフロー (repeat(5,1fr): ステップ3つ＋矢印2つ) */
  [style*="grid-template-columns:repeat(5,1fr)"] { grid-template-columns: 1fr !important; gap: 8px !important; }
  [style*="grid-template-columns:repeat(5,1fr)"] [style*="display:flex;align-items:center;justify-content:center;padding-top:20px"] { display: none !important; }
}

/* ===== SIDEBAR LAYOUT ===== */
.with-sidebar {
  display: flex;
  align-items: flex-start;
  background: var(--bg);
}
.sidebar-main {
  flex: 1;
  min-width: 0;
}
.sidebar-col {
  flex-shrink: 0;
  width: 256px;
  padding: 28px 16px 28px 12px;
  position: sticky;
  top: 120px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  background: var(--bg);
  border-left: 1px solid rgba(0,120,180,0.10);
}
.sidebar-col::-webkit-scrollbar { width: 4px; }
.sidebar-col::-webkit-scrollbar-thumb { background: rgba(0,120,180,0.2); border-radius: 2px; }
.sidebar-box {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 20px;
}
.sidebar-box-header {
  background: linear-gradient(90deg, var(--sky-dark), var(--sky));
  color: white;
  padding: 10px 16px;
  font-weight: 700;
  font-size: .88rem;
  letter-spacing: .06em;
  text-align: center;
}
.sidebar-box-body {
  padding: 14px 16px;
  font-size: .81rem;
  color: var(--muted);
  line-height: 1.85;
}
.sidebar-box-body a { color: var(--sky-dark); text-decoration: none; }
.sidebar-map { margin-top: 10px; }
.sidebar-map-link {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: .74rem; color: var(--sky-dark);
  background: var(--bg); padding: 3px 8px; border-radius: 4px;
  margin-bottom: 6px; text-decoration: none !important;
}
.sidebar-map iframe {
  width: 100%; height: 175px;
  border-radius: 6px; border: none;
  display: block;
}
.sidebar-banner {
  display: block;
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
  position: relative;
  min-height: 0;
  text-decoration: none !important;
  color: white;
  box-shadow: var(--shadow);
  transition: transform .22s, box-shadow .22s;
  margin-bottom: 16px;
}
.sidebar-banner:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.sidebar-banner.recruit-banner {
  background: linear-gradient(135deg, var(--navy) 0%, var(--sky-dark) 100%);
}
.sidebar-banner.contact-banner {
  background: linear-gradient(135deg, var(--sky-dark) 0%, var(--sky) 100%);
}
/* 英字ウォーターマーク */
.sidebar-banner::before {
  position: absolute;
  bottom: -4px; left: 50%;
  transform: translateX(-50%);
  font-size: 2.4rem; font-weight: 900;
  letter-spacing: .04em;
  color: white; opacity: 0.09;
  white-space: nowrap;
  pointer-events: none;
  line-height: 1;
}
.sidebar-banner.recruit-banner::before { content: 'RECRUIT'; }
.sidebar-banner.contact-banner::before { content: 'CONTACT'; }
.sidebar-banner-inner {
  position: relative;
  z-index: 1;
  padding: 10px 12px 9px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.sidebar-banner-icon {
  opacity: 0.88;
  margin-bottom: 2px;
}
.sidebar-banner-title { font-size: 0.92rem; font-weight: 800; letter-spacing: .08em; }
.sidebar-banner-sub { font-size: .68rem; opacity: .82; line-height: 1.5; text-align: center; }

/* ===== SERVICE LINK CARDS (index) ===== */
.svc-link-card {
  display: flex; align-items: center; gap: 14px;
  padding: 20px 16px; text-decoration: none; border: none;
  border-bottom: 1px solid #e8eef4;
  transition: background .18s;
}
.svc-link-card:hover { background: #e8f4fb; }
.svc-link-card::after { display: none; }
.svc-bar { display: block; width: 4px; align-self: stretch; min-height: 40px; border-radius: 2px; flex-shrink: 0; }
.svc-link-title { font-size: 0.95rem; font-weight: 700; color: var(--navy); margin-bottom: 3px; }
.svc-link-sub { font-size: 0.75rem; color: var(--muted); }
.svc-link-arrow { color: var(--muted); font-size: 1rem; margin-left: auto; flex-shrink: 0; }
.sidebar-banner-arrow {
  margin-top: 5px; font-size: 0.64rem; opacity: 0.65;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 50px; padding: 1px 9px;
  letter-spacing: 0.06em;
  transition: opacity .2s;
}
.sidebar-banner:hover .sidebar-banner-arrow { opacity: 1; }
@media (max-width: 900px) {
  .with-sidebar { flex-direction: column; }
  .sidebar-col {
    width: 100%; position: static;
    max-height: none; padding: 24px 20px;
    border-left: none; border-top: 1px solid rgba(0,120,180,0.10);
  }
  .sidebar-map iframe { height: 200px; }
}

/* ===== RESULTS CARDS ===== */
.results-card {
  display: flex;
  align-items: center;
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  border-bottom: 1px solid rgba(0,120,180,0.08);
  transition: box-shadow .2s, transform .2s;
}
.results-card:hover {
  box-shadow: 0 6px 28px rgba(0,120,180,0.16);
  transform: translateY(-2px);
}
.results-card-img {
  flex-shrink: 0;
  width: 180px;
  height: 120px;
  overflow: hidden;
}
.results-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.results-card-body {
  flex: 1;
  padding: 20px 24px;
  border-left: 4px solid var(--sky);
}
.results-card-body h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 6px;
}
.results-card-body p {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.7;
}
.results-card-arrow {
  padding: 0 20px;
  font-size: 1.2rem;
  color: var(--sky-dark);
  font-weight: 700;
}
@media (max-width: 600px) {
  .results-card-img { width: 110px; height: 90px; }
  .results-card-body { padding: 14px 16px; }
  .results-card-body h2 { font-size: .92rem; }
}
  
/* ===== SERVICE LINK CARDS (index) ===== */
.svc-link-card {
  display: flex; align-items: center; gap: 14px;
  padding: 20px 16px; text-decoration: none; border: none;
  border-bottom: 1px solid #e8eef4;
  transition: background .18s;
}
.svc-link-card:hover { background: #f4f8fc; }
.svc-link-card::after { display: none; }
.svc-bar { display: block; width: 4px; height: 44px; border-radius: 2px; flex-shrink: 0; }
.svc-link-title { font-size: 0.95rem; font-weight: 700; color: var(--navy); margin-bottom: 3px; }
.svc-link-sub { font-size: 0.75rem; color: var(--muted); }
.svc-link-arrow { color: var(--muted); font-size: 1rem; margin-left: auto; flex-shrink: 0; }

/* ===== SERVICE LINK CARDS (index) ===== */
.svc-link-card {
  display: flex; align-items: center; gap: 14px;
  padding: 20px 16px; text-decoration: none; border: none;
  border-bottom: 1px solid #e8eef4;
  transition: background .18s;
}
.svc-link-card:hover { background: #e8f4fb; }
.svc-link-card::after { display: none; }
.svc-bar { display: block; width: 4px; min-height: 40px; border-radius: 2px; flex-shrink: 0; align-self: stretch; }
.svc-link-title { font-size: 0.95rem; font-weight: 700; color: var(--navy); margin-bottom: 3px; }
.svc-link-sub { font-size: 0.75rem; color: var(--muted); }
.svc-link-arrow { color: var(--muted); font-size: 1rem; margin-left: auto; flex-shrink: 0; }

/* ===== TABLET (769px〜960px) inline grid対応 ===== */
@media (min-width: 769px) and (max-width: 960px) {
  [style*="grid-template-columns:repeat(4"] { grid-template-columns: 1fr 1fr !important; gap: 16px !important; }
  [style*="grid-template-columns:repeat(3"] { grid-template-columns: 1fr 1fr !important; gap: 16px !important; }
  [style*="grid-template-columns:1fr 1fr 1fr"] { grid-template-columns: 1fr 1fr !important; gap: 16px !important; }
}

/* ページトップボタン（スマホのみ） */
#backToTop {
  display: none;
  position: fixed;
  bottom: 24px;
  right: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--sky-dark);
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0,0,0,0.25);
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  transform: translateY(10px);
  z-index: 500;
}
#backToTop.visible {
  opacity: 1;
  transform: translateY(0);
}
@media (max-width: 768px) {
  #backToTop { display: flex; }
}

.footer-col .footer-line-btn {
  display: inline-block; padding: 10px 24px; width: 180px; text-align: center; box-sizing: border-box;
  background: #06C755; color: white !important;
  border-radius: 50px; font-size: 0.82rem; font-weight: 700;
  text-decoration: none; margin-top: 8px;
  transition: background 0.2s;
}
.footer-col .footer-line-btn:hover { background: #05a847; }

/* フッター スマホ最適化 */
@media (max-width: 768px) {
  .footer-brand p { display: none; }
  .footer-col a { display: inline-block; width: calc(50% - 8px); margin-bottom: 10px; }
  .footer-col h4 { display: block; width: 100%; }
  .footer-col .footer-tel,
  .footer-col .footer-mail-btn,
  .footer-col .footer-line-btn { display: block; width: auto; }
}
