@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&family=Noto+Sans+JP:wght@400;500;700&display=swap');

/* =========================================
   基本設定
   ========================================= */
html { scroll-behavior: smooth; }
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Noto Sans JP', sans-serif;
  background: linear-gradient(to bottom, #24342d 0%, #2f3f36 35%, #3b2f25 70%, #1f2a24 100%);
  background-attachment: fixed;
  color: #f5f0e8;
  line-height: 1.9;
  overflow-x: hidden;
}

/* ▼ リンク色の統一 */
a {
  color: #b7d6bc;
  text-decoration: none;
}
a:hover {
  opacity: 0.8;
}

/* アニメーション（ふわっと表示） */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.2s ease-out, transform 1.2s ease-out;
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* =========================================
   ナビゲーション
   ========================================= */
.navbar { position: fixed; top: 0; width: 100%; background: rgba(15, 25, 20, 0.85); backdrop-filter: blur(10px); z-index: 1000; }
.nav-container { max-width: 1100px; margin: 0 auto; padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; }
.logo a { font-family: 'Playfair Display', serif; font-size: 1.8rem; font-weight: 700; color: #9fd8a3; }
.nav-links { list-style: none; display: flex; gap: 20px; }
.nav-links a { color: #f5f0e8; font-size: 0.95rem; }
.nav-links a.active { color: #9fd8a3; }

/* =========================================
   ヒーロー
   ========================================= */
.hero { height: 80vh; display: flex; align-items: center; justify-content: center; text-align: center; position: relative; }
.hero-image { background-image: url("images/hero.jpg"); background-size: cover; background-position: center; }
.hero-overlay { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.3); }
.hero-content { position: relative; z-index: 1; }
.hero h1 { 
  font-family: 'Playfair Display', serif; font-size: 3.5rem; 
  background: linear-gradient(to right, #d8f3dc, #b7e4c7, #95d5b2); 
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; 
}

/* 共通コンテナ */
.container { max-width: 1100px; margin: 0 auto; padding: 120px 20px 100px; }
.section-title { text-align: center; color: #9fd8a3; margin-bottom: 40px; font-family: 'Playfair Display', serif; font-size: 1.8rem; }

/* =========================================
   プロフィール
   ========================================= */
.profile-card { 
  background: rgba(58, 74, 65, 0.75);
  border-radius: 28px; 
  padding: 40px; 
  margin-bottom: 80px; 
  text-align: center;
  color: #f5f0e8;
}

/* =========================================
   記事スライダー（PC）
   ========================================= */
.latest-posts { margin: 80px 0; }

.slider-outer {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  overflow: hidden;
  padding: 60px 0;
}

.scroll-posts {
  display: flex !important;
  align-items: center !important;
  gap: 25px !important;
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform;
}

.scroll-posts .card-link {
  display: flex;
  color: inherit;
  flex-shrink: 0;
}

.scroll-posts .article-card { 
  min-width: 280px; max-width: 280px; 
  background: rgba(58, 74, 65, 0.7);
  border-radius: 28px;
  padding: 40px;
  opacity: 0.3;
  transform: scale(0.85);
  transition: all 0.5s ease;
  display: flex;
  flex-direction: column;
}

.scroll-posts .article-card.active { 
  opacity: 1;
  transform: scale(1.1);
  background: rgba(70, 90, 80, 0.9);
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

.date { 
  font-size: 0.75rem;
  color: #b7d6bc;
  border: 1px solid rgba(159, 216, 163, 0.4);
  padding: 3px 12px;
  border-radius: 20px;
  margin-bottom: 20px;
  background: rgba(159, 216, 163, 0.05);
}

/* =========================================
   想い
   ========================================= */
.thoughts-section { margin: 100px 0; }
.thoughts-grid { 
  display: grid; 
  gap: 30px; 
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
}
.thought-card { 
  background: rgba(58, 74, 65, 0.65);
  border-radius: 28px; 
  padding: 40px; 
  color: #f5f0e8;
}
.thought-card h3 { color: #b7e4c7; margin-bottom: 15px; }

/* =========================================
   写真プレビュー
   ========================================= */
.photo-preview { margin: 120px 0 60px; text-align: center; }
.photo-scroll { 
  display: flex; gap: 15px; overflow-x: auto; padding: 20px 0; 
  scrollbar-width: none; -ms-overflow-style: none;
}
.photo-scroll::-webkit-scrollbar { display: none; }
.photo-scroll img { width: 300px; height: 200px; object-fit: cover; border-radius: 15px; flex-shrink: 0; }
.photo-more { margin-top: 30px; }
.photo-more a { color: #9fd8a3; }

/* =========================================
   Photosページ
   ========================================= */
.page-header { text-align: center; margin-bottom: 50px; width: 100%; }

.page-subtitle {
  display: block;
  text-align: center;
  color: #b7d6bc;
  font-size: 0.95rem;
  letter-spacing: 0.1em;
  margin-top: 0.5rem;
}

.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.photo-item { position: relative; overflow: hidden; border-radius: 15px; aspect-ratio: 3 / 2; background: rgba(58, 74, 65, 0.5); }
.photo-item img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s; }
.photo-item:hover img { transform: scale(1.08); }
.photo-info {
  position: absolute; bottom: 0; width: 100%; padding: 15px;
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  color: #fff; font-size: 0.75rem; opacity: 0; transition: opacity 0.3s ease;
}
.photo-item:hover .photo-info { opacity: 1; }
.back-home { text-align: center; margin-top: 50px; }
.back-home a { color: #9fd8a3; }

/* =========================================
   Contactページ
   ========================================= */
.contact-header {
  text-align: center;
  margin-top: 120px;
  margin-bottom: 40px;
}

.contact-label {
  font-size: 2rem;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  background: linear-gradient(to right, #d8f3dc, #b7e4c7, #95d5b2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
}

.contact-subtitle {
  color: #b7d6bc;
  font-size: 1rem;
  letter-spacing: 0.08em;
  margin: 0;
}

.contact-intro {
  text-align: center;
  margin-bottom: 30px;
}

.forms-wrapper {
  width: 100%;
  max-width: 640px;
  margin: 20px auto;
  background: rgba(255, 255, 255, 0.05);
  padding: 10px;
  border-radius: 20px;
}

.x-link {
  display: inline-block;
  color: #1f2a24 !important;
  background: #9fd8a3;
  font-weight: bold;
  padding: 6px 24px;
  border-radius: 6px;
  text-decoration: none;
}

.contact-subtext {
  color: #b7d6bc;
  font-size: 0.85rem;
  margin-bottom: 15px;
}

/* フッター */
footer { text-align: center; padding: 60px; color: #888; font-size: 0.9rem; }

/* =========================================
   スマホ（レスポンシブ）
   ========================================= */
@media (max-width: 768px) {

  .hero h1 { font-size: 2.2rem; }

  /* ▼ スライダーを横スクロールに */
  .slider-outer {
    width: 100%;
    left: 0;
    margin-left: 0;
    overflow-x: auto;
    padding: 20px 0;
  }

  #slider {
    display: flex;
    gap: 1rem;
    scroll-snap-type: x mandatory;
    padding-left: 1rem;
  }

  /* ▼ 正方形カード（大きめ・統一サイズ） */
  #slider .article-card {
    width: 80%;
    aspect-ratio: 1 / 1;   /* 正方形 */
    flex-shrink: 0;
    scroll-snap-align: start;

    padding: 30px 25px !important;

    overflow: hidden;      /* 飛び出し防止 */
    transform: none !important;
    opacity: 1 !important;

    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }

  /* ▼ タイトルは2行まで */
  #slider .article-card h3 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 1.1rem;
  }

  /* ▼ 本文も2行まで */
  #slider .article-card .excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 0.9rem;
  }

  #slider .article-card.active {
    transform: none !important;
    opacity: 1 !important;
  }

  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .contact-intro br { display: none; }
}
/* =========================================
   読み込みアニメーション
   ========================================= */
.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, #24342d 0%, #2f3f36 35%, #3b2f25 70%, #1f2a24 100%);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.page-loader.fade-out {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  text-align: center;
}

.loader-logo {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 700;
  color: #9fd8a3;
  margin-bottom: 20px;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.05); }
}

/* =========================================
   SNSシェアボタン
   ========================================= */
.sns-share {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sns-button {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  font-size: 1.3rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  cursor: pointer;
}

.sns-button:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.sns-button.twitter {
  background: #1DA1F2;
}

.sns-button.line {
  background: #06C755;
}

.sns-button.instagram {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

/* SNSアイコン（テキストで表示） */
.sns-button::before {
  font-weight: bold;
}

.sns-button.twitter::before {
  content: "𝕏";
  font-size: 1.2rem;
}

.sns-button.line::before {
  content: "LINE";
  font-size: 0.65rem;
  font-weight: 900;
}

.sns-button.instagram::before {
  content: "📷";
  font-size: 1.3rem;
}

/* スマホ対応 */
@media (max-width: 768px) {
  .sns-share {
    right: 10px;
    gap: 10px;
  }
  
  .sns-button {
    width: 45px;
    height: 45px;
    font-size: 1.1rem;
  }
  
  .sns-button.twitter::before {
    font-size: 1rem;
  }
  
  .sns-button.line::before {
    font-size: 0.6rem;
  }
  
  .sns-button.instagram::before {
    font-size: 1.1rem;
  }
}
/* =========================================
   ハンバーガーメニュー
   ========================================= */

/* ハンバーガーボタン（デフォルトは非表示） */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 25px;
  height: 3px;
  background: #9fd8a3;
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* ハンバーガーメニューが開いた時のアニメーション */
.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* スマホ表示時 */
@media (max-width: 768px) {
  
  /* ハンバーガーボタンを表示 */
  .hamburger {
    display: flex;
  }
  
  /* ナビゲーションリンクをデフォルトで非表示 */
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;
    background: rgba(15, 25, 20, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 40px;
    transition: right 0.4s ease;
    z-index: 1000;
    padding: 0;
  }
  
  /* メニューが開いた時 */
  .nav-links.active {
    right: 0;
  }
  
  /* リンクのスタイル調整 */
  .nav-links li {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.3s ease;
  }
  
  .nav-links.active li {
    opacity: 1;
    transform: translateX(0);
  }
  
  /* 各リンクのアニメーション遅延 */
  .nav-links.active li:nth-child(1) { transition-delay: 0.1s; }
  .nav-links.active li:nth-child(2) { transition-delay: 0.2s; }
  .nav-links.active li:nth-child(3) { transition-delay: 0.3s; }
  .nav-links.active li:nth-child(4) { transition-delay: 0.4s; }
  
  .nav-links a {
    font-size: 1.2rem;
  }
  
  /* オーバーレイ（背景をタップで閉じる用） */
  .nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
  }
  
  .nav-overlay.active {
    display: block;
    opacity: 1;
  }
}
