/* ========================================
   YSNB Web - CSS
   ======================================== */

/* --- Reset & Base --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-navy: #1C2A57;
  --color-navy-dark: #0E162B;
  --color-text-primary: #314157;
  --color-text-secondary: #45556C;
  --color-text-tertiary: #61738D;
  --color-text-muted: #90A1B8;
  --color-border: #E1E8F0;
  --color-border-input: #CAD5E2;
  --color-badge-bg: #ECEEF2;
  --color-surface-light: #F8FAFC;
  --color-white: #FFFFFF;
  --color-red: #FA2B36;

  --font-family: 'Inter', 'Noto Sans JP', sans-serif;
  --radius-sm: 6.75px;
  --radius-md: 8.75px;
  --radius-lg: 12.75px;
  --radius-full: 9999px;

  --shadow-md: 0 8px 10px -6px rgba(0,0,0,0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1);
  --shadow-card: 0 4px 6px -1px rgba(0,0,0,0.1), 0 10px 15px -3px rgba(0,0,0,0.1);
}

/* --- スクロール連動フェードイン（AnimatedSection / AnimatedItem 相当）--- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(48px);
  transition: opacity 1s ease-out, transform 1s ease-out;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-on-scroll--item {
  transform: translateY(32px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.animate-on-scroll--item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-family);
  color: var(--color-text-primary);
  line-height: 1.6;
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  /* 画像のダウンロード抑止 */
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  user-drag: none;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

/* --- Container --- */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 40px;
}

/* --- Section Header --- */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header--left {
  text-align: left;
}

.section-title {
  font-size: 42px;
  font-weight: 400;
  color: var(--color-navy-dark);
  letter-spacing: -0.68px;
  line-height: 1;
}

.section-divider {
  width: 70px;
  height: 2px;
  background: var(--color-navy);
  margin: 20px auto 0;
}

.section-header--left .section-divider {
  margin-left: 0;
}

.section-description {
  font-size: 15.75px;
  color: var(--color-text-secondary);
  margin-top: 20px;
  letter-spacing: -0.29px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-family);
  font-size: 15.75px;
  font-weight: 500;
  letter-spacing: -0.29px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn--primary {
  background: var(--color-navy);
  color: var(--color-white);
  padding: 12px 25px;
}

.btn--primary:hover {
  background: #253570;
}

.btn--outline {
  background: var(--color-white);
  color: var(--color-navy);
  padding: 13px 40px;
  box-shadow: var(--shadow-md), var(--shadow-xl);
}

.btn--outline:hover {
  background: #f0f2f5;
}

.btn--submit {
  padding: 14px 103px;
  font-size: 15.75px;
}

.btn-arrow {
  flex-shrink: 0;
}

/* ========================================
   Header
   ======================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 40px;
  height: 71px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo img {
  width: 150px;
  height: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 15.75px;
  font-weight: 400;
  color: var(--color-navy);
  letter-spacing: -0.29px;
  transition: opacity 0.2s;
}

.nav-link:hover {
  opacity: 0.7;
}

.nav-link--cta {
  background: var(--color-navy);
  color: var(--color-white);
  padding: 7px 21px;
  border-radius: var(--radius-md);
  font-weight: 500;
}

.nav-link--cta:hover {
  opacity: 0.9;
}

/* ========================================
   Hero
   ======================================== */
