/* ========================================
   スクロールアニメーション
======================================== */

/* パララックス効果 */
.parallax-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    will-change: transform;
}

/* 数字カウントアップ */
.count-up {
    display: inline-block;
}

/* テキストグラデーションアニメーション */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.gradient-text {
    background: linear-gradient(270deg, var(--neon-green), var(--white), var(--neon-green));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 3s ease infinite;
}

/* グロー効果 */
@keyframes glow {
    0% {
        box-shadow: 0 0 5px rgba(193, 255, 0, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(193, 255, 0, 0.8), 0 0 30px rgba(193, 255, 0, 0.4);
    }
    100% {
        box-shadow: 0 0 5px rgba(193, 255, 0, 0.5);
    }
}

.glow-effect {
    animation: glow 2s ease-in-out infinite;
}

/* パルスアニメーション */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.pulse-animation {
    animation: pulse 2s ease-in-out infinite;
}

/* タイピングエフェクト */
@keyframes typing {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

.typing-effect {
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid var(--neon-green);
    animation: typing 3s steps(40, end), blink 0.75s step-end infinite;
}

/* ローディングアニメーション */
@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(193, 255, 0, 0.1);
    border-top-color: var(--neon-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* ウェーブアニメーション */
@keyframes wave {
    0%, 100% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-10px);
    }
    75% {
        transform: translateY(10px);
    }
}

.wave-animation {
    display: inline-block;
    animation: wave 2s ease-in-out infinite;
}

.wave-animation:nth-child(2) {
    animation-delay: 0.1s;
}

.wave-animation:nth-child(3) {
    animation-delay: 0.2s;
}

.wave-animation:nth-child(4) {
    animation-delay: 0.3s;
}

/* スライドアニメーション */
@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInFromBottom {
    from {
        opacity: 0;
        transform: translateY(100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ズームアニメーション */
@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes zoomOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.5);
    }
}

/* フリップアニメーション */
@keyframes flipInX {
    from {
        transform: perspective(400px) rotateX(90deg);
        opacity: 0;
    }
    40% {
        transform: perspective(400px) rotateX(-10deg);
    }
    70% {
        transform: perspective(400px) rotateX(10deg);
    }
    to {
        transform: perspective(400px) rotateX(0);
        opacity: 1;
    }
}

@keyframes flipInY {
    from {
        transform: perspective(400px) rotateY(90deg);
        opacity: 0;
    }
    40% {
        transform: perspective(400px) rotateY(-10deg);
    }
    70% {
        transform: perspective(400px) rotateY(10deg);
    }
    to {
        transform: perspective(400px) rotateY(0);
        opacity: 1;
    }
}

/* バウンスアニメーション */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-30px);
    }
    60% {
        transform: translateY(-15px);
    }
}

.bounce-animation {
    animation: bounce 2s infinite;
}

/* フェードアニメーション（スクロール用） */
.fade-in {
    opacity: 0;
    transition: opacity 1s ease;
}

.fade-in.visible {
    opacity: 1;
}

.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-down {
    opacity: 0;
    transform: translateY(-30px);
    transition: all 0.8s ease;
}

.fade-in-down.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.8s ease;
}

.fade-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(30px);
    transition: all 0.8s ease;
}

.fade-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* スケールアニメーション */
.scale-in {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.8s ease;
}

.scale-in.visible {
    opacity: 1;
    transform: scale(1);
}

/* 回転アニメーション */
.rotate-in {
    opacity: 0;
    transform: rotate(-180deg);
    transition: all 0.8s ease;
}

.rotate-in.visible {
    opacity: 1;
    transform: rotate(0);
}

/* スタガードアニメーション（順番に表示） */
.stagger-item {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.stagger-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.stagger-item:nth-child(1) { transition-delay: 0.1s; }
.stagger-item:nth-child(2) { transition-delay: 0.2s; }
.stagger-item:nth-child(3) { transition-delay: 0.3s; }
.stagger-item:nth-child(4) { transition-delay: 0.4s; }
.stagger-item:nth-child(5) { transition-delay: 0.5s; }
.stagger-item:nth-child(6) { transition-delay: 0.6s; }

/* ホバーエフェクト */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(193, 255, 0, 0.2);
}

.hover-grow {
    transition: transform 0.3s ease;
}

.hover-grow:hover {
    transform: scale(1.05);
}

.hover-shrink {
    transition: transform 0.3s ease;
}

.hover-shrink:hover {
    transform: scale(0.95);
}

/* ボーダーアニメーション */
.border-animation {
    position: relative;
    overflow: hidden;
}

.border-animation::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--neon-green), transparent);
    transition: left 0.5s ease;
}

.border-animation:hover::before {
    left: 100%;
}

/* テキストハイライトアニメーション */
.text-highlight {
    position: relative;
    display: inline-block;
}

.text-highlight::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--neon-green);
    transition: width 0.3s ease;
}

.text-highlight:hover::after {
    width: 100%;
}

/* ブラーエフェクト */
.blur-in {
    filter: blur(10px);
    opacity: 0;
    transition: all 0.8s ease;
}

.blur-in.visible {
    filter: blur(0);
    opacity: 1;
}

/* 3D変形 */
.transform-3d {
    transform-style: preserve-3d;
    transition: transform 0.5s ease;
}

.transform-3d:hover {
    transform: rotateY(10deg) rotateX(10deg);
}