/* ============================================
   studio Lib. TOP（index）ページ専用スタイル
   ============================================ */


/* ============================================
   TOP ページ ヘッダーフェードイン
   （body.loaded 付与後に発火）
   ============================================ */
.header-cta { height: 32px; font-weight: 400; }

/* ヒーロー中はロゴ非表示、スクロール後に表示 */
[data-hero] .sl-site-logo {
  opacity: 0;
  transition: opacity 0.4s ease;
}
body[data-hero].hero-passed .sl-site-logo { opacity: 1; }

[data-hero] .sl-site-nav a { opacity: 0; }
[data-hero] .header-cta { opacity: 0; }

/* body.loaded 付与前は全アニメ停止 */
body[data-hero]:not(.loaded) .scroll-indicator,
body[data-hero]:not(.loaded) .sl-site-nav a,
body[data-hero]:not(.loaded) .header-cta {
  animation: none;
  opacity: 0;
}

/* body.loaded 付与後にアニメ開始 */
body[data-hero].loaded .scroll-indicator {
  animation: heroFadeIn 0.6s ease 3.15s forwards;
}
body[data-hero].loaded .sl-site-nav a {
  animation: heroFadeIn 0.5s ease forwards;
}
body[data-hero].loaded .sl-site-nav a:nth-child(1) { animation-delay: 0.4s; }
body[data-hero].loaded .sl-site-nav a:nth-child(2) { animation-delay: 0.55s; }
body[data-hero].loaded .sl-site-nav a:nth-child(3) { animation-delay: 0.7s; }
body[data-hero].loaded .sl-site-nav a:nth-child(4) { animation-delay: 0.85s; }
body[data-hero].loaded .header-cta {
  animation: heroFadeIn 0.5s ease 1.0s forwards;
}

@keyframes heroFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
  padding: 0;
  background:
    radial-gradient(ellipse 90% 60% at 100% 10%, rgba(221,214,254,1.0) 0%, transparent 100%),
    radial-gradient(ellipse 90% 80% at 100% 55%, rgba(186,230,253,0.9) 0%, transparent 100%),
    #ffffff;
  position: relative;
  overflow: hidden;
  height: 150vh;
  margin-top: calc(-1 * var(--header-height));
  display: flex;
  align-items: stretch;
}
.hero + .section { margin-top: -2px; position: relative; }
.hero__bottom-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 80vh;
  background: linear-gradient(to bottom,
    transparent 0%,
    rgba(255,255,255,0.05) 25%,
    rgba(255,255,255,0.2) 50%,
    rgba(255,255,255,0.7) 75%,
    #ffffff 100%
  );
  pointer-events: none;
  z-index: 0;
}



/* ロゴ（左下） */
.hero__logo-deco {
  position: absolute;
  bottom: calc(50vh + 80px);
  left: calc(5% + 58px);
  width: clamp(120px, 12vw, 150px);
  margin: 0;
  z-index: 1;
  pointer-events: none;
}

.hero__logo-sub {
  display: block;
  font-family: var(--font-en);
  font-size: 8px;
  font-weight: 400;
  color: var(--color-muted);
  margin-top: 0;
  width: 100%;
  text-align: right;
}

/* vibeテキスト（左上） */
.hero__vibe {
  position: absolute;
  top: calc(var(--header-height) + 40px);
  left: 5%;
  font-family: var(--font-en);
  font-size: clamp(14px, 1.8vw, 24px);
  font-weight: 400;
  color: var(--color-muted);
  letter-spacing: 0;
  margin: 0;
  z-index: 1;
  pointer-events: none;
}
.hero__vibe-row { display: block; line-height: 1.5; }
.hero__vibe-row--indent { padding-left: calc(1.2em + 10px); }
.hero__vibe-text { letter-spacing: -0.01em; }
.hero__vibe-spinner {
  display: inline-block;
  width: 1.2em;
  text-align: center;
  margin-right: 10px;
}
.hero__vibe-cursor {
  display: inline-block;
  width: 0.55em;
  height: 0.85em;
  background: var(--color-muted);
  vertical-align: -0.1em;
  margin-left: 3px;
  animation: cursorBlink 0.7s step-end infinite;
}
.hero__vibe-cursor.hidden { opacity: 0; animation: none; }
@keyframes cursorBlink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}




