/**
 * MAL v4.3 Enterprise - TERASS Picks風物件詳細表示スタイル
 * 物件詳細・概要・図面・画像統合表示スタイル
 */

/* 物件詳細モーダル */
#property-detail-modal {
    backdrop-filter: blur(8px);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.property-detail-modal-content {
    animation: modalSlideUp 0.3s ease-out;
}

@keyframes modalSlideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 画像ギャラリー */
.image-gallery-main {
    position: relative;
    overflow: hidden;
}

.image-gallery-main img {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.image-gallery-main:hover img {
    transform: scale(1.02);
}

.image-thumbnail {
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.image-thumbnail:hover {
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.image-thumbnail.active {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(44, 90, 160, 0.3);
}

/* 物件情報セクション */
.property-info-section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    border: 1px solid #e2e8f0;
}

.property-info-section h4 {
    color: var(--primary-color);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.property-info-section h4 i {
    width: 20px;
    text-align: center;
}

/* 基本情報グリッド */
.property-basic-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.info-item {
    background: #f8fafc;
    border-radius: 8px;
    padding: 12px;
    border-left: 4px solid var(--primary-color);
}

.info-item-label {
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.info-item-value {
    color: #1e293b;
    font-size: 16px;
    font-weight: 600;
}

.price-value {
    color: var(--primary-color);
    font-size: 20px;
}

/* 説明テキスト */
.property-description {
    line-height: 1.7;
    color: #475569;
    background: #f1f5f9;
    padding: 16px;
    border-radius: 8px;
    border-left: 4px solid #94a3b8;
}

/* 市場分析セクション */
.market-analysis {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 8px;
    padding: 16px;
    border: 1px solid #0ea5e9;
}

.market-analysis-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e2e8f0;
}

.market-analysis-item:last-child {
    border-bottom: none;
}

.market-analysis-label {
    color: #475569;
    font-weight: 500;
}

.market-analysis-value {
    color: #0f172a;
    font-weight: 600;
}

/* アクションボタン */
.property-action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
    min-height: 48px;
}

.property-action-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.property-action-button:active {
    transform: translateY(0);
}

/* ボタンバリエーション */
.btn-favorite {
    background: linear-gradient(135deg, #ec4899 0%, #be185d 100%);
    color: white;
}

.btn-favorite:hover {
    background: linear-gradient(135deg, #db2777 0%, #9d174d 100%);
}

.btn-contact {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.btn-contact:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
}

.btn-share {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
}

.btn-share:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
}

.btn-print {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.btn-print:hover {
    background: linear-gradient(135deg, #4b5563 0%, #374151 100%);
}

.btn-detail {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
}

.btn-detail:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
}

/* 間取り図表示 */
.floor-plan-container {
    background: #f8fafc;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
}

.floor-plan-container img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.floor-plan-container img:hover {
    transform: scale(1.05);
}

/* お問い合わせモーダル */
#contact-modal {
    backdrop-filter: blur(4px);
    animation: modalFadeIn 0.3s ease-out;
}

.contact-form {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    animation: modalSlideUp 0.3s ease-out;
}

.contact-form input,
.contact-form textarea {
    border: 2px solid #e2e8f0;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(44, 90, 160, 0.1);
}

/* 通知システム */
.notification {
    animation: notificationSlideIn 0.3s ease-out;
}

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

.notification.success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.notification.error {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

.notification.info {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
}

/* レスポンシブデザイン */
@media (max-width: 1024px) {
    .property-detail-modal-content {
        grid-template-columns: 1fr;
    }
    
    .property-basic-info {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 768px) {
    #property-detail-modal {
        padding: 16px;
    }
    
    .property-detail-modal-content {
        max-height: 85vh;
    }
    
    .property-info-section {
        padding: 16px;
        margin-bottom: 16px;
    }
    
    .property-basic-info {
        grid-template-columns: 1fr;
    }
    
    .property-action-button {
        font-size: 16px;
        padding: 16px 24px;
    }
    
    .image-thumbnail-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    #property-detail-modal {
        padding: 8px;
    }
    
    .property-info-section h4 {
        font-size: 16px;
    }
    
    .info-item {
        padding: 8px;
    }
    
    .info-item-value {
        font-size: 14px;
    }
    
    .price-value {
        font-size: 18px;
    }
    
    .image-thumbnail-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
}

/* アニメーション強化 */
.property-card,
.property-list-item,
.property-detail-card {
    transform: translateZ(0); /* GPU加速 */
}

/* ローディングスピナー（詳細データ取得時用） */
.detail-loading {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}

.detail-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid #e2e8f0;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1000;
}

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

/* 画像ズーム効果 */
.image-zoom-container {
    position: relative;
    overflow: hidden;
    cursor: zoom-in;
}

.image-zoom-container img {
    transition: transform 0.3s ease;
}

.image-zoom-container:hover img {
    transform: scale(1.1);
}

/* スクロールバーカスタマイズ */
.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}