/*
Theme Name: SWELL Child Shindan
Template: swell
Version: 1.7.0
Description: 裏町診断所用 SWELL子テーマ（カード大幅拡大・1枚時センター） v1.7.0
Author: 裏町診断所
*/

html { scroll-behavior: smooth; }

:root{
  --shindan-bg:            #f6f1fb;
  --shindan-surface:       #ebe3f5;
  --shindan-card-bg:       #ffffff;
  --shindan-text:          #2a1f3a;
  --shindan-text-sub:      #5a4d6d;
  --shindan-text-mute:     #9890a3;
  --shindan-border:        rgba(107, 58, 160, 0.12);
  --shindan-border-strong: rgba(107, 58, 160, 0.28);
  --shindan-accent:        #6b3aa0;
  --shindan-accent-hover:  #4d2778;
  --shindan-gold:          #c9a961;
  --shindan-shadow:        0 4px 20px rgba(75, 32, 130, 0.08);
  --shindan-shadow-lift:   0 12px 32px rgba(75, 32, 130, 0.16);
  --shindan-radius:        14px;
}

html, body{
  background: var(--shindan-bg);
  color: var(--shindan-text);
  font-family: "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  font-weight: 400;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.home main,
body.home .shindan-header,
body.home .shindan-footer{
  background: var(--shindan-bg);
}

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

img{
  max-width: 100%;
  height: auto;
  display: block;
}

.shindan-container{
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Header ===== */
.shindan-header{
  border-bottom: 1px solid var(--shindan-border);
  background: var(--shindan-bg);
}
.shindan-header__inner{
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 64px;
}
.shindan-header__title{
  font-size: 18px;
  font-weight: 500;
  margin: 0;
  line-height: 1;
}
.shindan-header__title a{
  color: var(--shindan-text);
}
.shindan-header__nav{
  display: flex;
  gap: 24px;
}
.shindan-header__nav a{
  font-size: 14px;
  color: var(--shindan-text-sub);
  transition: color .15s ease;
}
.shindan-header__nav a:hover{
  color: var(--shindan-accent);
}

/* ===== Hero ===== */
.shindan-hero{
  position: relative;
  text-align: center;
  padding: 120px 24px;
  background-color: #1a0f24;
  background-image: url(images/hero-bg.png);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: #ffffff;
  overflow: hidden;
}
.shindan-hero::before{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15,8,30,0.35) 0%, rgba(20,10,40,0.55) 100%);
  pointer-events: none;
}
.shindan-hero__title{
  position: relative;
  z-index: 1;
  font-size: 40px;
  font-weight: 500;
  margin: 0;
  line-height: 1.4;
  color: #ffffff;
  display: inline-block;
  padding-bottom: 28px;
  letter-spacing: 0.24em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.6), 0 0 40px rgba(107,58,160,0.3);
}
.shindan-hero__title::after{
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--shindan-gold) 50%, transparent 100%);
}

/* ===== Card grid ===== */
.shindan-apps{
  padding: 16px 0 80px;
  background: var(--shindan-bg);
}
.shindan-apps__title{
  font-size: 22px;
  font-weight: 500;
  margin: 0 0 28px;
  color: var(--shindan-text);
  position: relative;
  padding-left: 16px;
  letter-spacing: 0.04em;
}
.shindan-apps__title::before{
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 1em;
  background: linear-gradient(180deg, var(--shindan-accent) 0%, var(--shindan-gold) 100%);
  border-radius: 2px;
}
.shindan-apps__grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}
.shindan-card{
  display: block;
  border: 1px solid var(--shindan-border);
  border-radius: var(--shindan-radius);
  overflow: hidden;
  background: var(--shindan-card-bg);
  box-shadow: var(--shindan-shadow);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  width: 100%;
  max-width: 480px;
  justify-self: center;
}
.shindan-card:hover{
  transform: translateY(-3px);
  box-shadow: var(--shindan-shadow-lift);
  border-color: var(--shindan-border-strong);
}
.shindan-card__thumb{
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #ebe3f5 0%, #d8c6ee 60%, #c9a3ea 100%);
  overflow: hidden;
  position: relative;
}
.shindan-card__thumb::before{
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.45), transparent 55%);
  pointer-events: none;
}
.shindan-card__thumb img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: relative;
  z-index: 1;
}
.shindan-card__body{
  padding: 22px 24px 26px;
}
.shindan-card__name{
  font-size: 19px;
  font-weight: 500;
  margin: 0 0 8px;
  color: var(--shindan-text);
  line-height: 1.4;
  letter-spacing: 0.03em;
}
.shindan-card__desc{
  font-size: 14px;
  color: var(--shindan-text-sub);
  margin: 0;
  line-height: 1.75;
}

