/* 
 * シンギュラリティ カスタムスタイル
 * 追加のカスタマイズ用CSSファイル
 */

/* アニメーション */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* セクションのアニメーション */
.section {
    animation: fadeIn 0.8s ease-out;
}

/* カードのホバーエフェクト強化 */
.feature-card,
.liver-card,
.column-card,
.story-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.feature-card:hover,
.liver-card:hover,
.column-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* グラデーション背景 */
.gradient-bg-1 {
    background: linear-gradient(135deg, #81D8D0, #FF6B9D);
}

.gradient-bg-2 {
    background: linear-gradient(135deg, #FF6B9D, #81D8D0);
}

.gradient-bg-3 {
    background: linear-gradient(135deg, #333333, #81D8D0);
}

/* テキストグラデーション */
.gradient-text {
    background: linear-gradient(90deg, #81D8D0, #FF6B9D);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* スクロールバーのカスタマイズ */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #F5F5F5;
}

::-webkit-scrollbar-thumb {
    background: #81D8D0;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #FF6B9D;
}

/* 選択時のハイライト */
::selection {
    background: #81D8D0;
    color: #fff;
}

::-moz-selection {
    background: #81D8D0;
    color: #fff;
}

/* フォーカス時のアウトライン */
a:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 2px solid #81D8D0;
    outline-offset: 2px;
}

/* ローディングアニメーション */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(129, 216, 208, 0.3);
    border-radius: 50%;
    border-top-color: #81D8D0;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* バッジ */
.badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
}

.badge-primary {
    background: #81D8D0;
    color: #fff;
}

.badge-secondary {
    background: #FF6B9D;
    color: #fff;
}

.badge-outline {
    background: transparent;
    border: 2px solid #81D8D0;
    color: #81D8D0;
}

/* アラート */
.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.alert-info {
    background: rgba(129, 216, 208, 0.1);
    border-left: 4px solid #81D8D0;
    color: #333;
}

.alert-success {
    background: rgba(76, 175, 80, 0.1);
    border-left: 4px solid #4CAF50;
    color: #333;
}

.alert-warning {
    background: rgba(255, 107, 157, 0.1);
    border-left: 4px solid #FF6B9D;
    color: #333;
}

/* 画像のレイジーロード効果 */
img.lazy {
    opacity: 0;
    transition: opacity 0.3s;
}

img.lazy.loaded {
    opacity: 1;
}

/* プログレスバー */
.progress-bar {
    width: 100%;
    height: 4px;
    background: #F5F5F5;
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #81D8D0, #FF6B9D);
    transition: width 0.3s ease;
}

/* ツールチップ */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 120px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 5px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* モーダル背景 */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: none;
}

.modal-backdrop.active {
    display: block;
}

/* カスタムチェックボックス */
.custom-checkbox {
    display: inline-block;
    position: relative;
    padding-left: 30px;
    cursor: pointer;
}

.custom-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.custom-checkbox .checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 20px;
    width: 20px;
    background-color: #F5F5F5;
    border: 2px solid #81D8D0;
    border-radius: 4px;
}

.custom-checkbox input:checked ~ .checkmark {
    background-color: #81D8D0;
}

.custom-checkbox .checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked ~ .checkmark:after {
    display: block;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* パンくずリスト */
.breadcrumbs {
    padding: 15px 0;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: #81D8D0;
    margin-right: 10px;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs span {
    margin-right: 10px;
    color: #999;
}

/* SNSシェアボタン */
.share-buttons {
    display: flex;
    gap: 10px;
    margin: 30px 0;
}

.share-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #fff;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.share-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.share-button.twitter {
    background: #1DA1F2;
}

.share-button.facebook {
    background: #4267B2;
}

.share-button.line {
    background: #00B900;
}

.share-button.copy {
    background: #81D8D0;
}

/* 印刷用スタイル */
@media print {
    .site-header,
    .site-footer,
    .fixed-cta,
    .share-buttons {
        display: none;
    }
    
    body {
        background: white;
    }
    
    a {
        text-decoration: underline;
    }
}

/* ダークモード対応の準備 */
@media (prefers-color-scheme: dark) {
    /* 将来的なダークモード対応用 */
}

/* アクセシビリティ向上 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* スキップリンク */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #81D8D0;
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 100;
}

.skip-link:focus {
    top: 0;
}
