/* OPAC固有のスタイル */

.opac-main {
    background-color: #f4f6f9;
    /* 少し事務的な背景色 */
    min-height: 80vh;
    padding-top: 80px;
    /* Navbarの分 */
}

.opac-container {
    padding-top: 40px;
    padding-bottom: 60px;
    max-width: 1000px;
}

.system-header {
    margin-bottom: 30px;
    border-bottom: 2px solid var(--main-blue);
    padding-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.system-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 1.8rem;
    color: var(--main-blue);
    margin: 0;
}

.system-title span {
    font-family: 'Noto Sans JP', sans-serif;
    font-size: 1rem;
    color: #888;
    margin-left: 15px;
    font-weight: normal;
}

.system-notice {
    font-size: 0.8rem;
    color: var(--accent-red);
    margin: 0;
}

/* 検索パネル */
.search-panel {
    background: #fff;
    padding: 30px;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
    border-top: 4px solid var(--main-blue);
}

.search-form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.form-select,
.form-input {
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
}

.form-input {
    flex-grow: 1;
}

.btn-search {
    background-color: var(--main-blue);
    color: #fff;
    border: none;
    padding: 0 40px;
    font-weight: bold;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-search:hover {
    background-color: #002040;
}

.search-options {
    font-size: 0.9rem;
    color: #666;
}

.search-options label {
    margin-right: 20px;
    cursor: pointer;
}

/* 結果エリア */
.result-header {
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
}

.results-list {
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    min-height: 200px;
}

.placeholder-msg {
    padding: 60px;
    text-align: center;
    color: #999;
}

.sub-msg {
    font-size: 0.85rem;
    margin-top: 10px;
}

/* 個別の本アイテム */
.book-item {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    gap: 20px;
    transition: background 0.2s;
    cursor: pointer;
    /* クリックできることを示す */
}

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

.book-item:hover {
    background-color: #f9fbfd;
}

.book-info h3 {
    color: var(--main-blue);
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.book-meta {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 5px;
}

.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
    margin-top: 8px;
}

.status-ok {
    background-color: #d4edda;
    color: #155724;
}

.status-ng {
    background-color: #f8d7da;
    color: #721c24;
}

/* モーダルウィンドウ */
.modal-overlay {
    display: none;
    /* 初期状態は非表示 */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #fff;
    padding: 30px;
    border-radius: 5px;
    width: 90%;
    max-width: 600px;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

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

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 1.5rem;
    cursor: pointer;
    color: #aaa;
}

.close-modal:hover {
    color: #333;
}

.modal-header {
    border-bottom: 2px solid var(--main-blue);
    margin-bottom: 20px;
    padding-bottom: 10px;
}

.modal-header h3 {
    margin: 0;
    color: var(--main-blue);
    font-family: 'Noto Serif JP', serif;
}

.modal-info-row {
    display: flex;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.modal-info-row .label {
    width: 100px;
    font-weight: bold;
    color: #666;
    flex-shrink: 0;
}

.modal-info-row .value {
    color: #333;
}

@media (max-width: 768px) {
    .system-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .search-form-row {
        flex-direction: column;
    }

    .form-select,
    .form-input,
    .btn-search {
        width: 100%;
    }

    .book-item {
        flex-direction: column;
        gap: 10px;
    }

    .modal-content {
        width: 95%;
        padding: 20px;
    }

    .modal-info-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}