/* グローバルブックマークリスト - Comic Seymour風スタイル */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    font-size: 12px;
    line-height: 1.5;
    color: #333;
    background-color: #fff;
    min-width: 990px;
}

.container {
    width: 990px;
    margin: 0 auto;
    background: #fff;
}

/* ヘッダー */
.header {
    background: linear-gradient(to bottom, #4A90E2, #2E7CD6);
    border-bottom: 3px solid #1E5FA8;
    padding: 10px 20px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 24px;
    font-weight: bold;
}

.header h1 a {
    color: #fff;
    text-decoration: none;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.header-user {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 12px;
}

.header-user span {
    color: #fff;
    text-shadow: 0 1px 1px rgba(0,0,0,0.2);
}

/* ナビゲーションタブ */
.nav-tabs {
    background: #2E7CD6;
    display: flex;
    padding: 0 20px;
    border-bottom: 1px solid #1E5FA8;
}

.nav-tab {
    display: inline-block;
    padding: 8px 20px;
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
    border-left: 1px solid rgba(255,255,255,0.2);
    border-right: 1px solid rgba(255,255,255,0.2);
    background: transparent;
    position: relative;
    margin-right: -1px;
    transition: background 0.2s;
}

.nav-tab:hover {
    background: rgba(255,255,255,0.1);
}

.nav-tab.active {
    background: #fff;
    color: #2E7CD6;
    border-bottom: 2px solid #fff;
}

.nav-tab.genre-shounen {
    border-top: 3px solid #0185E5;
}

.nav-tab.genre-shoujo {
    border-top: 3px solid #FF6E78;
}

.nav-tab.genre-seinen {
    border-top: 3px solid #4CAF50;
}

.nav-tab.genre-josei {
    border-top: 3px solid #9C27B0;
}

/* ボタン */
.btn {
    display: inline-block;
    padding: 6px 15px;
    background: linear-gradient(to bottom, #4A90E2, #2E7CD6);
    color: white;
    text-decoration: none;
    border-radius: 3px;
    border: 1px solid #1E5FA8;
    cursor: pointer;
    font-size: 12px;
    font-weight: bold;
    transition: all 0.2s;
    text-shadow: 0 1px 0 rgba(0,0,0,0.2);
}

.btn:hover {
    background: linear-gradient(to bottom, #5DA3F5, #4A90E2);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.btn-primary {
    background: linear-gradient(to bottom, #4A90E2, #2E7CD6);
    border: 1px solid #1E5FA8;
}

.btn-primary:hover {
    background: linear-gradient(to bottom, #5DA3F5, #4A90E2);
}

.btn-secondary {
    background: linear-gradient(to bottom, #fff, #f0f0f0);
    border: 1px solid #ddd;
    color: #333;
    text-shadow: none;
}

.btn-secondary:hover {
    background: linear-gradient(to bottom, #f8f8f8, #e8e8e8);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.btn-danger {
    background: linear-gradient(to bottom, #ff6b6b, #e74c3c);
    border: 1px solid #c0392b;
}

.btn-danger:hover {
    background: linear-gradient(to bottom, #ff8787, #ff6b6b);
}

.btn-info {
    background: linear-gradient(to bottom, #5bc0de, #46b8da);
    border: 1px solid #2e9eb8;
}

.btn-info:hover {
    background: linear-gradient(to bottom, #6fd4f2, #5bc0de);
}

.btn-small {
    padding: 4px 10px;
    font-size: 11px;
}

.btn-large {
    padding: 10px 25px;
    font-size: 14px;
}

/* メインコンテンツ */
main {
    background: #fff;
    padding: 20px;
    min-height: 500px;
}

/* ダッシュボード */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #2E7CD6;
}

.dashboard-header h2 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

/* リストグリッド - コミックカード風 */
.lists-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.list-card {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    padding: 0;
    transition: all 0.2s;
    overflow: hidden;
    position: relative;
}

.list-card:hover {
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.list-card-thumbnail {
    width: 100%;
    height: 280px;
    background: linear-gradient(135deg, #E3F2FD, #90CAF9);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.list-card-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.list-card-thumbnail .no-image {
    font-size: 48px;
    color: #2E7CD6;
    opacity: 0.3;
}

.list-card-content {
    padding: 10px;
}

.list-card h3 {
    font-size: 13px;
    font-weight: bold;
    margin-bottom: 5px;
    line-height: 1.4;
    height: 36px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.list-card h3 a {
    color: #333;
    text-decoration: none;
}

.list-card h3 a:hover {
    color: #2E7CD6;
}

.list-card .description {
    font-size: 11px;
    color: #666;
    margin-bottom: 8px;
    height: 32px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.list-meta {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    margin-bottom: 8px;
    padding: 5px 0;
    border-top: 1px solid #f0f0f0;
}

.bookmark-count {
    color: #666;
}

.visibility {
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 10px;
    font-weight: bold;
}

.visibility.public {
    background: #d4f4dd;
    color: #27ae60;
}

.visibility.private {
    background: #ffe4e4;
    color: #e74c3c;
}

/* バッジ */
.badge {
    display: inline-block;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    border-radius: 2px;
    position: absolute;
    top: 5px;
    left: 5px;
}

.badge-new {
    background: #FF3366;
    color: white;
}

.badge-free {
    background: #00AA00;
    color: white;
}

.badge-sale {
    background: #2E7CD6;
    color: white;
}

/* リストアクション */
.list-actions {
    display: flex;
    gap: 5px;
    margin-top: 8px;
}

.list-actions .btn {
    flex: 1;
    text-align: center;
    padding: 4px 8px;
    font-size: 11px;
}

/* ブックマーク表示 */
.bookmarks-container {
    margin-top: 20px;
}

.bookmarks-container.grid-view {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
}

.bookmarks-container.list-view {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ブックマークアイテム - グリッドビュー */
.grid-view .bookmark-item {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    padding: 0;
    transition: all 0.2s;
    overflow: hidden;
    position: relative;
}

.grid-view .bookmark-item:hover {
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.grid-view .bookmark-item .thumbnail {
    width: 100%;
    height: 220px;
    background: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin: 0;
}

.grid-view .bookmark-item .thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.grid-view .bookmark-content {
    padding: 8px;
}

.grid-view .bookmark-content h3 {
    font-size: 12px;
    font-weight: bold;
    margin-bottom: 4px;
    height: 32px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.grid-view .bookmark-content h3 a {
    color: #333;
    text-decoration: none;
}

.grid-view .bookmark-content h3 a:hover {
    color: #2E7CD6;
}

.grid-view .bookmark-content .description {
    font-size: 10px;
    color: #666;
    margin-bottom: 6px;
    height: 26px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* ブックマークアイテム - リストビュー */
.list-view .bookmark-item {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    padding: 10px;
    display: flex;
    transition: all 0.2s;
}

.list-view .bookmark-item:hover {
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    background: #f8fbff;
}

.list-view .bookmark-item .thumbnail {
    width: 80px;
    height: 110px;
    margin-right: 15px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 3px;
}

.list-view .bookmark-item .thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.list-view .bookmark-content {
    flex: 1;
}

.list-view .bookmark-content h3 {
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 5px;
}

.list-view .bookmark-content h3 a {
    color: #333;
    text-decoration: none;
}

.list-view .bookmark-content h3 a:hover {
    color: #2E7CD6;
    text-decoration: underline;
}

.list-view .bookmark-content .description {
    font-size: 12px;
    color: #666;
    margin-bottom: 8px;
    line-height: 1.4;
}

.bookmark-actions {
    display: flex;
    gap: 5px;
    margin-top: 8px;
}

/* フォーム */
.form {
    max-width: 600px;
    background: #fff;
    padding: 20px;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
}

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

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

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 13px;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #2E7CD6;
    box-shadow: 0 0 0 2px rgba(46, 124, 214, 0.1);
}

.help-text {
    display: block;
    margin-top: 5px;
    font-size: 11px;
    color: #666;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #e5e5e5;
}

/* 認証フォーム */
.auth-form {
    max-width: 400px;
    margin: 50px auto;
    padding: 30px;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.auth-form h1 {
    text-align: center;
    margin-bottom: 25px;
    color: #2E7CD6;
    font-size: 20px;
}

/* ビュー切り替え */
.view-toggle {
    display: flex;
    gap: 0;
    border: 1px solid #ccc;
    border-radius: 3px;
    overflow: hidden;
}

.view-toggle .btn {
    border-radius: 0;
    border: none;
    border-right: 1px solid #ccc;
}

.view-toggle .btn:last-child {
    border-right: none;
}

.view-toggle .btn.active {
    background: #2E7CD6;
    color: white;
}

/* ページヘッダー */
.page-header {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #2E7CD6;
}

.page-header h2 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
}

.page-header p {
    font-size: 12px;
    color: #666;
}

/* リストヘッダー */
.list-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #2E7CD6;
}

.list-info h2 {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
}

.list-info .description {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}

/* 警告・成功メッセージ */
.alert {
    padding: 10px 15px;
    margin-bottom: 15px;
    border-radius: 3px;
    font-size: 12px;
    border: 1px solid;
}

.alert-danger {
    background-color: #fff5f5;
    color: #c00;
    border-color: #ffcccc;
}

.alert-success {
    background-color: #f0fff4;
    color: #2e7d32;
    border-color: #b7e4c7;
}

.warning {
    background-color: #fffbf0;
    color: #f57c00;
    border: 1px solid #ffe0b2;
    padding: 15px;
    border-radius: 3px;
    margin-bottom: 15px;
}

.warning h3 {
    margin-bottom: 8px;
    font-size: 14px;
}

/* 空の状態 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    background: #f8f8f8;
    border-radius: 4px;
}

.empty-state p {
    margin-bottom: 20px;
    font-size: 14px;
}

/* ヒーローセクション */
.hero {
    background: linear-gradient(135deg, #E3F2FD, #90CAF9);
    padding: 40px;
    border-radius: 4px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, transparent 70%);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hero h2 {
    font-size: 24px;
    color: #333;
    margin-bottom: 15px;
    font-weight: bold;
    position: relative;
}

.hero p {
    font-size: 14px;
    color: #666;
    margin-bottom: 25px;
    line-height: 1.6;
    position: relative;
}

.cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    position: relative;
}

/* 機能グリッド */
.features {
    margin-bottom: 40px;
}

.features h3 {
    text-align: center;
    font-size: 20px;
    color: #333;
    margin-bottom: 25px;
    font-weight: bold;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.feature-item {
    background: #fff;
    padding: 20px;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    transition: all 0.2s;
}

.feature-item:hover {
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    border-color: #2E7CD6;
}

.feature-item h4 {
    font-size: 14px;
    margin-bottom: 10px;
    color: #2E7CD6;
    font-weight: bold;
}

.feature-item p {
    font-size: 12px;
    color: #666;
    line-height: 1.5;
}

/* ファイルアップロード */
.file-upload-area {
    border: 2px dashed #ccc;
    border-radius: 4px;
    padding: 30px;
    text-align: center;
    margin-top: 10px;
    transition: all 0.2s;
    background: #fafafa;
}

.file-upload-area:hover {
    border-color: #2E7CD6;
    background: #f0f8ff;
}

.file-upload-area.dragover {
    border-color: #2E7CD6;
    background: #e6f4ff;
}

.current-thumbnail {
    margin: 10px 0;
}

.current-thumbnail img {
    border: 1px solid #ddd;
    border-radius: 3px;
    margin-bottom: 10px;
    max-width: 200px;
}

/* スワイパー風スライダー */
.swiper-container {
    position: relative;
    overflow: hidden;
    padding: 20px 0;
}

.swiper-wrapper {
    display: flex;
    transition: transform 0.3s ease;
}

.swiper-slide {
    flex-shrink: 0;
    width: 180px;
    margin-right: 15px;
}

.swiper-button-prev,
.swiper-button-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.9);
    border: 1px solid #ddd;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.2s;
}

.swiper-button-prev:hover,
.swiper-button-next:hover {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.swiper-button-prev {
    left: 10px;
}

.swiper-button-next {
    right: 10px;
}

/* レスポンシブ対応 */
@media (max-width: 1024px) {
    body {
        min-width: auto;
    }
    
    .container {
        width: 100%;
        max-width: 990px;
    }
}

@media (max-width: 768px) {
    .lists-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .bookmarks-container.grid-view {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-tabs {
        overflow-x: auto;
        white-space: nowrap;
    }
}

@media (max-width: 480px) {
    .lists-grid {
        grid-template-columns: 1fr;
    }
    
    .bookmarks-container.grid-view {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .header-top {
        flex-direction: column;
        gap: 10px;
    }
    
    .list-header {
        flex-direction: column;
        gap: 10px;
    }
}

/* フッター */
.footer {
    background: linear-gradient(to bottom, #f5f5f5, #e8e8e8);
    border-top: 3px solid #ddd;
    margin-top: 50px;
    padding: 30px 0;
}

.footer-container {
    width: 990px;
    margin: 0 auto;
    text-align: center;
}

.footer-nav {
    margin-bottom: 20px;
}

.footer-links {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 30px;
    padding: 0;
    margin: 0;
}

.footer-links li {
    display: inline-block;
}

.footer-links a {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    padding: 5px 10px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #2E7CD6;
    text-decoration: underline;
}

.footer-copyright {
    color: #999;
    font-size: 12px;
    margin-top: 15px;
}

.footer-copyright p {
    margin: 0;
}

@media (max-width: 768px) {
    .footer-container {
        width: 100%;
        padding: 0 20px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 10px;
    }
}