/**
 * 日本の占いスタイル
 * Japanese Fortune Teller CSS
 */

/* メインスタイル */
.japanese-fortune-container {
    font-family: 'Noto Sans JP', sans-serif;
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.title-elegant {
    font-family: 'Playfair Display', 'Noto Sans JP', serif;
    letter-spacing: -0.02em;
}

.fortune-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.fortune-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.english-title {
    font-size: 1rem;
    color: #666;
    margin-top: 0.25rem;
}

.fortune-date {
    color: #666;
    font-size: 1rem;
}

/* テキストグラデーション */
.text-gradient {
    background: linear-gradient(to right, #c45f24, #e67e22);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* 運勢カード */
.fortune-card-container {
    margin: 2rem 0;
}

.fortune-card {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    min-height: 200px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
}

.fortune-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.fortune-text {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.japanese-text {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.english-text {
    color: #666;
    font-size: 1rem;
}

/* ローディング */
.fortune-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 150px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #c45f24;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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

/* アニメーション */
.reveal-animation {
    opacity: 0;
    transform: translateY(20px);
    animation: reveal 0.8s forwards;
}

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

@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

@keyframes slideUp {
    0% { transform: translateY(20px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-in-out;
}

.animate-slide-up {
    animation: slideUp 0.6s ease-out;
}

/* エラー表示 */
.fortune-error {
    text-align: center;
    padding: 2rem;
}

.error-text {
    color: #d63031;
    margin-bottom: 1rem;
}

.retry-button {
    background-color: #e67e22;
    color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Noto Sans JP', sans-serif;
    transition: background-color 0.3s;
}

.retry-button:hover {
    background-color: #d35400;
}

/* フォーチュンメタ情報 */
.fortune-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    flex-wrap: wrap;
}

.fortune-rating {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.rating-label {
    margin-right: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.rating-stars {
    display: flex;
}

.star {
    color: #ddd;
    font-size: 1.2rem;
    margin-right: 0.25rem;
}

.star.active {
    color: #f39c12;
}

.fortune-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.category-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    background-color: #f5f5f5;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
}

.category-badge.highlighted {
    background-color: #fff3e0;
    color: #e67e22;
}

.category-badge .japanese-text {
    font-size: 0.85rem;
    margin-right: 0.25rem;
    margin-bottom: 0;
}

.category-badge .english-text {
    font-size: 0.75rem;
}

/* アクションボタン */
.fortune-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.action-button {
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    cursor: pointer;
    font-family: 'Noto Sans JP', sans-serif;
    display: flex;
    align-items: center;
    transition: all 0.3s;
}

.refresh-button {
    background-color: #e67e22;
    color: white;
    border: none;
}

.refresh-button:hover {
    background-color: #d35400;
}

.share-button {
    background-color: white;
    color: #333;
    border: 1px solid #ddd;
}

.share-button:hover {
    background-color: #f9f9f9;
    border-color: #ccc;
}

.button-icon {
    margin-right: 0.5rem;
    font-size: 1.1rem;
}

.action-button.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.action-button.loading .button-icon {
    animation: spin 1s linear infinite;
}

/* 星座・九星気学セクション */
.fortune-links-section {
    margin: 3rem 0;
}

.section-title {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.section-title .icon {
    margin-right: 0.75rem;
    font-size: 1.8rem;
}

.zodiac-grid,
.kyusei-grid {
    display: grid;
    gap: 0.75rem;
}

.zodiac-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
}

.kyusei-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.zodiac-link,
.kyusei-link {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    background-color: white;
    border: 1px solid #eee;
    border-radius: 6px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s;
}

.zodiac-link:hover,
.kyusei-link:hover {
    background-color: #fff8e1;
    border-color: #ffe082;
    color: #e67e22;
    transform: translateY(-2px);
}

.zodiac-symbol {
    margin-right: 0.5rem;
    font-size: 1.2rem;
}

/* 詳細ページ共通スタイル */
.page-navigation {
    margin-bottom: 2rem;
}

.back-link, 
.back-button {
    display: inline-flex;
    align-items: center;
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.back-link:hover, 
.back-button:hover {
    color: #e67e22;
}

.back-icon {
    margin-right: 0.5rem;
}

.navigation-bottom {
    text-align: center;
    margin: 2rem 0;
}

.back-button {
    padding: 0.75rem 1.5rem;
    background-color: #f5f5f5;
    border-radius: 30px;
    display: inline-flex;
    transition: all 0.3s;
}

.back-button:hover {
    background-color: #eee;
}

/* 星座ページスタイル */
.zodiac-title {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1.5rem 0;
}

.zodiac-symbol {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
}

.zodiac-lucky-points,
.kyusei-lucky-points {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
}

.lucky-title {
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.lucky-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.lucky-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.lucky-icon {
    margin-right: 0.75rem;
    font-size: 1.2rem;
}

.lucky-label {
    font-weight: 500;
    margin-right: 0.5rem;
}

.lucky-value {
    color: #666;
}

/* 九星気学ページスタイル */
.kyusei-title {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1.5rem 0;
}

.kyusei-element {
    display: flex;
    align-items: center;
    margin: 0.5rem 0;
    font-size: 1.2rem;
}

.element-emoji {
    font-size: 1.5rem;
    margin-right: 0.5rem;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .fortune-meta {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .fortune-rating,
    .fortune-categories {
        margin-bottom: 1rem;
    }
    
    .zodiac-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    .kyusei-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
    
    .zodiac-symbol {
        font-size: 2.5rem;
    }

    .fortune-title {
        font-size: 1.75rem;
    }
    
    .kyusei-element {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .fortune-title {
        font-size: 1.75rem;
    }
    
    .fortune-card {
        padding: 1.5rem;
    }
    
    .zodiac-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .kyusei-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .zodiac-symbol {
        font-size: 2rem;
    }
    
    .fortune-title {
        font-size: 1.5rem;
    }
    
    .kyusei-element {
        font-size: 1rem;
    }
    
    .lucky-item {
        flex-wrap: wrap;
    }
    
    .lucky-label {
        width: 100%;
        margin-bottom: 0.25rem;
    }
}