.hero {
  position: relative;
  height: 100vh;
  min-height: 700px;
  max-height: 941px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.hero-bg-img {
  width: 100%;
  height: 120%;
  min-height: 100%;
  object-fit: cover;
  object-position: center top;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(28, 42, 87, 0.85) 0%,
    rgba(28, 42, 87, 0.6) 50%,
    rgba(28, 42, 87, 0.3) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 40px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-text {
  max-width: 680px;
  width: 100%;
  text-align: center;
}

.hero-heading {
  font-family: Inter, sans-serif;
  font-size: 63px;
  font-weight: 400;
  line-height: 78.75px;
  color: var(--color-white);
  letter-spacing: -1.34px;
  text-align: center;
}

.hero-heading span {
  display: block;
}

.hero-subtitle {
  margin-top: 16px;
  font-size: 17px;
  color: rgba(255,255,255,0.8);
  letter-spacing: -0.15px;
  line-height: 1.3;
}

.hero-subtitle-cap {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.29px;
}

.hero-divider {
  width: 84px;
  height: 1px;
  background: rgba(255,255,255,0.4);
  margin: 28px auto;
}

.hero-description {
  font-size: 15.75px;
  color: rgba(255,255,255,0.85);
  letter-spacing: -0.29px;
  margin-bottom: 28px;
}

.hero .btn--primary {
  padding: 13px 103px;
  box-shadow: var(--shadow-md), var(--shadow-xl);
  background: var(--color-white);
  color: var(--color-navy);
}

.hero .btn--primary:hover {
  background: #f0f2f5;
}

/* ========================================
   Services
   ======================================== */
.services {
  padding: 112px 0;
  background: linear-gradient(180deg, #F8F9FB 0%, #FFFFFF 100%);
}

.service-cards {
  display: flex;
  flex-direction: column;
  gap: 56px;
}

.service-card {
  perspective: 1200px;
}

.service-card-inner {
  position: relative;
  width: 100%;
  min-height: 563px;
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}

.service-card.flipped .service-card-inner {
  transform: rotateY(180deg);
}

.service-card:not(.flipped) .service-card-back {
  pointer-events: none;
}

.service-card-front,
.service-card-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.service-card-front {
  display: flex;
  flex-direction: column;
}

.service-card-back {
  transform: rotateY(180deg);
  -webkit-transform: rotateY(180deg);
  background-color: #1c2a57;
  border: none;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

/* フリップ時: 表のクリック無効化（visibility は裏が真っ白になるため使用しない） */
.service-card.flipped .service-card-front {
  pointer-events: none;
}

/* フリップ時: 裏を前面に、背景を明示 */
.service-card.flipped .service-card-back {
  z-index: 1;
  background-color: #1c2a57;
}

.service-card-front picture {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.service-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.70) 0%,
    rgba(0, 0, 0, 0.30) 50%,
    rgba(0, 0, 0, 0.10) 100%
  );
}

.service-card-front-content {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 56px;
  color: var(--color-white);
  text-align: center;
}

.service-icon {
  width: 56px;
  height: 56px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 16px;
  background: rgba(255,255,255,0.15);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
}

.service-icon--sm {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-navy);
  color: var(--color-white);
  border-radius: var(--radius-sm);
}

.service-card-back .service-icon--sm {
  background: rgba(255, 255, 255, 0.15);
  color: var(--color-white);
}

.service-card-title {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: 0.24px;
  line-height: 1.35;
}

.service-card-tagline {
  font-size: 14px;
  margin-top: 8px;
  opacity: 0.8;
  letter-spacing: -0.15px;
}

.service-card-actions {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0 56px 28px;
}

/* 表の＋と裏の×を同じ位置に（Web: 右下 56px） */
.service-card-front .service-card-actions {
  padding: 0 56px 56px;
}

.service-card-front .service-card-actions .service-card-flip-btn {
  position: absolute;
  right: 56px;
  bottom: 56px;
  margin-left: 0;
}

.service-card-back .service-card-actions {
  position: relative;
  margin-top: auto;
  padding: 56px;
  width: 100%;
  min-height: 56px;
  flex-shrink: 0;
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* 詳しく相談する・×を同じ高さに（中央揃え） */
.service-card-back .service-card-actions .btn--outline {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  flex-shrink: 0;
}

.service-card-back .service-card-actions .service-card-flip-btn {
  position: absolute;
  right: 56px;
  top: 50%;
  transform: translateY(-50%);
  flex-shrink: 0;
  margin-left: 0;
}

.service-card-back .service-card-actions .service-card-flip-btn:hover {
  transform: translateY(-50%) scale(1.05);
}

.service-card-flip-btn {
  width: 49px;
  height: 49px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.85);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-navy);
  box-shadow: var(--shadow-md), var(--shadow-xl);
  transition: all 0.2s;
  margin-left: auto;
}

