/* ========================================
   各show.blade.php共通スタイル
   ======================================== */

/* 記事ヘッダー */
.article-header {
    background: #ffffff;
    margin-bottom: 0px;
}

/* 記事タイトル */
.article-title {
    font-size: 28px;
    font-weight: bold;
    line-height: 1.4;
    margin-bottom: 20px;
    color: #333;
}

/* メタ情報 */
.article-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    font-size: 14px;
    color: #666;
    flex-wrap: wrap;
}

/* アイキャッチ画像 */
.featured-image {
    margin-top: 20px;
}

.featured-image img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
}

/* 記事本文 */
.article-content {
    background: #ffffff;
    /*
    padding: 40px;
    border: 1px solid #e0e0e0;
    */
    margin-bottom: 30px;
    line-height: 1.8;
    color: #333;
}

.article-content h2 {
    font-size: 24px;
    font-weight: bold;
    margin: 30px 0 15px 0;
    color: #333;
}

.article-content h3 {
    font-size: 20px;
    font-weight: bold;
    margin: 25px 0 12px 0;
    color: #333;
}

/* FAQ形式のスタイル */
.article-content h2.wp-block-heading {
    font-size: 24px;
    font-weight: bold;
    margin: 40px 0 20px 0;
    color: #1E50A2;
    padding-bottom: 10px;
    border-bottom: 3px solid #1E50A2;
    /* alignleft（float）画像の回り込みを解除して見出しが右寄りに見えるのを防ぐ */
    clear: both;
}

.article-content h3.wp-block-heading {
    font-size: 16px;
    font-weight: bold;
    margin: 20px 0 10px 0;
    color: #333;
    line-height: 1.6;
}

.article-content h3.wp-block-heading strong {
    color: #1E50A2;
    font-weight: bold;
}

/* 質問と回答のスタイル */
.article-content h3.wp-block-heading + p {
    margin-top: 0;
    margin-bottom: 15px;
    padding-left: 20px;
    line-height: 1.8;
    color: #555;
    font-size: 16px;
}

/* スペーサー */
.wp-block-spacer {
    display: block;
}

/* 左寄せ画像 */
.article-content .wp-block-image.alignleft {
    float: left;
    margin: 0 20px 15px 0;
    max-width: 300px;
}

.article-content .wp-block-image.alignleft img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 強調テキスト */
.article-content .big1 {
    font-size: 18px;
    font-weight: bold;
    color: #1E50A2;
}

/* 画像スタイル */
.article-content .wp-block-image {
    margin: 20px 0;
    text-align: center;
}

.article-content .wp-block-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

.article-content .wp-block-image a {
    display: inline-block;
}

/* リストスタイル */
.article-content ul {
    margin: 15px 0;
    padding-left: 30px;
}

.article-content ul li {
    margin-bottom: 8px;
    line-height: 1.8;
    color: #333;
}

.article-content ul li a {
    color: #1E50A2;
    text-decoration: none;
}

.article-content ul li a:hover {
    text-decoration: underline;
}

/* 青色大見出し */
.article-content p.has-text-color[style*="color:#0018a3"],
.article-content p.has-text-color[style*="color:#0018a3"] {
    font-size: 16px;
    font-weight: bold;
    color: #333 !important;
    margin: 30px 0 20px 0;
}

/* 中央揃え画像 */
.article-content .wp-block-image.aligncenter {
    text-align: center;
    margin: 25px 0;
}

.article-content .wp-block-image.aligncenter img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 画像キャプション */
.article-content .wp-element-caption {
    font-size: 14px;
    color: #666;
    margin-top: 10px;
    font-style: italic;
    text-align: center;
}

/* 赤色テキスト */
.article-content .has-vivid-red-color {
    color: #dc3545 !important;
    font-weight: bold;
    margin: 15px 0;
    padding: 10px;
    background-color: #fff5f5;
    border-left: 4px solid #dc3545;
}

/* 中央揃えテキスト */
.article-content .has-text-align-center {
    text-align: center;
    margin: 20px 0;
    line-height: 1.8;
}

