/* ============================================
   串友 Kushitomo Bali - Premium Animations
   高級感を演出するアニメーション
   ============================================ */

/* ==========================================
   1. フェードインアニメーション（基本）
   ========================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ==========================================
   2. スクロールトリガー用クラス
   ========================================== */
.animate-on-scroll {
    opacity: 0;
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.animate-on-scroll.animated {
    opacity: 1;
    animation-duration: 1s;
    animation-fill-mode: both;
    animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* アニメーションバリエーション */
.fade-in.animated {
    animation-name: fadeIn;
}

.fade-in-up.animated {
    animation-name: fadeInUp;
}

.fade-in-left.animated {
    animation-name: fadeInLeft;
}

.fade-in-right.animated {
    animation-name: fadeInRight;
}

.scale-in.animated {
    animation-name: scaleIn;
}

/* 遅延クラス */
.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

.delay-400 {
    animation-delay: 0.4s;
}

.delay-500 {
    animation-delay: 0.5s;
}

/* ==========================================
   3. ホバーエフェクト
   ========================================== */

/* ナビゲーションリンク */
.nav a {
    position: relative;
    transition: color 0.3s ease;
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #8B4513;
    transition: width 0.3s ease, left 0.3s ease;
}

.nav a:hover::after {
    width: 100%;
    left: 0;
}

.nav a:hover {
    color: #8B4513;
}

/* ボタンホバー */
.btn-cus a,
.btn-cus2 a {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-cus a::before,
.btn-cus2 a::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(139, 69, 19, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-cus a:hover::before,
.btn-cus2 a:hover::before {
    width: 300px;
    height: 300px;
}

.btn-cus a:hover,
.btn-cus2 a:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

/* 画像ホバー */
.photo img,
.photo2 img,
.photo3 img {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1), filter 0.6s ease;
}

.photo:hover img,
.photo2:hover img,
.photo3:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* メニュー項目ホバー */
.menu-price .list dl {
    transition: background-color 0.3s ease, transform 0.2s ease;
    padding: 5px 10px;
    border-radius: 4px;
}

.menu-price .list dl:hover {
    background-color: rgba(139, 69, 19, 0.05);
    transform: translateX(5px);
}

/* ==========================================
   4. パララックス効果
   ========================================== */
.parallax-section {
    position: relative;
    overflow: hidden;
}

.parallax-bg {
    position: absolute;
    top: -50px;
    left: 0;
    width: 100%;
    height: calc(100% + 100px);
    background-size: cover;
    background-position: center;
    will-change: transform;
    transition: transform 0.1s ease-out;
}

/* ==========================================
   5. ローディングアニメーション
   ========================================== */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }

    100% {
        background-position: 1000px 0;
    }
}

.loading-shimmer {
    animation: shimmer 2s infinite;
    background: linear-gradient(to right, #f6f7f8 0%, #edeef1 20%, #f6f7f8 40%, #f6f7f8 100%);
    background-size: 2000px 100%;
}

/* ==========================================
   6. テキストアニメーション
   ========================================== */
.text-reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.text-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* 見出しの下線アニメーション */
h2::after,
h3::after {
    content: '';
    display: block;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #8B4513, transparent);
    margin-top: 10px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

h2.animated::after,
h3.animated::after {
    width: 60px;
}

/* ==========================================
   7. スムーススクロール
   ========================================== */
html {
    scroll-behavior: smooth;
}

/* ==========================================
   8. レスポンシブ対応
   ========================================== */
@media (max-width: 768px) {

    /* モバイルではアニメーションを軽量化 */
    .animate-on-scroll.animated {
        animation-duration: 0.6s;
    }

    /* パララックスを無効化（パフォーマンス向上） */
    .parallax-bg {
        position: static;
        height: 100%;
    }
}

/* モーション削減の設定に対応 */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}