.service-card-flip-btn:hover {
  background: var(--color-white);
  transform: scale(1.05);
}

.service-card-back .service-card-flip-btn {
  background: rgba(255, 255, 255, 0.2);
  color: var(--color-white);
  margin-left: auto;
}

.service-card-back .btn--outline {
  background: var(--color-white);
  color: #1c2A57;
  border: none;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  line-height: 1;
  padding: 12px 24px;
  min-height: 48px;
  box-sizing: border-box;
}

.service-card-back .btn--outline .btn__text,
.service-card-back .btn--outline .btn-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.service-card-back .btn--outline .btn-arrow {
  flex-shrink: 0;
}

.service-card-back .btn--outline:hover {
  background: #f0f2f5;
  color: #1c2A57;
}

/* Service card back content */
.service-card-back-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
  max-width: 811px;
  margin: 0 auto;
  padding: 56px;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  text-align: left;
}

.service-card-back-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.service-card-back-header .service-card-back-title {
  margin: 0;
  line-height: 1.2;
  min-height: 42px;
  display: flex;
}

.service-card-back-title {
  font-family: Inter, sans-serif;
  font-size: 26px;
  font-weight: 600;
  line-height: 31.50px;
  letter-spacing: 0.24px;
  color: var(--color-white);
}

.service-card-back-desc {
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 22px;
  color: rgba(255, 255, 255, 0.80);
  margin-bottom: 24px;
}

.service-detail-list h4 {
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 21px;
  letter-spacing: 0.20px;
  color: rgba(255, 255, 255, 0.90);
  margin-bottom: 12px;
}

.service-detail-list ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
  list-style: none;
  padding-left: 0;
}

.service-detail-list li {
  font-family: Inter, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 22.75px;
  color: rgba(255, 255, 255, 0.80);
  padding-left: 0;
  position: relative;
  text-align: left;
}

.service-detail-list li::before {
  content: '・ ';
  color: rgba(255, 255, 255, 0.85);
}

/* ========================================
   Case Studies（Figma指定）
   ======================================== */
.case-studies {
  padding: 128px 0;
  background-color: #1c2a57;
  color: var(--color-white);
  overflow: hidden;
}

.case-studies .section-title {
  color: var(--color-white);
}

.case-studies .section-divider {
  background: rgba(255,255,255,0.4);
}

.case-studies .section-description {
  color: rgba(255,255,255,0.7);
}

/* Case slider - react-slick相当: 3/2/1枚、無限ループ、自動再生5s、gap 32px */
.case-slider {
  position: relative;
  margin: 0 auto;
  max-width: 1280px;
  padding: 0 24px;
  box-sizing: border-box;
  opacity: 0;
  transition: opacity 0.5s ease-out 0.4s;
}

.case-studies.is-visible .case-slider {
  opacity: 1;
}

@media (min-width: 769px) {
  .case-slider {
    padding: 0 32px;
  }
}

@media (min-width: 1025px) {
  .case-slider {
    padding: 0 48px;
  }
}

.case-slider__dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 40px;
}

.case-slider__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.case-slider__dot:hover {
  background: rgba(255, 255, 255, 0.6);
}

.case-slider__dot.is-active {
  background: #ffffff;
  transform: scale(1.2);
}

.case-slider__viewport {
  overflow: hidden;
  border-radius: var(--radius-lg);
  touch-action: pan-y pinch-zoom;
  width: 100%;
  padding: 0;
  box-sizing: border-box;
  --case-card-width: 318px;
  --case-slider-gap: 32px;
}

