/*
Theme Name: 越乃ポート
Description: 福井県の仕事マッチング掲示板用テーマ
Version: 1.0
Author: 越乃バレーコンシェルジュ
*/

@charset "UTF-8";

/* 基本スタイル */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Hiragino Kaku Gothic ProN', 'メイリオ', 'Meiryo', sans-serif;
    background: #F5F0E8;
    min-height: 100vh;
    color: #333;
    font-size: 16px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 15px;
}

.header {
    background: #3E6B5B;
    color: white;
    padding: 25px 20px;
    border-radius: 15px;
    margin-bottom: 25px;
    box-shadow: 0 8px 25px rgba(62, 107, 91, 0.3);
}

.header h1 {
    font-size: clamp(24px, 4vw, 48px);
    margin-bottom: 8px;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.2;
}

.header p {
    font-size: clamp(16px, 2.5vw, 24px);
    text-align: center;
    opacity: 0.9;
    margin: 0;
}

/* フォームとコントロール */
.controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.search-filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.search-input {
    padding: 12px 15px;
    font-size: clamp(14px, 1.2vw, 16px);
    border: 2px solid #ddd;
    border-radius: 8px;
    min-width: 200px;
    max-width: 300px;
    width: 100%;
    background: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    transition: border-color 0.3s ease;
}

.search-input:focus {
    border-color: #3E6B5B;
    outline: none;
}

.filter-select {
    padding: 12px 15px;
    font-size: clamp(14px, 1.2vw, 16px);
    border: 2px solid #ddd;
    border-radius: 8px;
    background: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    min-width: 150px;
}

.btn {
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-primary {
    background: #3E6B5B;
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* タブナビゲーション */
.tab-navigation {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 25px;
    background: white;
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.tab-btn {
    padding: 10px 20px;
    border: none;
    background: transparent;
    color: #666;
    font-size: clamp(14px, 1.1vw, 16px);
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    min-width: 100px;
    flex: 1;
    max-width: 150px;
}

.tab-btn:hover {
    background: #f8f9fa;
    color: #333;
}

.tab-btn.active {
    background: #3E6B5B;
    color: white;
    box-shadow: 0 4px 15px rgba(62, 107, 91, 0.3);
}

/* 投稿ボード */
.board {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.post {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    cursor: pointer;
    border-left: 6px solid;
    min-height: 220px;
    display: flex;
    flex-direction: column;
}

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

.post.job-request {
    border-left-color: #3E6B5B;
    background: linear-gradient(135deg, #fff 0%, #f8fbf9 100%);
}

.post.job-offer {
    border-left-color: #D4A574;
    background: linear-gradient(135deg, #fff 0%, #fdfbf7 100%);
}

.post.job-history {
    border-left-color: #28a745;
    background: linear-gradient(135deg, #fff 0%, #f8fff8 100%);
}

.post-type {
    font-size: 14px;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    color: white;
}

.post-type.request {
    background: #3E6B5B;
}

.post-type.offer {
    background: #D4A574;
}

.post-type.history {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.post-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
    line-height: 1.3;
}

.post-content {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 15px;
}

.post-meta {
    font-size: 14px;
    color: #999;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.post-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* 詳細表示モーダル */
.detail-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1100;
}

.detail-modal-content {
    background: white;
    margin: 30px auto;
    padding: 50px;
    border-radius: 20px;
    max-width: 1000px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 3px solid #eee;
}

.detail-type {
    font-size: 16px;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: bold;
    color: white;
}

.detail-type.request {
    background: #3E6B5B;
}

.detail-type.offer {
    background: #D4A574;
}

.detail-type.history {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.detail-title {
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
    line-height: 1.2;
}

.detail-content {
    font-size: 18px;
    line-height: 1.8;
    color: #555;
    margin-bottom: 30px;
    white-space: pre-wrap;
}

.detail-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.detail-info-item {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    border-left: 4px solid #3E6B5B;
}

.detail-info-item h4 {
    font-size: 16px;
    color: #3E6B5B;
    margin-bottom: 10px;
    font-weight: bold;
}

.detail-info-item p {
    font-size: 18px;
    color: #333;
    margin: 0;
}

.detail-contact {
    background: #3E6B5B;
    color: white;
    padding: 30px;
    border-radius: 15px;
    margin-top: 30px;
}

.detail-contact h3 {
    font-size: 24px;
    margin-bottom: 15px;
}

.detail-contact p {
    font-size: 18px;
    margin-bottom: 10px;
}

.close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 30px;
    cursor: pointer;
    color: #999;
}

.close:hover {
    color: #333;
}

/* フッター連絡先 */
.footer-contact {
    background-image: url('<?php echo get_template_directory_uri(); ?>/img/20251012_1614_穏やかな港の抽象画_simple_compose_01k7bm8z6fegdbsaaqya63m19g.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 60px 40px;
    border-radius: 15px;
    text-align: center;
    margin-top: 60px;
    position: relative;
    overflow: hidden;
}

.footer-contact p {
    margin: 10px 0;
    color: #495057;
}

.footer-contact strong {
    color: #333;
    font-size: 20px;
}

.footer-contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(245, 240, 232, 0.9);
    z-index: 1;
}

.footer-contact > * {
    position: relative;
    z-index: 2;
}

.footer-contact a {
    color: #3E6B5B;
    text-decoration: none;
    font-weight: 500;
}

.footer-contact a:hover {
    color: #D4A574;
    text-decoration: underline;
}

.phone-number {
    font-size: 14px !important;
    color: #6c757d !important;
    margin-top: 15px !important;
}

/* 相談ボタン */
.contact-btn {
    background: #3E6B5B;
    color: white;
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(62, 107, 91, 0.3);
    margin-top: 15px;
}

.contact-btn:hover {
    background: #D4A574;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 165, 116, 0.4);
}

/* ローディングとエラー表示 */
.loading {
    text-align: center;
    padding: 60px 20px;
    font-size: 18px;
    color: #666;
    background: white;
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.loading:before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #3E6B5B;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
    margin-right: 10px;
    vertical-align: middle;
}

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

.error-message {
    text-align: center;
    padding: 40px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    border-left: 6px solid #dc3545;
}

.error-message h3 {
    color: #dc3545;
    margin-bottom: 15px;
    font-size: 20px;
}

.error-message p {
    color: #666;
    margin-bottom: 20px;
    font-size: 16px;
}

.no-posts {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    background: white;
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.no-posts h3 {
    margin-bottom: 15px;
    color: #495057;
}

.no-posts p {
    font-size: 16px;
    margin-bottom: 0;
}

/* レスポンシブデザイン */
@media (max-width: 1200px) {
    .container {
        padding: 12px;
    }
    
    .board {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 18px;
    }
    
    .detail-info {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .header {
        padding: 20px 15px;
        margin-bottom: 20px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .board {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .post {
        padding: 18px;
        min-height: 200px;
    }
    
    .detail-info {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .controls {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .search-filters {
        justify-content: center;
        gap: 10px;
    }

    .search-input,
    .filter-select {
        min-width: unset;
        width: 100%;
    }

    .tab-navigation {
        padding: 10px;
        gap: 6px;
    }

    .tab-btn {
        padding: 10px 16px;
        font-size: 14px;
        min-width: unset;
    }
    
    .search-filters {
        flex-direction: column;
        align-items: center;
    }
    
    .search-input {
        width: 100%;
        max-width: 300px;
    }
    
    .footer-contact {
        padding: 20px;
    }
}
