/* =========================
  カラーテーマ
========================= */
:root {
  --bg-main: #fffaf4;      /* ほんのり黄色 */
  --bg-sub: #fff1f5;       /* 薄ピンク */
  --accent: #f9a8d4;       /* ピンク */
  --accent-soft: #fde68a;  /* やさしい黄色 */
  --text-main: #444;
}

/* =========================
  全体
========================= */
body {
  margin: 0;
  padding-top: 110px;
  font-family: 'Zen Maru Gothic', sans-serif;
    background-attachment: fixed;
  position: relative;
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.7;
}

/* 背景レイヤー */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  animation: bgZoom 3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;

  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(2px);
}

/* ページごとに画像切り替え */
.page-index::before {
  background-image: url("../img/背景用１.jpg");
}

.page-about::before {
  background-image: url("../img/背景用２.jpg");
}




@keyframes bgZoom {
  0% {
    transform: scale(1.2);
    filter: blur(10px) brightness(0.6);
  }
  100% {
    transform: scale(1);
    filter: blur(0) brightness(1);
  }
}

/* =========================
  ヘッダー
========================= */
header {
  position: fixed;
  top: 0;
  width: 100%;

  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 30px;

  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(10px);

  border-radius: 0 0 20px 20px;
  z-index: 999;
}

/* ハンバーガーメニュー用オーバーレイ */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: 0.3s;
  z-index: 998;
}

.overlay.active {
  opacity: 1;
  pointer-events: auto;
}

/* ロゴ */
.logo img {
  height: 60px;
}

/* ナビ */
.nav a {
  margin: 0 12px;
  text-decoration: none;
  color: #555;
  font-weight: 500;
}

/* ホバー */
.nav a:hover {
  color: #f472b6;
}

/* =========================
  ハンバーガー
========================= */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 22px;
  cursor: pointer;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 3px;
  background: #555;
  border-radius: 5px;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  width: 100%;
  max-width: 1100px;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  margin: 40px auto 0;
  transition: margin 0.3s;
  background: linear-gradient(to bottom, #111, #222);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
}

header.scrolled + .hero {
  margin-top: 10px;
}

.hero h1 { 
  font-family: 'Yomogi', cursive;
  font-size: clamp(32px, 5vw, 48px);
}


section h2 {
  font-family: 'Yomogi', cursive;
  letter-spacing: 1px;
  color: #333333; /* 少し明るい色 */
  text-shadow: 2px 2px 6px rgba(0,0,0,0.4);
}

/* ===== 背景 ===== */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;

  /* 画像 */
  background: url("../img/けいちゃん2.jpg") no-repeat center;
  background-size: cover;

  /* 最初は見えない */
  opacity: 0.4;
  z-index: 0;

  /* 少しズームした状態から */
  transform: scale(1.2);

  /* アニメーション */
  animation: flowerFadeIn 3s ease forwards;
}

/* ===== テキストを前面に ===== */
.hero h1,
.hero p {  
  position: relative;
  z-index: 1;
}

/* ===== テキストも少しアニメーション ===== */
.hero h1 {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 600;
  letter-spacing: 0.05em;
  line-height: 1.8;
  margin-bottom: 10px;
  opacity: 0;
  animation: textFade 2s ease forwards;
  animation-delay: 1s;
}

.hero p {
  font-size: clamp(1rem, 2vw, 1.3rem);
  line-height: 1.8;
  margin-top: 10px;
  opacity: 0;
  animation: textFade 2s ease forwards;
  animation-delay: 1.5s;
}

/* ===== アニメーション定義 ===== */

/* 花がふわっと表示 */
@keyframes flowerFadeIn {
  0% {
    opacity: 0;
    transform: scale(1.2);
  }
  100% {
    opacity: 0.4; /* ←ここで濃さ調整 */
    transform: scale(1);
  }
}