/* ===== Leo profile ===== */
.shindan-profile{
  background: var(--shindan-surface);
  padding: 80px 0;
  position: relative;
}
.shindan-profile::before{
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--shindan-gold), transparent);
}
.shindan-profile__head{
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}
.shindan-profile__avatar{
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: #dcdcdc;
  overflow: hidden;
  flex-shrink: 0;
  border: 3px solid #ffffff;
  box-shadow: 0 4px 16px rgba(75, 32, 130, 0.18), 0 0 0 1px var(--shindan-gold);
}
.shindan-profile__avatar img{
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.shindan-profile__label{
  font-size: 13px;
  color: var(--shindan-text-mute);
  margin: 0 0 2px;
  line-height: 1.3;
}
.shindan-profile__name{
  font-size: 21px;
  font-weight: 500;
  margin: 0;
  color: var(--shindan-text);
  line-height: 1.3;
  letter-spacing: 0.05em;
}
.shindan-profile__text{
  font-size: 14px;
  line-height: 1.9;
  margin: 0 0 16px;
  color: var(--shindan-text);
}
.shindan-profile__sns{
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 16px 0 24px;
}
.shindan-profile__sns a{
  font-size: 12px;
  padding: 7px 14px;
  border: 1px solid var(--shindan-border-strong);
  border-radius: 999px;
  color: var(--shindan-text-sub);
  background: #ffffff;
  transition: border-color .2s ease, color .2s ease, background .2s ease;
  letter-spacing: 0.03em;
}
.shindan-profile__sns a:hover{
  border-color: var(--shindan-accent);
  color: var(--shindan-accent);
}

/* ===== Footer ===== */
.shindan-footer{
  background: var(--shindan-bg);
  border-top: 1px solid var(--shindan-border);
  padding: 56px 0 32px;
}
.shindan-footer__top{
  text-align: center;
  padding-bottom: 32px;
}
.shindan-footer__cta-text{
  font-size: 14px;
  color: var(--shindan-text-sub);
  margin: 0 0 16px;
}
.shindan-footer__cta-btn{
  display: inline-block;
  padding: 12px 32px;
  border: 1px solid var(--shindan-accent);
  border-radius: 999px;
  font-size: 14px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--shindan-accent) 0%, var(--shindan-accent-hover) 100%);
  box-shadow: 0 4px 16px rgba(75, 32, 130, 0.25);
  letter-spacing: 0.08em;
  transition: transform .2s ease, box-shadow .2s ease;
}
.shindan-footer__cta-btn:hover{
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(75, 32, 130, 0.35);
}
.shindan-footer__divider{
  border: 0;
  border-top: 1px solid var(--shindan-border);
  margin: 0 0 24px;
}
.shindan-footer__bottom{
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--shindan-text-mute);
}
.shindan-footer__bottom-left{
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}
.shindan-footer__bottom-left a{
  color: var(--shindan-text-sub);
}
.shindan-footer__bottom-left a:hover{
  color: var(--shindan-accent);
}
.shindan-footer__sns{
  display: flex;
  gap: 12px;
}
.shindan-footer__sns a{
  color: var(--shindan-text-sub);
  font-size: 13px;
}
.shindan-footer__sns a:hover{
  color: var(--shindan-accent);
}

/* ===== Responsive ===== */
@media (max-width: 600px){
  .shindan-hero{
    padding: 72px 24px;
  }
  .shindan-hero__title{
    font-size: 28px;
    letter-spacing: 0.18em;
  }
  .shindan-header__inner{
    height: 56px;
  }
  .shindan-header__nav{
    gap: 16px;
  }
  .shindan-footer__bottom{
    flex-direction: column;
    align-items: flex-start;
  }
  .shindan-apps__grid{
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .shindan-card{
    max-width: 100%;
  }
  .shindan-card__name{
    font-size: 17px;
  }
  .shindan-card__desc{
    font-size: 13px;
  }
}

/* ===== Motion / animations ===== */
@keyframes shindan-hero-fade-up {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes shindan-line-grow {
  from { width: 0; opacity: 0; }
  to   { width: 48px; opacity: 1; }
}
.shindan-hero__title{
  animation: shindan-hero-fade-up 1.1s cubic-bezier(.16,1,.3,1) .15s both;
}
.shindan-hero__title::after{
  animation: shindan-line-grow 1.2s cubic-bezier(.16,1,.3,1) .9s both;
}

/* scroll-triggered fade up（JSが付与） */
.shindan-anim{
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s cubic-bezier(.16,1,.3,1),
              transform .8s cubic-bezier(.16,1,.3,1);
  will-change: opacity, transform;
}
.shindan-anim-in{
  opacity: 1;
  transform: translateY(0);
}

/* カードを左から順番にズラして登場 */
.shindan-card.shindan-anim:nth-child(1) { transition-delay: 0s; }
.shindan-card.shindan-anim:nth-child(2) { transition-delay: .08s; }
.shindan-card.shindan-anim:nth-child(3) { transition-delay: .16s; }
.shindan-card.shindan-anim:nth-child(4) { transition-delay: .24s; }
.shindan-card.shindan-anim:nth-child(5) { transition-delay: .32s; }
.shindan-card.shindan-anim:nth-child(6) { transition-delay: .40s; }
.shindan-card.shindan-anim:nth-child(7) { transition-delay: .48s; }
.shindan-card.shindan-anim:nth-child(8) { transition-delay: .56s; }

/* プロフィール内の各要素を順に */
.shindan-profile__head.shindan-anim { transition-delay: 0s; }
.shindan-profile__text.shindan-anim:nth-of-type(1) { transition-delay: .15s; }
.shindan-profile__sns.shindan-anim { transition-delay: .3s; }
.shindan-profile__text.shindan-anim:nth-of-type(2) { transition-delay: .45s; }

/* アクセシビリティ：動きを減らす設定 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .shindan-hero__title,
  .shindan-hero__title::after { animation: none !important; }
  .shindan-anim {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
