/* ==========================================================================
   Base & Common Styles (Premium Modern Dental Theme)
   ========================================================================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #0b1329; /* 💡 漆黒に近い、極めて深いラグジュアリーネイビー */
    color: #f1f5f9; /* 💡 目に優しくハッキリ映えるリッチオフホワイト */
    line-height: 1.6;
}

.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* ==========================================================================
   Header (Deep Navy & Gold Accent)
   ========================================================================== */
.main-header {
    /* 💡 修正：重ねるフィルターの濃さを 0.8 → 0.3 に変更し、背景画像を鮮明に明るくしました */
    background-image: linear-gradient(rgba(5, 11, 24, 0.3), rgba(5, 11, 24, 0.3)), url('https://www.04id.com/KLINVISA/images/back.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    
    color: #ffffff;
    padding: 40px 20px;
    border-bottom: 3px solid #d4af37; /* 💡 高級感を醸し出すシャンパンゴールドの細線 */
    position: relative;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-area h1 {
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #ffffff;
    /* 💡 念のため画像が明るくなっても文字が絶対にボヤけないよう、綺麗な影（シャドウ）を薄く入れています */
    text-shadow: 0 2px 8px rgba(5, 11, 24, 0.8);
}

#txtSubTitle {
    font-size: 15px;
    color: #cbd5e1; /* 💡 文字が沈まないように少し明るいグレーに変更 */
    margin-top: 4px;
    text-shadow: 0 1px 4px rgba(5, 11, 24, 0.8);
}

/* 言語切り替えセレクトボックス */
.lang-switcher select {
    background-color: #131c35;
    border: 1px solid #334155;
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}

.lang-switcher select:focus {
    border-color: #d4af37;
}

/* ==========================================================================
   Control Panel (Filter Area)
   ========================================================================== */
.control-panel {
    background-color: #131c35; 
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3); 
    border: 1px solid #1e293b;
}

#txtPanelTitle {
    font-size: 22px;
    color: #ffffff; 
    margin-bottom: 8px;
    font-weight: 600;
}

#txtPanelDesc {
    color: #94a3b8; 
    font-size: 14px;
    margin-bottom: 25px;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.filter-group label {
    display: block;
    font-weight: 600;
    color: #94a3b8; 
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    
    /* 💡 改行させず、スマホ幅に合わせて文字サイズを自動で最適化する設定 */
    white-space: nowrap;
    font-size: clamp(11px, 1.2vw, 13px); /* 画面幅に応じて11px〜13pxの間で自動伸縮 */
    overflow: hidden;
    text-overflow: ellipsis;
}

.filter-group select {
    width: 100%;
    padding: 10px 12px;
    background-color: #0b1329; 
    border: 1px solid #334155;
    color: #ffffff;
    border-radius: 6px;
    font-size: 14px;
    outline: none;
    transition: all 0.2s;
}

.filter-group select:focus {
    border-color: #d4af37;
    background-color: #131c35;
}

/* ==========================================================================
   Results Meta & Clinic Cards
   ========================================================================== */
.results-meta {
    margin: 25px 0 15px 0;
    font-size: 15px;
    color: #94a3b8;
}

#matchCount {
    color: #ffffff;
    font-size: 18px;
}

.clinic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 25px;
}

/* クリニックカード */
.clinic-card {
    background-color: #131c35; /* 💡 データ部背景：チャコールネイビー */
    border: 1px solid #1e293b;
    border-radius: 12px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s;
}

.clinic-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(0, 0, 0, 0.4);
    border-color: #334155;
}

.clinic-card h3 {
    font-size: 20px;
    color: #ffffff; /* 💡 クリニック名は美しい純白 */
    margin-bottom: 6px;
    font-weight: 600;
}

.clinic-location {
    font-size: 13px;
    color: #94a3b8; /* 💡 ロケーション用の落ち着いたライトグレー */
    margin-bottom: 15px;
}

.clinic-info-row {
    font-size: 13.5px;
    margin-bottom: 8px;
    color: #e2e8f0; /* 💡 詳細テキスト：完全にクッキリと読めるクリアホワイト */
}

.clinic-info-row strong {
    color: #94a3b8; /* 💡 項目ラベル（Opening Hours:等） */
}

/* 💰 価格表示エリア（最も視線を集める場所） */
.price-box {
    background-color: #0b1329; /* 💡 カード内でさらに引き締まるインボックス背景 */
    border-left: 4px solid #d4af37; /* 💡 シャンパンゴールドの縦線でプレミアム感を強調 */
    padding: 12px 15px;
    margin: 15px 0;
    border-radius: 0 8px 8px 0;
}

.price-box .lbl-total {
    font-size: 11px;
    font-weight: 700;
    color: #94a3b8;
    letter-spacing: 0.5px;
}

.price-box .price-range {
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
}

.price-note {
    font-size: 12px;
    color: #94a3b8;
    font-style: italic;
    margin-top: 4px;
}

/* ==========================================================================
   Buttons (Maps & Navigation)
   ========================================================================== */
.map-buttons-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 15px;
}

.btn-map {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    transition: opacity 0.2s;
}

.btn-map:hover {
    opacity: 0.9;
}

.google-maps-btn {
    background-color: #2563eb !important; /* 💡 ダークテーマに映える鮮明な公式ブルー */
    color: #ffffff !important;
}

.waze-btn {
    background-color: #06b6d4 !important; /* 💡 スカイブルー */
    color: #0f172a !important;
}

/* ==========================================================================
   Footer (Sophisticated Dark Slate)
   ========================================================================== */
.main-footer {
    background-color: #050b18; /* 💡 ヘッダーと同じ最深ネイビーで全体をクローズ */
    color: #94a3b8;
    padding: 40px 20px;
    font-size: 13px;
    line-height: 1.6;
    border-top: 1px solid #1e293b;
    margin-top: 60px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-disclaimer {
    text-align: left;
    color: #94a3b8;
    max-width: 900px;
    margin: 0 auto;
}

.footer-disclaimer strong {
    color: #cbd5e1;
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
}

.footer-divider {
    border: 0;
    border-top: 1px solid #1e293b;
    margin: 25px 0;
}

.footer-share-section {
    text-align: center;
}

.share-title {
    font-weight: bold;
    margin-bottom: 15px;
    color: #cbd5e1;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 20px;
    color: #ffffff !important;
    text-decoration: none !important;
    font-weight: bold;
    font-size: 14px;
}

/* Brand Colors for Sharing */
.share-btn.whatsapp { background-color: #25D366; }
.share-btn.wechat { background-color: #07C160; }
.share-btn.line-app { background-color: #06C755; }

.footer-bottom {
    text-align: center;
    color: #64748b;
    font-size: 11px;
    margin-top: 15px;
}

/* ==========================================================================
   Responsive adjustments (Mobile optimization)
   ========================================================================== */
@media screen and (max-width: 768px) {
    .main-header {
        /* スマホ時のみ余白を少し狭く調整 */
        padding: 20px 15px !important;
    }
    
    .header-container {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        gap: 15px !important;
    }

    .lang-switcher {
        position: static !important;
        order: -1 !important;
        margin: 0 auto 5px auto !important;
        display: block !important;
    }

    .logo-area h1 {
        font-size: 24px !important;
    }

    .share-buttons {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }
    
    .share-btn {
        width: 100%;
        max-width: 260px;
        justify-content: center;
    }
}