/* ============================================
   Concept Section
   ============================================ */
.concept-section {
  padding: 0 0 200px;
  position: relative;
  overflow: hidden;
}
.concept-section::before {
  content: '';
  position: absolute;
  width: 300px;
  height: 300px;
  left: -50px;
  top: 50%;
  transform: translateY(-50%);
  background: linear-gradient(135deg, rgba(186,230,253,0.8) 0%, rgba(221,214,254,0.65) 50%, transparent 100%);
  border-radius: 50%;
  filter: blur(50px);
  pointer-events: none;
  z-index: 0;
}
.concept-section .sl-container { position: relative; z-index: 1; }
.concept-section__body {
  display: grid;
  grid-template-columns: 3fr 2fr;
  grid-template-rows: 1fr 1fr;
  text-align: left;
  min-height: 320px;
}
.concept-section__catch {
  grid-column: 2;
  grid-row: 1;
  align-self: end;
  padding: 24px 0;
  text-align: right;
  font-size: clamp(22px, 2.6vw, 36px);
  font-weight: 400;
  color: var(--color-main);
  line-height: 1.5;
  letter-spacing: 0.04em;
}
.concept-section__catch-phrase {
  background: linear-gradient(90deg, #A5B4FC 0%, #7DD3FC 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.concept-section__catch-slash {
  -webkit-text-fill-color: var(--color-border);
  color: var(--color-border);
}
.concept-section__catch-grad { }
.concept-section__catch-main {
  display: inline-block;
}
.concept-section__sub {
  grid-column: 2;
  grid-row: 2;
  align-self: start;
  max-width: 480px;
  width: 100%;
  padding: 24px 0;
  font-size: 15px;
  color: var(--color-main);
  line-height: 1.9;
}

@media (max-width: 767px) {
  .concept-section__body { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .concept-section__catch { grid-column: 1; grid-row: 1; font-size: clamp(18px, 5.5vw, 26px); }
  .concept-section__sub { grid-column: 1; grid-row: 2; font-size: 13px; }
  .concept-section__sub br { display: none; }
}

/* ============================================
   Scroll Indicator — ドット列
   ============================================ */
.scroll-indicator {
  position: absolute;
  bottom: calc(50vh + 48px);
  right: 5%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  opacity: 0;
  z-index: 1;
}
.scroll-indicator__dot {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--color-muted);
  opacity: 0;
  animation-duration: 3s;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}
.scroll-indicator__dot:nth-child(1) { animation-name: dotSeq1; }
.scroll-indicator__dot:nth-child(2) { animation-name: dotSeq2; }
.scroll-indicator__dot:nth-child(3) { animation-name: dotSeq3; }
.scroll-indicator__dot:nth-child(4) { animation-name: dotSeq4; }
.scroll-indicator__dot:nth-child(5) { animation-name: dotSeq5; }
.scroll-indicator__dot:nth-child(6) { animation-name: dotSeq6; }

@keyframes dotSeq1 { 0%,49.9%{opacity:1} 50%,100%{opacity:0} }
@keyframes dotSeq2 { 0%,8.3%{opacity:0} 8.4%,58.2%{opacity:1} 58.3%,100%{opacity:0} }
@keyframes dotSeq3 { 0%,16.6%{opacity:0} 16.7%,66.5%{opacity:1} 66.6%,100%{opacity:0} }
@keyframes dotSeq4 { 0%,24.9%{opacity:0} 25%,74.8%{opacity:1} 74.9%,100%{opacity:0} }
@keyframes dotSeq5 { 0%,33.2%{opacity:0} 33.3%,83.1%{opacity:1} 83.2%,100%{opacity:0} }
@keyframes dotSeq6 { 0%,41.5%{opacity:0} 41.6%,91.4%{opacity:1} 91.5%,100%{opacity:0} }

/* ============================================
   Hero — レスポンシブ
   ============================================ */
@media (max-width: 767px) {
  .hero { height: 130svh; }
  .scroll-indicator { display: none; }
  .hero__logo-deco {
    width: clamp(160px, 45vw, 240px);
    bottom: calc(30svh + 72px);
    left: 20px;
  }
  .hero__logo-sub { font-size: 10px; text-align: right; font-weight: 400; letter-spacing: -0.05em; }
  .hero__vibe {
    font-size: clamp(13px, 4.5vw, 20px);
    right: 20px;
  }
}

/* ============================================
   Works Horizontal Scroll
   ============================================ */
.works-scroll-wrap {
  height: 600vh;
  position: relative;
}
.works-scroll-sticky {
  position: relative;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: clamp(12px, 2.5vh, 32px);
  padding: clamp(16px, 3vh, 40px) 0;
}
.works-scroll-sticky.is-fixed {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
}
.works-scroll-sticky.is-bottom {
  position: absolute;
  bottom: 0;
  top: auto;
  left: 0;
  right: 0;
  width: 100%;
}
.works-scroll-header { flex-shrink: 0; text-align: left; width: 100%; }
.works-scroll-header .section__title { margin-bottom: 0; }
.works-scroll-track {
  display: flex;
  gap: 24px;
  padding: 0 5%;
  will-change: transform;
  flex-shrink: 0;
}
.works-scroll-card {
  flex: 0 0 544px;
  width: 544px;
}
.works-scroll-card .sl-card__img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  width: 100%;
  height: auto;
}
.works-progress {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  padding-right: 5%;
}
.works-progress__bar {
  width: 80px;
  height: 1px;
  background: var(--color-border);
}
.works-progress__fill {
  height: 100%;
  background: var(--color-main);
  width: 0%;
  transition: width 0.08s linear;
  transform-origin: left;
}
.works-progress__count {
  font-family: var(--font-en);
  font-size: 12px;
  color: var(--color-muted);
  white-space: nowrap;
  letter-spacing: 0.05em;
}
.works-scroll-footer {
  flex-shrink: 0;
  width: 100%;
  text-align: right;
  max-width: none;
  padding-left: 0;
  padding-right: 5%;
}
.works-text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-en);
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--color-main);
  text-decoration: none;
}
.works-text-link__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--color-main);
  overflow: hidden;
  position: relative;
  transition: border-color 0.3s ease;
  flex-shrink: 0;
}
.works-text-link__arrow::before,
.works-text-link__arrow::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  background: var(--color-main);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8h10M9 4l4 4-4 4'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8h10M9 4l4 4-4 4'/%3E%3C/svg%3E") center/contain no-repeat;
}
.works-text-link__arrow::before {
  transition: transform 0.6s ease, opacity 0.6s ease;
}
.works-text-link__arrow::after {
  transform: translateX(-140%);
  opacity: 0;
  transition: transform 0.6s ease, opacity 0.6s ease;
}
.works-text-link:hover .works-text-link__arrow::before {
  transform: translateX(140%);
  opacity: 0;
}
.works-text-link:hover .works-text-link__arrow::after {
  transform: translateX(0);
  opacity: 1;
}

@media (max-width: 767px) {
  .works-scroll-wrap { height: auto; }
  .works-scroll-sticky { position: static; height: auto; overflow: visible; display: block; }
  .works-scroll-header { margin-bottom: 32px; }
  .works-scroll-track { display: grid; grid-template-columns: 1fr; transform: none !important; padding: 0 20px; gap: 20px; }
  .works-scroll-card { flex: none; width: 100%; }
  .works-progress { display: none; }
}