.case-slider__track {
  display: flex;
  gap: var(--case-slider-gap, 32px);
  will-change: transform;
  transition: transform 0.5s ease;
}

.case-studies {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.case-studies.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.case-card {
  flex: 0 0 var(--case-card-width, 318px);
  width: var(--case-card-width, 318px);
  min-width: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(226, 232, 240, 0.6);
  border-radius: 8px;
  overflow: hidden;
  color: #1c2a57;
  display: flex;
  flex-direction: column;
  will-change: transform;
  transition: all 0.5s;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.case-card:hover {
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.case-card-image {
  position: relative;
  height: 224px;
  overflow: hidden;
}

.case-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.case-card-image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent);
}

/* アイコンコンテナ（画像内左上） */
.case-card-icon {
  position: absolute;
  top: 24px;
  left: 24px;
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  z-index: 1;
}

.case-card-icon svg {
  width: 28px;
  height: 28px;
  color: #1c2a57;
  flex-shrink: 0;
}

.case-card-header {
  padding: 24px 24px 0;
  padding-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.case-card-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.case-card-company {
  font-size: 20px;
  font-weight: 400;
  color: #1c2a57;
  line-height: 1.25;
  margin: 0;
}

.case-card .badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  background-color: #f1f5f9;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  color: #334155;
  letter-spacing: 0.09px;
}

.case-card-summary {
  font-size: 14px;
  color: #334155;
  line-height: 1.625;
  letter-spacing: -0.02px;
  margin: 0;
}

.case-card-content {
  padding: 0 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  flex: 1;
}

.case-card-section h4 {
  font-size: 14px;
  font-weight: 700;
  color: #1c2a57;
  margin-bottom: 8px;
  letter-spacing: -0.15px;
}

.case-card-section ul {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.case-card-section li {
  font-size: 14px;
  color: #334155;
  letter-spacing: -0.02px;
  padding-left: 14px;
  position: relative;
  line-height: 1.5;
}

.case-card-section li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #1c2a57;
}

/* アプローチ白枠（Figma指定） */
.case-card-section.approach-box {
  background-color: #f8fafc;
  border-radius: 8px;
  padding: 16px;
}

.case-card-section.approach-box h4 {
  color: #1c2a57;
  margin-bottom: 12px;
  font-size: inherit;
}

.case-card-section.approach-box ul {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.case-card-section.approach-box li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: #334155;
  padding-left: 0;
  font-size: 14px;
  line-height: 20px;
}

.case-card-section.approach-box li::before {
  content: '';
  display: block;
  position: static;
  width: 6px;
  height: 6px;
  min-width: 6px;
  margin-top: 8px;
  border-radius: 9999px;
  background-color: #1c2a57;
  flex-shrink: 0;
}

/* Case slider nav buttons */
.case-slider__prev,
.case-slider__next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-navy);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: opacity 0.2s, transform 0.2s, background 0.2s;
  z-index: 2;
}

.case-slider__prev:hover,
.case-slider__next:hover {
  background: rgba(255,255,255,0.6);
  transform: translateY(-50%) scale(1.05);
}

.case-slider__prev {
  left: 8px;
}

.case-slider__next {
  right: 8px;
}

@media (max-width: 768px) {
  .case-slider {
    padding: 0 44px;
  }

  .case-slider__prev,
  .case-slider__next {
    width: 32px;
    height: 32px;
  }

  .case-slider__prev {
    left: 6px;
    right: auto;
  }

  .case-slider__next {
    right: 6px;
    left: auto;
  }
}

/* ========================================
   About
   ======================================== */
.about {
  padding: 112px 0;
  background: var(--color-white);
}

.about-content {
  display: flex;
  gap: 70px;
  align-items: flex-start;
}