/* テキスト */
@keyframes textFade {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================
  セクション
========================= */
section {
  max-width: 1000px;
  margin: 0 auto;
  padding: 100px 20px;
}

/* タイトル */
.section-title {
  font-size: clamp(1rem, 2vw, 1.3rem);
  margin-bottom: 40px;
  position: relative;
}

/* やさしいライン */
.section-title::after {
  content: "";
  width: 50px;
  height: 4px;
  background: linear-gradient(90deg, #f9a8d4, #fde68a);
  display: block;
  margin-top: 10px;
  border-radius: 5px;
}

section p {
  font-size: clamp(16px, 2vw, 18px);
}


/* About以降の見出し */
section h2 {
  position: relative;
  padding-left: 36px;
}

section h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

/* 差し替えだけ書く */
#about h2::before { background-image: url("../img/どりじゃ.jpg"); }
#photo-gallery h2::before { background-image: url("../img/オルフェ.jpg"); }
#works h2::before { background-image: url("../img/すてご.jpg"); }
#skills h2::before { background-image: url("../img/なかやま.jpg"); }
#experience h2::before { background-image: url("../img/ごるし.jpg"); }
#contact h2::before { background-image: url("../img/まめちん.jpg"); }



/* =========================
  Worksカード（丸み＋やさしさ）
========================= */
.works-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.work-row {
  display: flex;
  align-items: center;

  background: #ffffff;
  border-radius: 20px;

  padding: 15px;
  gap: 15px;

  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
  transition: 0.3s;
}

/* ふわっと浮く */
.work-row:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* 画像 */
.work-thumb img {
  width: 150px;
  height: 100px;
  object-fit: cover;
  border-radius: 15px;
}

.work-thumb img.work2 {
  width: 100%;
  height: 100px;
  object-fit: contain;
}

/* テキスト */
.work-info h3 {
  font-size: 20px;
  margin-bottom: 5px;
}

.work-desc {
  font-size: 15px;
  opacity: 0.7;
  line-height: 1.4;
}

/* タグ */
.work-meta span {
  background: #fff1f5;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  margin-right: 5px;
}

/* =========================
  ボタン
========================= */
.btn {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 14px;

  background: linear-gradient(135deg, #f9a8d4, #fde68a);
  color: #444;

  border-radius: 999px;
  font-size: 12px;
  text-decoration: none;

  transition: 0.3s;
}

.btn:hover {
  transform: translateY(-2px);
}

/* =========================
  About
========================= */
.about-container {
  gap: 40px;
  align-items: center;
  flex-wrap: wrap;
}

.about-image img {
  width: 220px;
  border-radius: 50%;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.about-section .about-content {
  align-items: center;
  gap: 30px;
}

/* 画像 */
.about-section .about-content img {
  width: 200px;
  height: auto;
  border-radius: 20px;
}

/* テキスト */
.about-section .about-content p {
  flex: 1;
}

/* About全体を横並び */
.about-wrapper {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

/* 左側 */
.about-content {
  flex: 1;
}

/* 右側（timeline） */
.about-timeline {
  flex: 1.2;
  padding: 0;
}

/* タイムラインをコンパクトに */
.timeline {
  transform: scale(0.85);
  transform-origin: top left;
}

/* スマホ対応 */
@media (max-width: 768px) {
  .about-wrapper {
    flex-direction: column;
  }

  .timeline {
    transform: scale(1);
  }
}


/* =========================
  Skills
========================= */
.skill-card {
  max-width: 100%;
  margin: 0;
  padding: 30px;
  background: rgba(255,255,255,0.4);
  backdrop-filter: blur(12px);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  transition: 0.3s;
}

.skill-card:hover {
  transform: translateY(-5px);
}

/* 所感エリア全体 */
.skill-comments {
  margin-top: 20px;
  padding: 16px;
  background: #fffdf8;
  border-radius: 16px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

/* 各項目 */
.skill-item {
  margin-bottom: 12px;
  position: relative;
  padding-left: 20px;
}

.skill-item::before {
  content: "🌿";
  position: absolute;
  left: 0;
  top: 2px;
}

.skill-item:last-child {
  margin-bottom: 0;
}

.skill-item:hover {
  transform: translateX(4px);
  transition: 0.3s;
}

/* スキル名 */
.skill-name {
  display: inline-block;
  font-weight: bold;
  color: #f472b6; /* ピンク系 */
  margin-bottom: 4px;
}

/* テキスト */
.skill-item p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #555;
}

.skill-item:nth-child(1) .skill-name { color: #f59e0b; }
.skill-item:nth-child(2) .skill-name { color: #ec4899; }
.skill-item:nth-child(3) .skill-name { color: #3b82f6; }

/* チャートサイズ調整 */
#skillChart {
  width: 100% !important;
  height: auto !important;
}

/* ===== タイムライン全体 ===== */
.about-timeline {
  background: rgba(255,255,255,0.3);
  border-radius: 20px;
  padding: 20px;
  backdrop-filter: blur(10px);
  position: relative;
}

/* 中央の線 */
.timeline {
  position: relative;
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  width: 200px;
  height: 100%;
  transform: translateX(-50%);
  pointer-events: none;
}

.timeline-line path {
  fill: none;
  stroke: url(#lineGradient);
  stroke-width: 4;
  opacity: 0.6;
}

.timeline::before {
  display: none;
}

.timeline-item::before {
  content: "";
  position: absolute;
  width: 40px;
  height: 2px;
  background: #86efac;
  top: 50%;
}

/* 各アイテム */
.timeline-item {
  width: 50%;
  padding: 20px;
  position: relative;
}

.timeline-item span {
  font-size: 30px;

}

/* 左 */
.timeline-item.left .bubble{
  font-size: 20px;
  left: 0;
  text-align: right;
  transform: rotate(-8deg);
}

.timeline-item.left p{
  font-size: 20px;
}

/* 右 */
.timeline-item.right .bubble{
  font-size: 20px;
  transform: rotate(8deg);
  left: 50%;
}

.timeline-item.right p {
  font-size: 20px;
}

.timeline-item:nth-child(1) .bubble { background: #d9f99d; }
.timeline-item:nth-child(2) .bubble { background: #bbf7d0; }
.timeline-item:nth-child(3) .bubble { background: #86efac; }
.timeline-item:nth-child(4) .bubble { background: #4ade80; }

/* バブル */
.bubble {
  display: inline-block;
  padding: 16px 22px;
  border-radius: 60% 40% 55% 45% / 55% 45% 60% 40%;
  background: linear-gradient(135deg, #bbf7d0, #86efac);
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  backdrop-filter: blur(10px);  
  color: #3a393b;
  position: relative;
  max-width: 320px;
  transition: all 0.4s ease;
}

@keyframes leafFloat {
  0% { transform: rotate(-5deg) translateY(0); }
  50% { transform: rotate(5deg) translateY(-5px); }
  100% { transform: rotate(-5deg) translateY(0); }
}

.timeline-item.left .bubble {
  animation: leafFloat 6s ease-in-out infinite;
}

.timeline-item.right .bubble {
  animation: leafFloat 7s ease-in-out infinite reverse;
}


/* ポップ感 */
.bubble:hover {
  transform: scale(1.05);
}

/* 年 */
.year {
  display: block;
  font-size: 1.4rem;
  font-weight: bold;
  margin-bottom: 5px;
}

/* 左葉 → 茎へ */
.timeline-item.left::before {
  right: 50%;
  transform: translateY(-50%);
}

/* 右葉 → 茎へ */
.timeline-item.right::before {
  left: 50%;
  transform: translateY(-50%);
}

/* 左の三角 */
.timeline-item.left .bubble::after {
  content: "";
  position: absolute;
  right: -10px;
  top: 20px;
  border: 10px solid transparent;
  border-left-color: rgba(255,255,255,0.1);
}

/* 右の三角 */
.timeline-item.right .bubble::after {
  content: "";
  position: absolute;
  left: -10px;
  top: 20px;
  border: 10px solid transparent;
  border-right-color: rgba(255,255,255,0.1);
}

.timeline.no-line::before {
  display: none;
}

@media (max-width: 768px) {
  .timeline::before {
    left: 10px;
  }

  .timeline-item {
    width: 100%;
    padding-left: 40px;
  }

  .timeline-item.right,
  .timeline-item.left {
    left: 0;
    text-align: left;
  }

  .bubble {
    max-width: 100%;
  }
}

/* ギャラリー */
.gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* PCは2枚 */
  gap: 20px;
}

.photo-gallery {
  margin-top: 80px;
}

/* スマホ：1枚 */
@media (max-width: 768px) {
  .gallery {
    grid-template-columns: 1fr;
  }
}

/* カード */
.photo-card {
  position: relative;
  text-align: center;
}

/* 正方形 */
.photo-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
  transition: transform 0.3s ease;
}

/* タイトル */
.photo-card p {
  position: absolute;
  left: 50%;
  bottom: -30px;
  transform: translateY(10%);
  opacity: 0;
  transition: all 0.3s ease;
  font-size: 15px;
}

/* ホバー */
.photo-card:hover img {
  transform: scale(0.92);
  box-shadow: 0 10px 24px rgba(0,0,0,0.25);
}

.photo-card:hover p {
  bottom: -10px;
  opacity: 1;
  transform: translateY(0);
}



/* =========================
  メール
========================= */

#contact {
padding: 80px 20px;
}

.contact-form {
max-width: 600px;
margin: 0;
padding: 40px;
background: white;
border-radius: 30px;
box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.form-group {
margin-bottom: 20px;
display: grid;
grid-template-columns: 2fr 2fr; /* ← 2倍ずつ */
gap: 10px;
}

.contact-form input,
.contact-form textarea {
width: 100%;
padding: 12px;
border: 1px solid #ccc;
border-radius: 22px;
background: #f1f3f6;
font-size: 14px;
outline: none;
}

.contact-form textarea {
  width: 100%;
  height: 150px;
  margin-top: 10px;
  border-radius: 20px;
  min-height: 120px;
  resize: none;
}

.contact-form button {
width: 100%;
padding: 15px;
border: 1px solid #ccc;
border-radius: 999px;
background: linear-gradient(135deg, #ff7eb3, #ff758c);
color: white;
font-size: 16px;
cursor: pointer;
transition: 0.3s;
}

.contact-form button {
transform: translateY(-2px);
box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* =========================
  フッター
========================= */
footer {
  text-align: center;
  padding: 30px;
  background: #fff1f5;
  border-radius: 20px 20px 0 0;
}

/* =========================
  スマホ
========================= */
@media (max-width: 768px) {

  .nav {
    position: fixed;
    top: 0;
    right: -100%;

    width: 70%;
    height: 100vh;

    background: #fff;
    border-radius: 20px 0 0 20px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    transition: 0.3s;
  }

  .nav.active {
    right: 0;
  }

  .hamburger {
    display: flex;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
  }

  .work-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .work-thumb img {
    width: 100%;
    height: auto;
  }
 
  .about-section .about-content {
    flex-direction: column;
    text-align: center;
  }


}