@charset "utf-8";
/* 画像BBS スタイルシート */

/* リセット・基本設定 */
* {
    box-sizing: border-box;
}

html {
    font-family: 'Hiragino Kaku Gothic Pro', Meiryo, Osaka, 'MS PGothic', arial, sans-serif;
    font-size: 62.5%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-size: 1.6rem;
    line-height: 1.4;
    color: #202020;
    background: #f2f5f8;
}

a:hover {
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ヘッダー */
.header {
    background: #fff;
    border-bottom: 2px solid #b2dcf0;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1000px;
    padding: 15px 20px;
    margin: 0 auto;
    line-height: 1;
}

.logo img {
    width: 66px;
    height: 30px;
}

.nav-links {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.post-link a {
    padding: 10px 20px;
    font-weight: bold;
    color: #2ea1d7;
    text-decoration: none;
    border: 1px solid #2ea1d7;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.post-link a:hover {
    color: #1e729a;
    ;
    border: 1px solid #1e729a;
}

.home-link a {
    padding: 10px 15px;
    color: black;
    text-decoration: none;
    background: #f1f2f3;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.home-link a:hover {
    background: #e1e2e3;
}

/* メインコンテンツ */
.main-content {
    flex: 1;
    width: 100%;
    max-width: 1000px;
    padding: 20px;
    margin: 0 auto;
}

/* 検索フォーム */
.search-toggle-button {
    display: none;
}

.search-container {
    padding: 20px;
    margin-bottom: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.search-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.search-input {
    flex: 1;
    min-width: 200px;
    padding: 10px;
    font-size: 1.6rem;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.search-select {
    padding: 10px;
    font-size: 1.6rem;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
}

.search-button {
    padding: 8px 20px;
    font-size: 1.6rem;
    color: white;
    cursor: pointer;
    background: #00B4CC;
    border: none;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.search-button:hover {
    background: #0089a0;
}

.search-clear {
    padding: 8px 15px;
    color: #202020;
    text-align: center;
    text-decoration: none;
    border: 1px solid #878787;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.search-clear:hover {
    color: white;
    text-decoration: none;
    background: #878787;
}

.searcherror {
    width: 100%;
    padding: 10px 8px;
    font-size: 1.4rem;
    color: #721c24;
    background: #f8d7da;
    border-radius: 8px;
}

.search-result-info {
    padding: 10px 20px;
    margin-bottom: 20px;
    background: rgb(0 0 0 / 5%);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

/* スレッド一覧表示（新規追加） */
.thread-list-container {
    overflow: hidden;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.thread-list-header {
    display: grid;
    grid-template-columns: 1fr 220px 100px 100px;
    gap: 15px;
    padding: 15px 20px;
    font-weight: bold;
    background: #b2dcf0;
    border-bottom: 2px solid #81c6e6;
}

.header-images {
    text-align: center;
}

.thread-list {
    display: flex;
    flex-direction: column;
}

.thread-item {
    display: grid;
    grid-template-columns: 1fr 220px 100px 100px;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s ease;
}

.thread-item:hover {
    background-color: #f8f9fa;
}

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

.thread-title {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.thread-title a {
    font-weight: bold;
    line-height: 1.3;
    overflow-wrap: anywhere;
    text-decoration: none;
}

.thread-title a:hover {
    opacity: 0.8;
}

.thread-model-type {
    padding-top: 3px;
    font-size: 1.3rem;
    font-weight: normal;
    color: #666;
}

.thread-author {
    display: flex;
    align-items: center;
}

.thread-author a {
    color: #333;
    text-decoration: none;
}

.thread-author a:hover {
    text-decoration: underline;
}

.thread-date {
    display: flex;
    align-items: center;
    font-size: 1.4rem;
    color: #666;
}

.thread-images {
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-icon {
    font-weight: bold;
    color: #28a745;
}

.no-image {
    color: #ccc;
}

/* 投稿詳細表示 */
.post-detail-container {
    margin: 0 auto;
}

.breadcrumb {
    padding: 10px 0;
    margin-bottom: 15px;
    font-size: 1.4rem;
    color: #666;
}

.breadcrumb a {
    color: #2ea1d7;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.error-container {
    padding: 40px;
    text-align: center;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.back-link {
    display: inline-block;
    padding: 10px 20px;
    margin-top: 15px;
    color: white;
    text-decoration: none;
    background: #2ea1d7;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.back-link:hover {
    background: #1e729a;
}

/* 既存の投稿表示スタイル */
.posts-container {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.no-posts {
    padding: 40px;
    font-size: 1.8rem;
    color: #666;
    text-align: center;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

/* 投稿アイテム */
.post {
    padding: 10px;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.post-header {
    padding: 10px 12px;
    margin: 8px 8px 20px;
    background: #f2efe7;
    border-bottom: 1px solid #e7e7e7;
    border-radius: 8px;
}

.post-header h2 {
    overflow-wrap: anywhere;
}

.post-title {
    margin-bottom: 3px;
    font-size: 1.8rem;
}

.post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
}

.post-author-info {
    display: flex;
    gap: 15px;
    align-items: center;
}

.post-name a {
    font-size: 1.8rem;
    text-shadow: 0 1px 0 rgb(16 16 16 / 10%);
}

.post-name a:hover {
    opacity: 0.8;
}

.post-url a {
    padding: 2px 10px;
    color: #f9f9f9;
    text-decoration: none;
    background: #278bd3;
    border-radius: 6px;
}

.post-url a:hover {
    background: #1e6aa1;
}

.post-date {
    font-size: 1.4rem;
}

/* 投稿本文 */
.post-body {
    display: flex;
    gap: 25px;
    margin: 0 10px 20px;
}

.post-images {
    display: flex;
    flex-shrink: 0;
    flex-direction: column;
    gap: 10px;
    width: 300px;
}

.image-container {
    width: fit-content;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 20%);
}

.image-link {
    display: block;
}

.post-image {
    display: block;
    max-height: 380px;
    cursor: pointer;
    border-radius: 4px;
    transition: opacity 0.2s;
}

.post-image:hover {
    opacity: 0.9;
}

.post-content {
    flex: 1;
    overflow-wrap: anywhere;
}

.model-type {
    display: inline-block;
    width: 100%;
    padding: 7px 10px 5px;
    margin-bottom: 15px;
    font-weight: bold;
    color: #1d7299;
    background: rgb(46 161 215 / 15%);
    border-radius: 4px;
}

/* 投稿フッター */
.post-footer {
    display: flex;
    justify-content: flex-end;
    padding-top: 15px;
    margin: 0 10px;
    border-top: 1px solid #eee;
}

.delete-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.delete-password {
    width: 120px;
    padding: 5px 8px;
    font-size: 1.4rem;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.delete-button {
    padding: 4px 12px;
    font-size: 1.4rem;
    color: white;
    cursor: pointer;
    background: #dc3545;
    border: none;
    border-radius: 3px;
    transition: background 0.3s ease;
}

.delete-button:hover {
    background: #c82333;
}

/* 投稿フォーム */
.post-form-container {
    max-width: 700px;
    padding: 30px;
    margin: 0 auto;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.post-form-header {
    padding: 12px 0;
    margin-bottom: 10px;
    text-align: center;
    background: #f2efe7;
    border-radius: 8px;
}

.post-form-container h1 {
    font-size: 2rem;
    color: #333;
}

.form-notice {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 5px;
    margin-bottom: 30px;
    text-align: center;
    background: #f1f2f3;
    border-radius: 8px;
}

.form-notice p {
    margin: 2px 0;
    font-size: 1.4rem;
    color: #666;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.required {
    font-size: 1.5rem;
    color: #dc3545;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="url"],
.form-group input[type="password"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    font-size: 1.6rem;
    border: 2px solid #c1c1c1;
    border-radius: 10px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #2ea1d7;
    box-shadow: 0 0 0 2px rgb(46 161 215 / 10%);
}

.form-group textarea {
    min-height: 400px;
    resize: vertical;
}

.form-group small {
    display: block;
    margin-top: 5px;
    font-size: 1.4rem;
    color: #666;
}

.form-actions {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin-top: 35px;
    text-align: center;
}

.submit-button {
    padding: 12px 50px;
    font-size: 1.8rem;
    font-weight: bold;
    color: white;
    cursor: pointer;
    background: #2ea1d7;
    border: none;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.submit-button:hover {
    background: #1e729a;
}

.cancel-link {
    box-sizing: border-box;
    display: inline-block;
    padding: 12px 30px;
    font-weight: bold;
    color: black;
    text-decoration: none;
    border: 3px solid #ccc;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.cancel-link:hover {
    background: #ccc;
}

.form-attention {
    margin-top: 15px;
    font-size: 1.4rem;
    line-height: 1.6;
    color: #666;
    text-align: center;
}

/* 画像プレビューコンテナ */
.image-preview {
    padding: 12px;
    margin-top: 10px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgb(0 0 0 / 10%);
    transition: all 0.2s ease;
}

.image-preview:hover {
    border-color: #bbb;
    box-shadow: 0 2px 5px rgb(0 0 0 / 15%);
}

/* プレビュー画像 */
.image-preview img {
    display: block;
    max-width: 200px;
    max-height: 150px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgb(0 0 0 / 20%);
    transition: transform 0.2s ease;
}

.image-preview img:hover {
    transform: scale(1.02);
}

/* ファイル情報テキスト */
.image-preview p {
    margin: 8px 0;
    font-size: 1.3rem;
    font-weight: bold;
    color: #555;
}

/* 削除ボタン */
.image-preview button {
    padding: 6px 12px;
    font-size: 1.3rem;
    font-weight: bold;
    color: white;
    cursor: pointer;
    background: #dc3545;
    border: none;
    border-radius: 4px;
    box-shadow: 0 1px 2px rgb(0 0 0 / 20%);
    transition: all 0.3s ease;
}

.image-preview button:hover {
    background: #c82333;
    box-shadow: 0 2px 4px rgb(0 0 0 / 30%);
    transform: translateY(-1px);
}

.image-preview button:active {
    box-shadow: 0 1px 2px rgb(0 0 0 / 20%);
    transform: translateY(0);
}

/* エラーメッセージ（フォーム内） */
.form-group .error-message {
    padding: 8px 12px;
    margin-top: 8px;
    font-size: 1.3rem;
    color: #721c24;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

/* ファイル入力フィールドの見た目改善 */
.form-group input[type="file"] {
    width: 100%;
    padding: 10px;
    font-size: 1.6rem;
    cursor: pointer;
    background: #fff;
    border: 2px dashed #c1c1c1;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.form-group input[type="file"]:hover {
    background: #f8f9fa;
    border-color: #999;
}

.form-group input[type="file"]:focus {
    outline: none;
    background: #fff;
    border-color: #2ea1d7;
    box-shadow: 0 0 0 3px rgb(46 161 215 / 10%);
}

/* メッセージ */
.message {
    width: 100%;
    padding: 20px;
    margin-bottom: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.success-message {
    width: 100%;
    padding: 15px;
    margin: 0 auto 20px;
    color: #155724;
    text-align: center;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
}

.error-message,
.error-messages {
    padding: 15px;
    margin-bottom: 20px;
    color: #721c24;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

.error-messages {
    width: 100%;
    margin: 0 auto 20px;
}

.error-messages ul {
    padding-left: 20px;
    margin: 0;
}

.error-messages li {
    margin-bottom: 5px;
}

.back-link {
    margin-left: 10px;
    color: #007bff;
}

/* ページネーション・フッター */
.footer {
    padding: 20px;
    margin-top: 30px;
    background: white;
    border-top: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.pagination-container {
    margin-top: 50px;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    justify-content: center;
}

.page-link {
    padding: 12px 16px;
    line-height: 1;
    color: #1696d4;
    text-decoration: none;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    transition: all 0.2s;
}

a.page-link {
    background: white;
}

.page-link:hover {
    text-decoration: none;
    background: #e9ecef;
}

.page-link.current {
    color: white;
    background: #19a7ec;
    border-color: #1696d4;
}

.page-link.prev,
.page-link.next {
    font-weight: bold;
}

.page-numbers {
    display: flex;
    gap: 10px;
    align-items: center;
}

.page-ellipsis {
    padding: 8px 4px;
    color: #6c757d;
}

/* フッターコンテンツ */
.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    justify-content: space-between;
    max-width: 1000px;
    padding-top: 15px;
    margin: 0 auto;
    border-top: 1px solid #e9ecef;
}

.footer-links .admin-link {
    padding: 6px 10px;
    font-size: 1.4rem;
    color: #6c757d;
    text-decoration: none;
    border-radius: 3px;
    transition: all 0.2s;
}

.footer-links .admin-link:hover {
    color: #495057;
    text-decoration: none;
    background: #f8f9fa;
}

.copyright {
    padding: 6px 10px;
    font-size: 1.4rem;
    color: #6c757d;
}

.copyright p {
    margin: 0;
}

/* 管理画面用スタイル */
.admin-login-container {
    max-width: 400px;
    padding: 40px;
    margin: 50px auto;
    text-align: center;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.admin-login-container h1 {
    margin-bottom: 30px;
    color: #333;
}

.login-form .form-group {
    text-align: left;
}

.login-button {
    width: 100%;
    padding: 12px;
    margin-top: 10px;
    font-size: 1.6rem;
    color: white;
    cursor: pointer;
    background: #007bff;
    border: none;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.login-button:hover {
    background: #0056b3;
}

.admin-container {
    padding: 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
}

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 15px;
    margin-bottom: 30px;
    border-bottom: 2px solid #007bff;
}

.admin-header h1 {
    color: #333;
}

.logout-link {
    padding: 8px 16px;
    color: white;
    text-decoration: none;
    background: #dc3545;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.logout-link:hover {
    text-decoration: none;
    background: #c82333;
}

/* 統計情報 */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-item {
    padding: 20px;
    text-align: center;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
}

.stat-label {
    display: block;
    margin-bottom: 5px;
    font-size: 1.5rem;
    color: #666;
}

.stat-value {
    display: block;
    font-size: 3.2rem;
    font-weight: bold;
    color: #007bff;
}

/* 管理画面投稿テーブル */
.admin-posts h2 {
    margin-bottom: 20px;
    color: #333;
}

.posts-table-container {
    overflow-x: auto;
}

.posts-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.posts-table th,
.posts-table td {
    padding: 12px;
    vertical-align: top;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

.posts-table th {
    font-weight: bold;
    color: #495057;
    background: #f8f9fa;
}

.posts-table tr:hover {
    background: #f8f9fa;
}

.title-cell {
    max-width: 250px;
}

.title {
    margin-bottom: 5px;
    font-weight: bold;
}

.content-preview {
    font-size: 1.4rem;
    color: #666;
}

.ip-cell {
    font-family: monospace;
    font-size: 1.4rem;
}

.date-cell {
    font-size: 1.4rem;
    white-space: nowrap;
}

.image-cell {
    text-align: center;
}

.image-count {
    padding: 2px 6px;
    font-size: 1.3rem;
    color: white;
    background: #28a745;
    border-radius: 3px;
}

.no-image {
    font-size: 1.4rem;
    color: #878787;
}

.action-cell {
    text-align: center;
}

.admin-delete-button {
    padding: 5px 10px;
    font-size: 1.3rem;
    color: white;
    cursor: pointer;
    background: #dc3545;
    border: none;
    border-radius: 3px;
    transition: background 0.3s ease;
}

.admin-delete-button:hover {
    background: #c82333;
}

/* アルバムモード */
.album-count {
    display: none;
}

.album-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.album-item {
    overflow: hidden;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
    transition: transform 0.2s ease;
}

.album-item:hover {
    transform: translateY(-2px);
}

.album-image {
    width: 100%;
    height: 200px;
    cursor: pointer;
    object-fit: cover;
    transition: opacity 0.2s ease;
}

.album-image:hover {
    opacity: 0.9;
}

.album-info {
    padding: 10px;
    text-align: center;
}

.album-author {
    font-size: 1.4rem;
    color: #666;
}

/* ユーティリティクラス */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mb-10 {
    margin-bottom: 10px;
}

.mb-20 {
    margin-bottom: 20px;
}

.mt-10 {
    margin-top: 10px;
}

.mt-20 {
    margin-top: 20px;
}

/* スクロールバーのスタイリング（webkit系ブラウザ） */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* レスポンシブデザイン */
@media screen and (max-width:768px) {
    .header-container {
        padding: 15px;
    }

    .main-content {
        padding: 15px;
    }

    .nav-links {
        justify-content: center;
    }

    .search-toggle-button {
        display: block;
        width: 100%;
        padding: 15px 0;
        margin: 5px 0 20px;
        font-size: 1.6rem;
        font-weight: bold;
        line-height: 1;
        color: white;
        cursor: pointer;
        background: #00B4CC;
        border: none;
        border-radius: 6px;
    }

    .search-container {
        display: none;
        /* デフォルトで非表示 */
    }

    .search-container.show {
        display: block;
    }

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

    .search-input,
    .search-select,
    .search-button,
    .search-clear {
        width: 100%;
    }

    /* スレッド一覧のレスポンシブ */
    .thread-list-header,
    .thread-item {
        grid-template-columns: 1fr 120px 60px 60px;
        gap: 8px;
    }

    .thread-list-header {
        display: none;
        /* モバイルではヘッダーを非表示 */
    }

    .thread-item {
        padding: 10px;
        border-bottom: 2px solid #e9ecef;
    }

    .thread-title a {
        padding: 5px;
    }

    .thread-date {
        font-size: 1.3rem;
    }

    /* 投稿詳細のレスポンシブ */
    .post-body {
        flex-direction: column;
        gap: 10px;
        margin: 0 5px 20px;
    }

    .post-header {
        padding: 10px;
        margin: 0 2px 10px;
    }

    .post-images {
        flex-wrap: wrap;
        align-items: center;
        width: 100%;
    }

    .post-image {
        width: 100vw;
        max-height: 200px;
        object-fit: cover;
        object-position: 25% 13%;
    }

    .post-meta {
        flex-direction: column;
        gap: 0;
        align-items: flex-start;
    }

    .post-date {
        align-self: flex-end;
    }

    .form-actions {
        flex-direction: column;
    }

    .submit-button,
    .cancel-link {
        width: 100%;
        text-align: center;
    }

    .pagination {
        gap: 5px;
        margin-bottom: 15px;
    }

    .footer-content {
        flex-direction: column;
        gap: 10px;
        align-items: normal;
    }

    .footer-links {
        text-align: right;
    }

    .copyright {
        text-align: center;
    }
}

@media screen and (max-width:680px) {

    .thread-list-header,
    .thread-item {
        grid-template-columns: 1fr 65px;
        align-items: center;
    }

    .thread-author,
    .thread-images {
        display: none;
    }
}

@media screen and (max-width:480px) {
    .post-form-container {
        padding: 20px;
    }

    .post-meta {
        gap: 2px;
    }

    .post-author-info {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }

    .pagination {
        gap: 3px;
    }

    .page-link.prev,
    .page-link.next {
        display: none;
    }

    .image-preview {
        padding: 10px;
    }

    .image-preview img {
        max-width: 100%;
        max-height: 120px;
    }

    .image-preview button {
        width: 100%;
        padding: 8px;
        font-size: 1.4rem;
    }
}

@media screen and (max-width:320px) {
    .header-container {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .nav-links {
        width: 100%;
    }
}

/* ======ハンバーガー====== */

.nav-container {
    display: flex;
    align-items: center;
    gap: 20px;
    display: flex;
}

#nav-check {
    display: none;
}

.nav-open {
    position: relative;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 40px;
    cursor: pointer;
    background: #fff;
    border-radius: 4px;
}

.nav-open span,
.nav-open span::before,
.nav-open span::after {
    position: absolute;
    display: block;
    width: 38px;
    height: 4px;
    content: '';
    background: #000;
    border-radius: 4px;
    transition: 0.6s;
}

.nav-open span::before {
    bottom: 12px;
}

.nav-open span::after {
    top: 12px;
}

#nav-check:checked~.nav-open span {
    background: rgb(255 255 255 / 0%);
}

#nav-check:checked~.nav-open span::before {
    bottom: 0;
    transform: rotate(45deg);
}

#nav-check:checked~.nav-open span::after {
    top: 0;
    transform: rotate(-45deg);
}

#nav-check:checked~nav {
    right: 0;
}

/* ====SPメニュー==== */

nav {
    position: fixed;
    top: 0;
    right: -100%;
    z-index: 99;
    box-sizing: border-box;
    width: 80%;
    max-width: 850px;
    height: 100vh;
    padding: 60px 0;
    overflow: auto;
    font-size: 1.6rem;
    background: rgb(255 255 255 / 95%);
    transition: .5s;
}

nav h3 {
    font-family: 'M PLUS Rounded 1c';
    font-size: 2.4rem;
    text-align: center;
}

nav dl {
    width: 82%;
    margin: 15px auto 0;
}

nav dt {
    padding: 8px;
    margin-bottom: 10px;
    font-family: 'M PLUS Rounded 1c';
    font-size: 1.8rem;
    background: #f1f2f3;
    border-radius: 4px;
}

nav dd {
    padding: 0 0 16px 20px
}

nav dd a {
    text-decoration: none;
}