.about-image {
  flex: 0 0 392px;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.about-image img {
  width: 100%;
  height: 540px;
  object-fit: cover;
}

.about-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.about-quote {
  font-size: 21px;
  font-weight: 400;
  color: var(--color-navy);
  letter-spacing: -0.36px;
  margin-bottom: 16px;
}

.about-paragraphs {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-paragraphs p {
  font-size: 14px;
  color: var(--color-text-primary);
  line-height: 1.65;
  letter-spacing: -0.15px;
}

.about-name {
  font-size: 22px;
  font-weight: 400;
  color: var(--color-navy);
  letter-spacing: 0.4px;
}

.about-role {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.about-role span {
  font-size: 12.25px;
  color: var(--color-text-secondary);
  letter-spacing: -0.02px;
}

.about-career {
  display: flex;
  height: 152.5px;
  padding: 12px 22px 22px 22px;
  flex-direction: column;
  align-items: flex-start;
  gap: 10.5px;
  flex-shrink: 0;
  align-self: stretch;
  margin-top: 20px;
  border-radius: 12.75px;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
}

.about-career h4 {
  font-size: 12.25px;
  font-weight: 500;
  color: var(--color-text-secondary);
  margin-bottom: 0;
  letter-spacing: -0.02px;
}

.about-career ul {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.about-career li {
  font-size: 12.25px;
  color: var(--color-text-secondary);
  letter-spacing: -0.02px;
  line-height: 1.5;
}

.about-career li::before {
  content: '• ';
}

/* ========================================
   Flow (ご依頼の流れ)
   ======================================== */
.flow {
  padding: 112px 0;
  background: var(--color-navy);
  color: var(--color-white);
}

.flow .section-title {
  color: var(--color-white);
}

.flow .section-divider {
  background: rgba(255,255,255,0.4);
}

.flow .section-description {
  color: rgba(255,255,255,0.7);
}

/* タイムライン全体: 1024px未満で非表示 */
.flow-steps-indicator {
  position: relative;
  max-width: 896px;
  margin: 0 auto 56px;
  display: none;
  min-height: 87.5px;
}

@media (min-width: 1024px) {
  .flow-steps-indicator {
    display: block;
  }
}

/* 背景線（全体を通る薄い線） */
.flow-timeline-bg {
  position: absolute;
  top: 28px;
  left: 0;
  right: 0;
  height: 1.75px;
  background-color: rgba(255, 255, 255, 0.2);
  z-index: 1;
}

/* アクティブ線（STEP 1 → STEP 2） */
.flow-timeline-active {
  position: absolute;
  top: 28px;
  left: 0;
  width: 307px;
  height: 2px;
  background-color: #ffffff;
  z-index: 2;
}

/* STEP円のグリッド */
.flow-step-dots {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  z-index: 10;
}

.flow-step-dot {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.flow-step-circle {
  width: 56px;
  height: 56px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 10;
  box-sizing: border-box;
  border: 4px solid rgba(255, 255, 255, 0.4);
  background-color: #1c2a57;
  font-size: 15.75px;
  line-height: 24.5px;
  font-weight: bold;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: -0.0179px;
}

.flow-step-circle span {
  display: block;
}

/* STEP 1: 完了済み */
.flow-step-dot:nth-child(1) .flow-step-circle {
  background-color: #d2d4dd;
  border: 4px solid rgba(255, 255, 255, 0.8);
  color: #1c2a57;
}

/* STEP 2: 現在進行中（アクティブ） */
.flow-step-dot:nth-child(2) .flow-step-circle {
  width: 61.6px;
  height: 61.6px;
  margin-top: -2.8px;
  background-color: #ffffff;
  border: 4px solid #ffffff;
  color: #1c2a57;
  box-shadow: 0 10px 15px 0 rgba(0, 0, 0, 0.1), 0 4px 6px 0 rgba(0, 0, 0, 0.1);
}

.flow-step-dot:nth-child(2) .flow-step-circle span {
  margin-top: 0.3px;
}

/* STEP 3 & 4: 未完了（デフォルトで適用済み） */

/* ラベル共通 */
.flow-step-label-wrap {
  margin-top: 14px;
  text-align: center;
}

.flow-step-label {
  font-size: 12.25px;
  line-height: 17.5px;
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: -0.0179px;
}

/* STEP 2 ラベル（アクティブ） */
.flow-step-dot:nth-child(2) .flow-step-label-wrap {
  margin-top: 11.2px;
}

.flow-step-dot:nth-child(2) .flow-step-label {
  color: #ffffff;
}

.flow-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

@media (max-width: 1023px) {
  .flow-cards {
    grid-template-columns: 1fr;
  }
}

.flow-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.flow-card-step {
  font-size: 11px;
  font-weight: 500;
  color: #94a3b8;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.flow-card-icon-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.flow-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  flex-shrink: 0;
}

/* 初回相談（STEP 2）のみ紺色アイコン */
.flow-card:nth-child(2) .flow-card-icon {
  background: #1C2A57;
  color: #fff;
}

.flow-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: #1e293b;
  letter-spacing: -0.02px;
}

.flow-card p {
  font-size: 13px;
  color: #64748b;
  line-height: 1.65;
  letter-spacing: -0.01px;
}

/* ========================================
   Contact
   ======================================== */
.contact {
  padding: 112px 0;
  background: linear-gradient(180deg, #F8F9FB 0%, #FFFFFF 100%);
}

.contact-form {
  max-width: 1015px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
}

.form-group {
  width: 100%;
}

.form-label {
  display: block;
  font-size: 12.25px;
  font-weight: 500;
  color: var(--color-text-primary);
  margin-bottom: 6px;
  letter-spacing: -0.02px;
}

.required {
  color: var(--color-red);
  margin-left: 2px;
}

.form-input,
.form-textarea {
  width: 100%;
  font-family: var(--font-family);
  font-size: 12.25px;
  color: var(--color-text-primary);
  padding: 10px 14px;
  border: 1px solid var(--color-border-input);
  border-radius: var(--radius-sm);
  background: var(--color-white);
  outline: none;
  transition: border-color 0.2s;
  letter-spacing: -0.02px;
}

.form-input:focus,
.form-textarea:focus {
  border-color: var(--color-navy);
  box-shadow: 0 0 0 2px rgba(28, 42, 87, 0.15);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--color-text-muted);
}

.form-input {
  height: 42px;
}

.form-textarea {
  min-height: 56px;
  resize: vertical;
}

.form-error {
  display: block;
  font-size: 12px;
  color: var(--color-red);
  margin-top: 4px;
}

.form-success {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  min-height: 1.5em;
}

.form-input.is-error,
.form-textarea.is-error {
  border-color: var(--color-red);
}

.form-note {
  font-size: 12.25px;
  color: var(--color-text-muted);
  letter-spacing: -0.02px;
}

/* ========================================
   Footer
   ======================================== */
.footer {
  padding: 56px 0 42px;
  background: var(--color-navy);
  color: var(--color-white);
}

.footer-main {
  display: flex;
  gap: 120px;
  padding-bottom: 42px;
  border-bottom: 1px solid rgba(255,255,255,0.25);
}

.footer-brand {
  flex: 0 0 auto;
}

.footer-logo {
  height: 57px;
  width: auto;
  margin-bottom: 16px;
}

.footer-tagline {
  font-size: 12.25px;
  color: rgba(255,255,255,0.85);
  line-height: 1.6;
  letter-spacing: -0.02px;
}

.footer-menu {
  flex: 1;
  max-width: 400px;
}

.footer-menu__title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: -0.15px;
  color: var(--color-white);
}

.footer-menu__cols {
  display: flex;
  flex-direction: row;
  gap: 48px;
}

.footer-menu__col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-menu a {
  font-size: 12.25px;
  color: rgba(255,255,255,0.85);
  letter-spacing: -0.02px;
  transition: color 0.2s;
}

.footer-menu a:hover {
  color: var(--color-white);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 28px;
}

.copyright {
  font-size: 12.25px;
  color: rgba(255,255,255,0.6);
  letter-spacing: -0.02px;
}

.copyright-brand {
  font-weight: 700;
}

.footer-links {
  display: flex;
  gap: 28px;
}

.footer-links a {
  font-size: 12.25px;
  color: rgba(255,255,255,0.6);
  letter-spacing: -0.02px;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--color-white);
}

/* ========================================
   Hamburger Menu
   ======================================== */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 101;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-navy);
  transition: all 0.3s ease;
  border-radius: 1px;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ========================================
   Responsive - Tablet
   ======================================== */
@media (max-width: 1024px) {
  /* 事務所について: タブレットはWebに近い横並びレイアウトのまま（画像トリミングを維持） */
  .about-content {
    gap: 48px;
  }

  .about-image {
    flex: 0 0 340px;
  }

  .about-image img {
    height: 540px;
    object-fit: cover;
  }

  .flow-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
  }

  .footer-main {
    flex-direction: column;
    gap: 40px;
  }
}

