body {
    font-family: 'Noto Sans JP', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
}

/* ✅ ヘッダー Google風デザイン */
header {
    background-color: #f8f9fa;
    color: #333;
    padding: 20px;
    height: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

header h1 {
    font-weight: 700;
    margin: 0;
    padding-left: 20px;
}
/* ✅ 新着コンテンツのタイトルがヘッダーに隠れないようにする */
.search-result-group h2 {
    margin-top: 120px; /* ヘッダーの高さ+余白 */
}

/* ✅ ナビゲーションリンク */
nav ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
    padding-right: 20px;
}

nav a, nav button {
    text-decoration: none;
    color: #1a73e8;
    font-weight: 700;
    background-color: transparent;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    transition: all 0.3s;
}

nav a:hover, nav button:hover {
    background-color: #e8f0fe;
    border-radius: 4px;
}

/* ✅ 管理機能ドロップダウン */
.dropdown {
    position: relative;
}

.dropdown-menu {
    display: none;
    position: absolute;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    padding: 10px 0;
    width: 200px;
}

.dropdown-menu a {
    padding: 10px 15px;
    display: block;
    color: #333;
    font-size: 14px;
}

.dropdown-menu a:hover {
    background-color: #e8f0fe;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

/* ✅ マイページのフォントサイズ調整 */
nav a[href*="mypage"] {
    font-size: 18px;
}

/* ✅ コンテンツカード */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* カードの幅を決める */
    gap: 20px;
    padding: 20px;
    margin-top: 24px;
}

.card {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s;
}

.card img {
    width: 100%;
    border-bottom: 1px solid #e0e0e0;
  /*  aspect-ratio: 16/9;   横:縦の比率 */
    aspect-ratio: 4/3;  /* 横:縦の比率 */
    object-fit: cover;   /* 画像を切り取る */
}

/* ✅ カードの中身 */
.card-content {
    padding: 15px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

/* ✅ タイトル（1行制限） */
.card-content h3 {
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 5px;
    margin-top: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}



/* ✅ ステータス */
.card-content p:first-of-type {
	margin-bottom: 5px;
    margin-top: 5px;
    font-size: 14px;
    font-weight: bold;
    color: #666;
    margin-bottom: 5px;
}

/* ✅ 説明文（3行制限） */
.card-content p:last-of-type {
	margin-bottom: 5px;
    margin-top: 5px;
    font-size: 14px;
    color: #444;
    line-height: 1.4;
    height: 4.2em;  /* 3行分の高さ */
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* ✅ カードのホバーエフェクト */
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}
/* ✅ カードのリンクデザイン */
.card a {
    color: #1a73e8;
    text-decoration: none;
    display: block;
    height: 100%;
}

/* ✅ カードのホバーエフェクト */
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* ✅ フッター */
footer {
    background-color: #f8f9fa;
    color: #333;
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid #e0e0e0;
    margin-top: 20px;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-links a {
    color: #1a73e8;
    text-decoration: none;
    margin-right: 15px;
}

.footer-links a:hover {
    text-decoration: underline;
}

.footer-info p {
    margin: 5px 0;
}

/* ✅ レスポンシブ対応 */
@media (max-width: 1024px) {
    .cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .cards {
        grid-template-columns: repeat(1, 1fr);
    }
}
