/* ===============================
   リセット（崩れ防止）
================================ */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #f5f8fb;
  font-family: "Segoe UI", sans-serif;
}

/* ===============================
   全体レイアウト
================================ */
.container {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  width: 100%;
  max-width: none;
  margin: 32px 0;
  padding: 0 24px;
}

/* ===============================
   左：検索条件
================================ */
.sidebar {
  width: 300px;
  flex: 0 0 300px;
}

.search-box {
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.title {
  margin: 0 0 20px;
  font-size: 20px;
  font-weight: bold;
  color: #1f2937;
}

.search-box label {
  display: block;
  margin-top: 16px;
  margin-bottom: 6px;
  font-weight: bold;
  color: #1f2937;
}

/* 入力 */
.search-box input[type="text"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d9dee7;
  border-radius: 10px;
  font-size: 14px;
}

.search-box input[type="text"]:focus {
  outline: none;
  border-color: #36b58b;
  box-shadow: 0 0 0 3px rgba(54, 181, 139, 0.15);
}

/* 属性 */
.checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.checkbox-group label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 1px solid #d9dee7;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
}

.checkbox-group input {
  margin: 0;
}

/* 検索ボタン */
.search-btn {
  width: 100%;
  margin-top: 24px;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #36b58b, #42c86b);
  color: #fff;
  font-size: 15px;
  font-weight: bold;
  cursor: pointer;
}

.search-btn:hover {
  opacity: 0.9;
}

/* ===============================
   中央：検索結果
================================ */
.main-content {
  flex: 1;
  min-width: 0;
}

.result-box {
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

/* ヘッダー */
.result-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 18px;
  font-weight: bold;
  color: #1f2937;
}

/* 件数 */
.result-count {
  padding: 3px 10px;
  border-radius: 999px;
  background: #e4f7ef;
  color: #15936b;
  font-size: 13px;
}

/* カード */
.book-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  margin-bottom: 12px;
  border: 1px solid #e5e9f0;
  border-radius: 12px;
  background: #fff;
  text-decoration: none;
  color: inherit;
  transition: 0.2s;
}

.book-card:hover {
  background: #f8fcfb;
  border-color: #bce7d5;
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

/* 左アイコン（任意） */
.book-icon {
  width: 40px;
  height: 40px;
  background: #e6f4ea;
  border-radius: 50%;
}

/* 中央 */
.book-info {
  flex: 1;
}

.book-name {
  font-weight: bold;
  margin-bottom: 5px;
  color: #111827;
}

.book-desc {
  font-size: 14px;
  color: #4b5563;
}

/* 右矢印 */
.book-arrow {
  font-size: 24px;
  color: #9ca3af;
}

/* ===============================
   右：広告
================================ */
.right-sidebar {
  flex: 0 0 220px;
}

.ad-box {
  height: 260px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
}

/* ===============================
   スマホ対応
================================ */
@media screen and (max-width: 900px) {
  .main-content{
    width: 100%;
  }
  .container {
    flex-direction: column;
    padding: 0 16px;
    width: 100%;
  }
  .sidebar,
  .right-sidebar {
    width: 100%;
    flex: none;
  }
  .ad-box {
    height: 150px;
  }
}