/* Google Maps iframe */
.article-content iframe {
    width: 100%;
    max-width: 600px;
    height: 600px;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin: 20px 0;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* セパレーター */
.article-content .wp-block-separator {
    margin: 30px 0;
    border: none;
    border-top: 1px solid #e0e0e0;
}

.article-content .wp-block-separator.has-css-opacity {
    opacity: 0.4;
}

.article-content p {
    margin-bottom: 15px;
}

.article-content img {
    max-width: 100%;
    height: auto;
    margin: 20px 0;
}

.article-content a {
    text-decoration: none;
}

.article-content a:hover {
    text-decoration: underline;
}

/* セクションタイトル */
.section-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

/* セクション */
.gallery-section,
.attachments-section,
.related-posts {
    background: #ffffff;
    padding: 30px;
    border: 1px solid #e0e0e0;
    margin-bottom: 30px;
}

/* ギャラリー */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.gallery-item img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

/* 関連資料 */
.attachments-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.attachment-item {
    display: flex;
    align-items: center;
    padding: 15px;
    background: #f8f8f8;
    border: 1px solid #e0e0e0;
    gap: 15px;
}

.attachment-icon,
.attachment-icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.attachment-icon-wrapper {
    width: 36px;
    height: 36px;
}

.attachment-thumb {
    width: 36px;
    height: 36px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.attachment-file-icon {
    width: 28px;
    height: 28px;
    font-size: 28px;
}

.attachment-icon-pdf {
    color: #E74C3C;
}

.attachment-icon-word {
    color: #2B579A;
}

.attachment-icon-excel {
    color: #217346;
}

.attachment-icon-image {
    background: linear-gradient(135deg, #FF9800, #4CAF50, #2196F3);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.attachment-icon-default {
    color: #7F8C8D;
}

.attachment-name {
    flex: 1;
    font-size: 14px;
    color: #333;
}

.download-link {
    color: #1E50A2;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
}

.download-link:hover {
    text-decoration: underline;
}

/* 関連記事 */
.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.related-item {
    border: 1px solid #e0e0e0;
    background: #ffffff;
}

.related-image img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.related-content {
    padding: 15px;
}

.related-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 8px;
    line-height: 1.4;
}

.related-title a {
    color: #333;
    text-decoration: none;
}

.related-title a:hover {
    color: #1E50A2;
}

.related-date {
    font-size: 12px;
    color: #666;
}

/* 戻るボタン */
.back-button {
    text-align: center;
    margin-bottom: 40px;
}
.back-button a {
    display: inline-block;
}
.back-button a:hover {
    background-color: #153d7a;
}

/* フローボックス */
.flow-box {
    position: relative;
    margin-bottom: 20px;
    padding: 20px;
    background: #ffffff;
    border: 2px solid #1E50A2;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.flow-box::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-top: 20px solid #1E50A2;
    z-index: 1;
}

.flow-box-last {
    position: relative;
    margin-bottom: 0;
    padding: 20px;
    background: #ffffff;
    border: 2px solid #1E50A2;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.flow-box .wp-block-group__inner-container,
.flow-box-last .wp-block-group__inner-container {
    margin: 0;
}

.flow-box p,
.flow-box-last p {
    margin: 0;
    line-height: 1.8;
}

.flow-box .big2,
.flow-box-last .big2 {
    font-size: 20px;
    font-weight: bold;
    display: block;
    margin-bottom: 10px;
}

.flow-box .big2.blue,
.flow-box-last .big2.blue {
    color: #1E50A2;
}

/* クリアフィックス */
.clearfix {
    display: flex;
    gap: 30px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.clearfix::after {
    content: '';
    display: table;
    clear: both;
}

/* 左ボックス */
.left-box {
    flex: 1;
    min-width: 300px;
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.left-box h3.wp-block-heading {
    font-size: 20px;
    font-weight: bold;
    color: #1E50A2;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1E50A2;
}

.left-box p {
    margin: 0;
    line-height: 2;
    color: #333;
}

/* 右ボックス */
.right-box {
    flex: 1;
    min-width: 300px;
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.right-box h3.wp-block-heading {
    font-size: 20px;
    font-weight: bold;
    color: #1E50A2;
    margin-top: 20px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1E50A2;
}

.right-box h3.wp-block-heading:first-child {
    margin-top: 0;
}

.right-box p {
    margin: 0 0 15px 0;
    line-height: 2;
    color: #333;
}

.right-box p:last-child {
    margin-bottom: 0;
}

/* キャッチボックス */
.catch {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
    padding: 20px;
    background: #ffffff;
    border-radius: 8px;
    align-items: flex-start;
}

.catch .wp-block-image {
    flex-shrink: 0;
    width: 150px;
    margin: 0;
}

.catch .wp-block-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

.catch-right {
    flex: 1;
    min-width: 0;
}

.catch-right h3.wp-block-heading {
    font-size: 24px;
    font-weight: bold;
    color: #1E50A2;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #1E50A2;
}

.catch-right ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.catch-right ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
    line-height: 1.8;
    color: #333;
}

.catch-right ul li::before {
    content: '●';
    position: absolute;
    left: 0;
    color: #1E50A2;
    font-size: 12px;
}

.catch-right p {
    margin: 0;
    line-height: 1.8;
    color: #333;
}

/* テーブルスタイル */
.article-content table.t1 {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    font-size: 14px;
}

.article-content table.t1 th,
.article-content table.t1 td {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
    vertical-align: middle;
}

.article-content table.t1 th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #333;
}

.article-content table.t1 tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

.article-content table.t1 tbody tr:hover {
    background-color: #f5f5f5;
}

/* 背景色クラス */
.article-content table.t1 .bgblue {
    background-color: #e3f2fd;
}

.article-content table.t1 .bgpink {
    background-color: #fce4ec;
}

.article-content table.t1 .bggreen {
    background-color: #e8f5e9;
}

/* テキスト中央揃え */
.article-content table.t1 .text-center {
    text-align: center;
}

/* サブテキストスタイル */
.article-content table.t1 .stit {
    padding-left: 20px;
    font-size: 13px;
    color: #666;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .article-header,
    .article-content,
    .gallery-section,
    .attachments-section,
    .related-posts {
        padding:0px;
    }
    
    .article-title {
        font-size: 24px;
    }
    
    .article-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .related-grid {
        grid-template-columns: 1fr;
    }
    
    .clearfix {
        flex-direction: column;
        gap: 20px;
    }
    
    .left-box,
    .right-box {
        min-width: 100%;
    }
    
    .catch {
        flex-direction: column;
        gap: 20px;
    }
    
    .catch .wp-block-image {
        width: 100%;
    }
    
    .article-content table.t1 {
        font-size: 12px;
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    .article-content table.t1 th,
    .article-content table.t1 td {
        padding: 6px 8px;
    }
    
    .article-content .wp-block-image.alignleft {
        float: none;
        margin: 15px 0;
        max-width: 100%;
    }
    
    .article-content .big1 {
        font-size: 16px;
    }
    
    .article-content p.has-text-color[style*="color:#0018a3"] {
        font-size: 20px;
    }
    
    .article-content iframe {
        height: 400px;
        max-width: 100%;
    }
}