/* ========================================
   Responsive - Mobile (409px design)
   ======================================== */
@media (max-width: 768px) {
  .container {
    padding: 0 22px;
  }

  /* --- Header Mobile --- */
  .header-inner {
    padding: 0 22px;
    height: 69px;
  }

  .logo img {
    width: 150px;
    height: auto;
  }

  .nav {
    display: none;
    position: fixed;
    top: 69px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(10px);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 40px;
    gap: 0;
    z-index: 99;
  }

  .nav.open {
    display: flex;
  }

  .nav .nav-link {
    font-size: 18px;
    padding: 16px 0;
    width: 100%;
    text-align: center;
    border-bottom: 1px solid var(--color-border);
  }

  .nav .nav-link--cta {
    margin-top: 20px;
    width: auto;
    padding: 12px 40px;
    border-bottom: none;
  }

  .hamburger {
    display: flex;
  }

  /* --- Hero Mobile --- */
  .hero {
    min-height: auto;
    max-height: none;
    height: 698px;
    align-items: center;
    justify-content: center;
    padding: 60px 0 100px;
  }

  .hero-overlay {
    background: linear-gradient(
      to top,
      rgba(28, 42, 87, 0.9) 0%,
      rgba(28, 42, 87, 0.6) 40%,
      rgba(28, 42, 87, 0.3) 100%
    );
  }

  .hero-content {
    padding: 0 22px;
  }

  .hero-text {
    max-width: 100%;
  }

  .hero-heading {
    font-size: 34px;
    letter-spacing: -0.73px;
    line-height: 1.25;
  }

  .hero-subtitle {
    font-size: 9.3px;
    margin-top: 10px;
  }

  .hero-subtitle-cap {
    font-size: 10.5px;
  }

  .hero-divider {
    margin: 20px 0;
  }

  .hero-description {
    font-size: 16.4px;
    line-height: 1.63;
    letter-spacing: -0.3px;
    margin-bottom: 24px;
  }

  .hero .btn--primary {
    padding: 13px 0;
    width: 100%;
    justify-content: center;
    margin-bottom: 0;
  }

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

  /* --- Section Headers Mobile --- */
  .section-title {
    font-size: 32.7px;
    letter-spacing: -0.4px;
    line-height: 1.11;
  }

  .section-description {
    font-size: 18.2px;
    line-height: 1.63;
    letter-spacing: -0.45px;
  }

  .section-header {
    margin-bottom: 40px;
  }

  /* --- Services Mobile --- */
  .services {
    padding: 80px 0;
  }

  .service-cards {
    gap: 32px;
  }

  .service-card-inner {
    min-height: 629px;
  }

  .service-card-img {
    object-fit: cover;
  }

  .service-card-front-content {
    padding: 29px;
  }

  .service-card-title {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.45px;
  }

  .service-card-tagline {
    font-size: 13px;
  }

  .service-card-actions {
    padding: 0 29px 29px;
  }

  .service-card-front .service-card-actions .service-card-flip-btn {
    right: 29px;
    bottom: 29px;
  }

  .service-card-back .service-card-actions {
    padding: 29px;
    min-height: 88px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
  }

  /* SP: 詳しく相談するをフローに置き、×と高さを揃える */
  .service-card-back .service-card-actions .btn--outline {
    position: relative;
    left: auto;
    top: auto;
    transform: none;
  }

  .service-card-back .service-card-actions .service-card-flip-btn {
    right: 29px;
    top: 50%;
    transform: translateY(-50%);
  }

  .service-card-back .service-card-actions .service-card-flip-btn:hover {
    transform: translateY(-50%) scale(1.05);
  }

  .service-card-back-content {
    padding: 29px;
  }

  .service-card-back-title {
    font-size: 18px;
  }

  .service-card-back-desc {
    font-size: 13px;
    line-height: 1.7;
  }

  .service-detail-list li {
    font-size: 13px;
    line-height: 1.6;
  }

  /* --- Case Studies Mobile --- */
  .case-studies {
    padding: 80px 0;
  }

  .case-card-image {
    height: 204px;
  }

  .case-card-company {
    font-size: 18px;
  }

  .case-card-summary {
    font-size: 13px;
    line-height: 1.6;
  }

  .case-card-section h4 {
    font-size: 14.5px;
  }

  .case-card-section li {
    font-size: 13px;
    line-height: 1.6;
  }

  .case-slider__prev,
  .case-slider__next {
    display: flex;
  }

  /* --- About Mobile --- */
  .about {
    padding: 80px 0;
  }

  .about-content {
    flex-direction: column;
    gap: 32px;
  }

  .about-image {
    flex: none;
    width: 100%;
  }

  .about-image img {
    height: 495px;
    border-radius: var(--radius-lg);
  }

  .about-text {
    gap: 32px;
  }

  .about-quote {
    font-size: 18px;
    margin-bottom: 12px;
  }

  .about-paragraphs p {
    font-size: 13px;
    line-height: 1.7;
  }

  .about-name {
    font-size: 20px;
  }

  .about-role span {
    font-size: 13px;
  }

  .about-career li {
    font-size: 13px;
  }

  /* --- Flow Mobile --- */
  .flow {
    padding: 80px 0;
  }

  /* 1024px未満ではタイムラインは display: none（.flow-steps-indicator のデフォルト） */

  .flow-cards {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .flow-card-step {
    font-size: 13px;
  }

  .flow-card-icon {
    width: 44px;
    height: 44px;
  }

  .flow-card h3 {
    font-size: 16.4px;
    font-weight: 500;
  }

  .flow-card p {
    font-size: 13px;
    line-height: 1.6;
  }

  /* --- Contact Mobile --- */
  .contact {
    padding: 80px 0;
  }

  .contact-form {
    gap: 24px;
  }

  .form-input {
    height: 44px;
    font-size: 14px;
  }

  .form-textarea {
    min-height: 58px;
    font-size: 14px;
  }

  .btn--submit {
    width: 100%;
    padding: 14px 0;
    justify-content: center;
    font-size: 16.4px;
  }

  .form-note {
    font-size: 13px;
  }

  /* --- Footer Mobile --- */
  .footer {
    padding: 48px 0 36px;
  }

  .footer-main {
    flex-direction: column;
    gap: 32px;
  }

  .footer-brand {
    order: 1;
  }

  .footer-tagline {
    font-size: 13px;
  }

  .footer-menu {
    order: 2;
    max-width: none;
  }

  .footer-menu__title {
    font-size: 14.5px;
  }

  .footer-menu__cols {
    flex-direction: column;
    gap: 10px;
  }

  .footer-menu a {
    font-size: 13px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    text-align: left;
  }

  .copyright {
    font-size: 13px;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 16px;
  }

  .footer-links a {
    font-size: 13px;
  }
}
