.video-row,
.category-all,
.category-beauty,
.category-busty,
.category-amateur,
.category-married,
.category-young,
.category-schoolgirl,
.category-office,
.category-massage,
.category-cosplay,
.category-body-beautiful-breasts,
.category-anal,
.category-creampie {
    display: contents !important;
}

:root {
    --primary-color: rgb(66, 130, 198);
    --secondary-color: rgb(103, 100, 186);
    --accent-color: rgb(135, 162, 206,0.6);
    --background-color: #f8f9ff;
    --card-background: #ffffff25;
    --text-color: #2c3e50;
    --text-light: #6b7280;
    --favorite-color: #e53935;
    --success-color: #4caf50;
    --border-radius: 12px;
    --shadow: 0 8px 32px rgba(102, 126, 234, 0.15);
    --shadow-frame: 0 5px 12px -6px rgba(0, 0, 0, 0.35);
    --shadow-button: 0 5px 12px -6px rgba(0, 0, 0, 0.45);
    --shadow-hover: 0 20px 60px rgba(102, 126, 234, 0.25);
    --gradient: linear-gradient(98deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    --gs-start: rgba(255, 255, 255, 0.94);
    --gs-end: rgba(95, 120, 146, 0.9);
    --gradient-background: linear-gradient(135deg, var(--gs-start) 0%, var(--gs-end) 100%);
    --transition: all 0.2s ease-out;
    --sinchaku: rgba(41, 216, 255, 0.6);
    --bg-primary: #eaedf7;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --text-primary: #414141;
    --text-secondary: #6b6b6b;
    --border-color: #c5d3e1;
    --sub-title-color: rgba(205, 205, 205, 0.85);
    --sidetitle:rgba(167, 203, 223, 0.3);
    --sidebar-active: linear-gradient(135deg, var(--accent-color) 0%, var(--sidetitle) 100%);
    --grd-erofun:repeating-linear-gradient(90deg, rgb(255, 255, 255), rgba(148, 180, 202, 0.08) 45%, rgba(165, 169, 171, 0.12) 52%, rgb(255, 255, 255));
    --grd-erofun-button:repeating-linear-gradient(90deg, rgb(255, 255, 255), rgba(218, 233, 242, 0.43) 45%, rgba(199, 222, 251, 0.3) 52%, rgb(255, 255, 255));
    --grd-erofun--btn:repeating-linear-gradient(90deg, rgb(255, 255, 255), rgba(218, 233, 242, 0.14) 45%, rgba(195, 219, 250, 0.12) 52%, rgb(255, 255, 255));
    --bg--btn:linear-gradient(135deg, rgba(100, 183, 246, 0.5), rgba(117, 23, 205, 0.2));
    --bg-tertiary:repeating-linear-gradient(90deg, rgb(255, 255, 255), rgba(218, 233, 242, 0.16) 45%, rgba(218, 238, 250, 0.2) 52%, rgb(255, 255, 255));
    --topdown: linear-gradient(#f9fcff, transparent 77%);
}

.dark-mode {
    --bg-primary: #1a1a1a;
    --bg-secondary: #2d2d2d;
    --gs-start: rgba(113, 113, 113, 0.6);
    --gs-end: rgba(65, 85, 97, 0.6);
    --accent-color: rgb(71, 86, 109);
    --bg-card: #333333;
    --text-primary: #e0e0e0;
    --text-secondary: #8e8e8e;
    --border-color: #262629;
    --background-color: rgb(30, 30, 37);
    --card-background: #16213e;
    --text-color: #e0e6ed;
    --text-light: #bbb;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    --shadow-frame: 0 5px 12px -6px rgba(0, 0, 0, 0.45);
    --shadow-button: 0 5px 12px -6px rgba(0, 0, 0, 0.55);
    --sub-title-color: rgba(46, 46, 46, 0.85);
    --sidetitle:rgba(88, 80, 69, 0.3);
    --sidebar-active: linear-gradient(135deg, var(--accent-color) 0%, var(--sidetitle) 100%);
    --grd-erofun:repeating-linear-gradient(90deg, rgba(31, 31, 31, 0.01), rgba(245, 251, 255, 0.22) 48%, rgba(199, 236, 255, 0.12) 58%, rgba(31, 31, 31, 0.01));
    --grd-erofun-button:repeating-linear-gradient(90deg, rgba(31, 31, 31, 0.0), rgba(245, 251, 255, 0.01) 40%, rgba(245, 251, 255, 0.1) 48%, rgba(199, 236, 255, 0.05) 53%, rgba(31, 31, 31, 0.01));
    --grd-erofun--btn:repeating-linear-gradient(90deg, rgba(31, 31, 31, 0.01), rgba(245, 251, 255, 0.03) 40%, rgba(245, 251, 255, 0.06) 48%, rgba(199, 236, 255, 0.05) 53%, rgba(31, 31, 31, 0.01));
    --bg--btn:linear-gradient(135deg, rgba(41, 149, 231, 0.4), rgba(105, 39, 168, 0.7));
    --bg-tertiary:repeating-linear-gradient(90deg, rgba(31, 31, 31, 0.01), rgba(245, 251, 255, 0.03) 40%, rgba(245, 251, 255, 0.1) 48%, rgba(199, 236, 255, 0.05) 53%, rgba(31, 31, 31, 0.01));
    --topdown: linear-gradient(var(--bg-card), transparent 77%);
}
body {
    width:100% !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    padding-top: 80px !important;
    overflow-x: hidden !important;
    overscroll-behavior-y: contain;
}

a {
    text-decoration: none !important;
}

/* ========================================
   🖥️ PC版ヘッダー（スクロール連動対応）
========================================= */

.header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    z-index: 8000 !important;
    overflow: visible !important;
    contain: none !important;
    will-change: transform;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
    -webkit-font-smoothing: antialiased;
    -webkit-backface-visibility: hidden;
    background: var(--gradient);
    backdrop-filter: blur(20px) !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1) !important;
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.header.hidden {
    transform: translate3d(0, -100%, 0);
}

.header.visible {
    transform: translate3d(0, 0, 0);
}

.header.scroll-hidden,
.header.header-hidden {
    transform: translate3d(0, -100%, 0) !important;
    pointer-events: none !important;
}

.header.header-visible {
    transform: translate3d(0, 0, 0) !important;
    pointer-events: auto !important;
}

.header-container {
    position: relative !important;
    overflow: visible !important;
    contain: none !important;
    transform: none !important;
    isolation: auto !important;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem !important;
    height: 60px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.header-container > * {
    min-width: 0 !important;
}

.logo {
    margin-top:8px !important;
    display: inline-block;
}

.header-center {
    flex: 1;
    display: flex;
    justify-content: center;
    margin: 0 2rem;
}

.search-form {
    width: 100%;
    max-width: 600px;
}

.search-container {
    display: flex;
    align-items: center;
    position: relative;
}

.search-icon {
    position: absolute;
    left: 1.04rem;
    top: 50%;
    transform: translateY(-50%) !important;
    color: rgba(172, 173, 177, 0.4);
    font-size: 1rem;
    z-index: 9;
}

.search-box {
    flex: 1;
    background: rgba(24, 2, 80, 0.04);
    border-radius: 30px;
    backdrop-filter: blur(10px);
    border: 1px inset rgba(6, 25, 87, 0.14);
    margin-top:0 !important;
    box-shadow: -1px -1.2px 29px -6px rgba(0,0,0,0.16) inset;
    color: rgba(253, 253, 254, 0.8) !important;
    font-size: 1rem !important;
    outline: none;
    padding: 0.58rem 1.5rem 0.58rem 2.88rem !important;
}

.search-box::placeholder {
  color: rgba(255,255,255, 0.5);
    font-size: 0.8rem !important;
  text-shadow: 2px 2px 6px rgba(200,200,200, 0.1), 0 0 rgba(130, 130, 130, 0.1);
    -webkit-text-stroke: 1.2px rgba(255,255,255,0.3);
    text-stroke: 1.2px rgba(255,255,255,0.3);
    paint-order: stroke;
}

.dark-mode .search-container {
    display: flex;
    align-items: center;
    position: relative;
}

.dark-mode .search-box {
    flex: 1;
    background: rgba(24, 2, 80, 0.04);
    border-radius: 30px;
    backdrop-filter: blur(10px);
    margin-top:0 !important;
    box-shadow: -3px -142px 29px -6px rgba(0,0,0,0.24) inset;
    border:2px rgba(222,222,222,0.6) !important;
    color: rgba(253, 253, 254, 0.1);
    font-size: 0.9rem;
    outline: none;
    padding: 0.58rem 1.5rem 0.58rem 2.6rem !important;
}
.dark-mode .search-box::placeholder {
  color: rgba(255,255,255, 0.45);
  text-shadow: 2px 2px 6px rgba(0,0,0,0.1), 0 0 rgba(30,30,30,0.1);
    -webkit-text-stroke: 1.2px rgba(20,20,20,0.3);
    text-stroke: 1.2px rgba(20,20,20,0.3);
    paint-order: stroke;
}
.header-right {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-menu {
    display: flex;
    gap: 0.5rem;
    list-style: none;
}

.nav-item a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1vw;
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item a:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.nav-item a:active,
.nav-item a.active {
    background: rgba(255, 255, 255, 0.25);
}

.mode-toggle {
    width: 48px;
    height: 48px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 12px;
    cursor: pointer;
    font-size: 1.6rem;
}

.mobile-search-toggle,
.mobile-menu-toggle {
    display: none;
}

/* ========================================
   🖥️ メインコンテナ
========================================= */

.main-container {
    max-width: 1920px;
    margin: 0 auto;
    padding: 20px 4px !important;
    display: grid;
    grid-template-columns: 4fr 320px !important;
    gap: 0.6rem;
    contain: layout style paint;
}

.main-content {
    min-width: 0;
    padding:0.1rem 0.6rem !important;
}

/* ========================================
   🎨 コンテンツヘッダー
========================================= */

.content-header {
    margin-bottom: 2rem !important;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    background-image:var(--grd-erofun) !important;
    box-shadow: -10px 0px 24px -6px rgba(0,0,0,0.18);
    
    box-shadow: var(--shadow);
    padding: 0.5rem 3rem !important;
}

.page-title {
    margin-top: 0 !important;
    text-align: center !important;
    width: 72%;
    margin: 0 auto !important;
    background: var(--bg-primary);
    box-shadow: 0px 0px 18px -6px rgba(0,0,0,0.1) inset !important;
    border-radius: 50px;
    border:2px ridge var(--sidetitle);
    padding: 0.8rem 2.4rem !important;
    margin-bottom: 2rem !important;
    color: var(--text-primary);
    font-size:1.48rem !important;
}

/* ========================================
   🔍 検索オプション
========================================= */

.search-options-section {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 2rem auto;
    max-width: 1280px;
    box-shadow: var(--shadow);
}

.search-options-container {
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr !important;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

.search-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.search-option label {
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
}

.search-option select {
    padding: 0.6rem 1.2rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-option select:hover {
    border-color: var(--primary-color);
}

.search-option select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 134, 198, 0.1);
}

/* ========================================
   🎨 コンテンツフィルター
========================================= */

.content-filters {
    display:grid !important;
    grid-template-columns:1fr 1fr 1fr 1fr 1fr 1fr 1fr 1fr !important;
    gap: 0.75rem;
    margin: 1.5rem auto;
}

.filter-button {
    padding: 0.75rem 1.25rem;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    white-space: nowrap;
}
.filter-button span{
    color: var(--text-secondary);
}
.filter-button::first-letter {
    font-size: 1.4rem;
    -webkit-text-stroke: 2px black;
    text-stroke: 2px black;
    paint-order: stroke;
}
@media (min-width: 769px) and (max-width: 1379px) { 
    .content-filters {
    display:grid !important;
    grid-template-columns:1fr 1fr 1fr 1fr 1fr !important;
    gap: 0.75rem !important;
    margin: 1.5rem auto !important;
}
.filter-button {
    padding: 0.45rem 0.95rem !important;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    white-space: nowrap;
}
.filter-button span{
    color: var(--text-secondary);
}
}
.filter-button:hover {
    background: linear-gradient(135deg, rgba(84, 177, 243, 0.2), rgba(103, 84, 233, 0.3));
    color: var(--text-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(66, 134, 198, 0.3);
}

.filter-button.active {
    background: linear-gradient(135deg, rgba(84, 177, 243, 0.2), rgba(103, 84, 233, 0.3));
    border: 3.2px solid var(--border-color);
}

.filter-button-special {
    background: linear-gradient(135deg, rgba(190, 255, 99, 0.4) rgba(255, 252, 89, 0.8)) !important;
    color: var(--text-secondary);
    border: 3px solid var(--border-color);
    margin-left:8px !important;
}

.filter-button-special:hover {
    transform: translateY(-2px) scale(1.05);
    background: linear-gradient(135deg, #b3ff6b, #f4ff53);
}

/* ========================================
   🏷️ タグセクション
========================================= */

.tags-section {
    background: var(--bg-card);
    border-radius: var(--border-radius);
    padding: 2rem !important;
    margin: 2rem auto !important;
    max-width: 1680px;
    box-shadow: var(--shadow);
}

.tags-container-wrapper h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding-right: 2rem !important;
}

.tag {
    background: var(--gradient);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(66, 134, 198, 0.4);
}

/* ========================================
   📂 カテゴリセクション
========================================= */

.category-section {
    background-image: var(--grd-erofun) !important;
    box-shadow: -10px 0px 24px -6px rgba(0,0,0,0.18);
    border-radius: 16px;
    margin: 2rem auto;
    padding: 1.5rem;
    max-width: 1680px;
    overflow: visible;
}

.category-container {
    width: 100%;
    max-width: 100%;
}

.category-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.category-icon {
    font-size: 1.6rem;
}

.category-tabs {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 2rem;
    overflow-x: auto;
    padding: 0.5rem 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.category-tabs::-webkit-scrollbar {
    display: none;
}

.category-tab {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.category-tab:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(66, 134, 198, 0.3);
}


.category-tab-icon {
    font-size: 1.2rem;
}

.category-tab-name {
    font-size: 0.95rem;
}

.category-videos-container {
    border-top: 2px solid var(--border-color);
    padding-top: 2rem;
    margin-top: 1rem;
}
.category-videos-container .ranking-badge{
    position: absolute;
    top: 6px !important;
    left: 6px !important;
    color: white;
    padding: 4px 6px !important;
    border-radius: 12px;
    font-weight: bold;
    font-size: 16px;
    -webkit-text-stroke: 2px rgba(50,50,50,0.4);
    text-stroke: 2px rgba(50,50,50,0.4);
    paint-order: stroke;
    text-shadow: 0.2px 0.2px 4px rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 15px rgba(255, 87, 87, 0.16) !important;
    border: 1.6px solid rgba(255, 255, 255, 0.8) !important;
    animation: pulse-gold 2s ease-in-out infinite !important;
}
        .video-duration{
            position: absolute;
            bottom: 6px !important;
            right: 6px;
            background: rgba(0, 0, 0, 0.55);
            color: white;
            padding: 4px 8px;
            border-radius: 4px;
            font-size: 0.86rem;
            -webkit-text-stroke: 2px rgba(50,50,50,0.9);
            text-stroke: 2px rgba(50,50,50,0.9);
            paint-order: stroke;
            font-weight: 600;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.36) !important;
            z-index:99;
        }
        .ai-related-grid .video-duration{
            position: absolute;
            bottom: 3px !important;
            right: 3px;
            background: rgba(0, 0, 0, 0.45);
            color: white;
            padding: 3px 6px;
            border-radius: 4px;
            font-size: 0.75rem;
            -webkit-text-stroke: 2px rgba(50,50,50,0.9);
            text-stroke: 2px rgba(50,50,50,0.9);
            paint-order: stroke;
            font-weight: 600;
            box-shadow: 0 4px 15px rgba(255, 87, 87, 0.26) !important;
            z-index:99;
        }
        .ai-related-grid a {
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.16) !important;
        }
        .ai-related-grid img {
            height:180px;
        }
        .ai-related-grid h3 {
           font-size: 1.2rem;
            font-weight: 600;
            line-height: 1.6;
            margin-top: -5px;
            margin-bottom: 0.5rem;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
            padding: 0 4px !important;
        }
        .ai-video-stats{
            display: grid;
            grid-template-columns: 1fr 1fr 1fr !important;
            gap: 0.6rem;
            color: var(--text-secondary);
            text-align:right;
        }
        .ai-video-stats span{
            font-size: 1rem;
        }
.category-videos-container button.favorite-btn-small{
    display:none !important;
}
.category-videos-container .ranking-badge .rank-1{
    background: linear-gradient(135deg, rgba(255, 254, 236, 0.75), rgba(216, 202, 0, 0.7)) !important;
}
.category-videos-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.category-videos-header h4 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.category-videos-count {
    padding: 0.5rem 1rem;
    background: rgba(66, 134, 198, 0.1);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-color);
}

/* ========================================
   🖥️ PC版グリッド（5カラム）
========================================= */

/* メイン動画グリッド（検索結果など） */
.videos-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 1rem !important;
    width: 100% !important;
    padding: 0 0.6rem !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

/* カテゴリ動画グリッドコンテナ */
.category-videos-grid {
    display: block;
    width: 100%;
    padding: 0;
    margin: 0;
}

.category-videos-grid .video-row {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 1.5rem !important;
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

.category-videos-grid .video-card {
    width: 100%;
    height: 100%;
    background: var(--bg-card);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInUp 0.4s ease-out backwards;
}

.category-videos-grid .video-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.category-videos-grid .video-card:nth-child(1) { animation-delay: 0.05s; }
.category-videos-grid .video-card:nth-child(2) { animation-delay: 0.1s; }
.category-videos-grid .video-card:nth-child(3) { animation-delay: 0.15s; }
.category-videos-grid .video-card:nth-child(4) { animation-delay: 0.2s; }
.category-videos-grid .video-card:nth-child(5) { animation-delay: 0.25s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.category-videos-grid .video-thumbnail {
    position: relative;
    width: 100%;
    max-height: 260px !important;
    padding-top: 56.25%;
    overflow: hidden;
    background: linear-gradient(45deg, #f0f0f0, #e0e0e0);
}

.category-videos-grid .video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    content-visibility: auto;
    contain-intrinsic-size: 320px 180px;
}

.category-videos-grid .video-card:hover .video-thumbnail img {
    transform: scale(1.05);
}

.category-videos-grid img.lazy {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.category-videos-grid img.lazy.loaded {
    opacity: 1;
}

.category-videos-grid .video-info {
    padding: 1rem;
    position: relative;
}

.category-videos-grid .video-title {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    padding:8px 12px !important;
}

.category-videos-grid .video-title a{
    text-decoration: none !important;
}
.category-videos-grid .video-meta {
    display: flex;
    justify-content: space-between;
    text-align:center !important;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.category-videos-grid .video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.4);
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    -webkit-text-stroke: 2px rgba(50,50,50,0.9);
    text-stroke: 2px rgba(50,50,50,0.9);
    paint-order: stroke;
    box-shadow: 0 4px 15px rgba(255, 87, 87, 0.26) !important;
}

.category-badge {
    position: absolute;
    top: 4px;
    left: 4px;
    background: linear-gradient(135deg, #4286c6, #6764ba);
    color: white;
    padding: 0.28rem 0.45rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.category-videos-grid .loading-placeholder,
.category-videos-grid .error-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid var(--border-color);
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
}

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

.loading-text {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 600;
}

/* ========================================
   🎨 動画カード
========================================= */

.video-card {
    background: var(--bg-card);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.video-card:hover {
    transform: translateY(-3px) scale(1.05) !important;
    box-shadow: 0 8px 25px rgba(26, 85, 140, 0.6) !important;
    border: 4px solid rgba(26, 85, 140, 0.4) !important;
    z-index: 999;
}

.video-card:after,
.video-card:before {
    background: var(--bg-card);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.video-info {
    position: relative;
    padding: 1.2rem 0.25rem 0.8rem !important;
}

.video-stats{
    position:relative;
    bottom:0 !important;
    height:24px !important;
    line-height:24px !important;
    display: grid;
    grid-template-columns: 1.4fr 1.4fr 1fr !important;
    padding:0 12px 0 !important;
    width:100% !important;
    color: var(--text-primary);
    margin:0 auto !important;
    text-align:center !important;
    align-items: center !important;
    justify-content: center !important;
}

.stat-item {
    margin:0 auto !important;
}

.video-title {
    font-size: 1rem !important;
    line-height: 1.4 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    margin-bottom: 1rem !important;
    font-weight: 600;
    color: var(--text-primary);
    padding:12px !important;
}

.video-stats span{
    white-space:nowrap !important;
}

/* ========================================
   📊 サイドバー
========================================= */

.sidebar-videos-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
}


.sidebar-section {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1rem 0.5rem 3rem !important;
    box-shadow: var(--shadow);
    margin-bottom: 1.2rem !important;
    text-align:center !important;
}

.sidebar-section h3 {
    text-align: center !important;
    width: 90%;
    margin: 0 auto 12px !important;
    background: var(--bg-primary);
    box-shadow: 0px 0px 22px -6px rgba(52, 51, 51, 0.1) inset !important;
    border-radius: 50px;
    padding: 1rem !important;
    border:2px ridge var(--sidetitle);
    color: var(--text-primary);
}

.horizontal-scroll-section {
    margin-bottom: 2rem;
}

.horizontal-scroll-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.horizontal-scroll-container {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.5rem;
}

.horizontal-scroll-container::-webkit-scrollbar {
    display: none;
}

.horizontal-scroll-container .video-card {
    min-width: 200px;
    max-width: 200px;
    scroll-snap-align: start;
    flex-shrink: 0;
}

/* ========================================
   📄 ページネーション
========================================= */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    margin: 3rem auto;
    padding: 2rem;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1rem !important;
    font-size: 1.275rem !important;
    min-width: 60px !important;
    background-image: var(--grd-erofun--btn) !important;
    border: 2px outset var(--border-color) !important;
    border-radius: 12px;
    color: var(--text-primary);
    text-decoration: none;
    box-shadow: var(--shadow);
    font-weight: 600;
    transition: all 0.3s ease;
    -webkit-text-stroke: 2px var(--border-color);
    text-stroke: 2px var(--border-color);
    paint-order: stroke;
}

.pagination a:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.pagination .current {
    background: var(--bg--btn) !important;
    color: white;
    border: 2px inset var(--border-color);
    box-shadow: var(--shadow-hover);
}

/* ========================================
   🎲 ランダムセクション
========================================= */

.random-section {
    background: linear-gradient(135deg, 
        rgba(66, 134, 198, 0.1) 0%, 
        rgba(103, 100, 186, 0.1) 100%);
    border-radius: 16px;
    padding: 3rem;
    margin: 3rem auto;
    max-width: 1680px;
    text-align: center;
}

.random-section {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.random-section .section-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.random-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.random-btn {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #4286c6, #6764ba);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(66, 134, 198, 0.3);
}

.random-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 25px rgba(66, 134, 198, 0.4);
}

.random_p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

/* ========================================
   🦶 フッター
========================================= */

.footer {
    background: var(--bg-card);
    border-top: 2px solid var(--border-color);
    padding: 4rem 0 2rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1680px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3rem;
}

.footer-section h3,
.footer-section h4 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.footer-section p {
    font-size: 96% !important;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    margin-top: 3rem;
    padding-top: 2rem;
}

.footer-bottom .footer-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-copyright p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-meta {
    display: flex;
    gap: 2rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* ========================================
   🌍 言語切り替え
========================================= */

.language-switcher {
    position: relative;
    z-index: 9999;
}

.language-toggle,
.language-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: 25px;
    color: white;
    cursor: pointer;
    font-weight: 500;
    background: rgba(255, 255, 255, 0) !important;
    border: 2px solid rgba(255, 255, 255, 0) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.language-button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.language-button .flag {
    font-size: 1.6rem !important;
}

.language-button i {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.language-button.active i {
    transform: rotate(180deg);
}

.language-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.15);
    overflow: hidden;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100000;
}

.language-menu.active,
.language-menu.show {
    position: absolute !important;
    border-radius: 12px !important;
    padding: 0.5rem !important;
    min-width: 180px !important;
    max-width: 250px !important;
    box-shadow: rgba(0, 0, 0, 0.6) 0px 8px 32px, rgba(255, 255, 255, 0.1) 0px 0px 0px 1px !important;
    backdrop-filter: blur(20px) !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0px) scale(1) !important;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    max-height: 80vh !important;
    overflow-y: auto !important;
    pointer-events: auto !important;
    contain: none !important;
    isolation: auto !important;
    z-index: 2147483647 !important;
}

.language-item,
.language-option {
    display: flex;
    align-items: center;
    gap: 0.75rem !important;
    padding: 0.75rem 1rem !important;
    width:180px !important;
    height:52px !important;
    line-height:52px !important;
    color: var(--text-color);
    text-decoration: none;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #f0f0f071;
}

.language-option:last-child {
    border-bottom: none;
}

.language-item:hover,
.language-option:hover {
    background: #f8f9ff;
}

.language-option .flag {
    font-size: 1.1rem;
}

.language-option .name {
    flex: 1;
}

.language-option .check {
    color: var(--primary-color);
    font-weight: bold;
}

.x_icon {
    width: 24px;
    height: 24px;
}

/* ========================================
   🌙 ダークモード
========================================= */

.dark-mode .header {
    background: linear-gradient(135deg, 
        rgba(30, 30, 43, 0.95) 0%, 
        rgba(44, 62, 80, 0.95) 100%) !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5) !important;
}


.dark-mode .category-videos-grid .video-card {
    background: var(--bg-tertiary);
}

.dark-mode .category-videos-grid .video-thumbnail {
    background: linear-gradient(45deg, #2a2a2a, #1a1a1a);
}

.dark-mode .category-tab {
    background: var(--bg-tertiary);
    border-color: var(--border-color-dark);
}

.dark-mode .category-tab:hover {
    background: var(--primary-color);
    color: white;
}

.dark-mode .category-videos-count {
    background: rgba(66, 134, 198, 0.2);
}

.dark-mode .footer {
    background: var(--bg-secondary);
}

.dark-mode .random-section {
    background: var(--bg-secondary);
}

.dark-mode .search-options-section,
.dark-mode .tags-section {
    background: var(--bg-secondary);
}

.dark-mode .language-menu {
    background: rgba(20, 20, 20, 0.95);
}

.dark-mode .video-title {
    color: var(--text-primary);
}


    .sidebar-section p {
        position:relative;
        top: 0.7rem;
        font-size: 0.85rem;
        color: #666;
        margin:0 auto !important;
        margin-bottom: 1.2rem !important;
    }


/* HOTラベル（緑枠） */
.hot-label {
    position: absolute !important;
    top: 6px !important;
    right: 6px !important;
    background: linear-gradient(135deg, rgba(81, 241, 41, 0.4), rgba(41, 224, 241, 0.4)) !important;
    color: white !important;
    padding: 4px 8px !important;
    border-radius: 20px !important;
    font-size: 0.8rem !important;
    font-weight: 800 !important;
    box-shadow: 0 4px 15px rgba(76, 209, 55, 0.4) !important;
    border: 1.2px solid rgba(255, 255, 255, 0.9) !important;
    z-index: 100 !important;
    animation: pulse-green 2s ease-in-out infinite;
}

.category-tab.active {
    background: var(--bg--btn) !important;
    color: white;
    border: 2px outset var(--border-color);
    box-shadow: var(--shadow-hover);
}
.native-tab-bar {
    display:none;
}

    #pc{
        display:block !important;
    }
    #sp{
        display:none !important;
    }
    #mobileSearchOverlay div div{
        color:var(--text-primary) !important;
    }

        /* Loading状態 */
        .video-card.loading {
            pointer-events: none;
            opacity: 0.6;
        }

        /* リンクスタイル */
        .video-link {
            text-decoration: none;
            color: inherit;
            display: block;
        }
        input[type="text"]:focus {
        background-color: transparent !important; /* 薄いグレーに変わる */
        border-color: rgba(255,255,255,0.8) !important;
        }

        input.dark-mode [type="text"]:focus {
        background-color: transparent !important; /* 薄いグレーに変わる */
        border-color: rgba(255,255,255,0.8) !important;
        }
        .sparea{
            display:none !important;
        }
        body.scrolling .header.header-visible {
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
            transition: 
                transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease !important;
        }

        body.scrolling .native-tab-bar.tab-bar-visible {
            box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15) !important;
            transition: 
                transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease !important;
        }

        .header:focus-within,
        .native-tab-bar:focus-within {
            transform: translate3d(0, 0, 0) !important;
            pointer-events: auto !important;
        }

        body.user-is-tabbing .header,
        body.user-is-tabbing .native-tab-bar {
            transition: transform 0.5s ease !important;
        }

        .header.preload,
        .native-tab-bar.preload {
            transition: none !important;
        }
        .video-card,
        .tag {
            will-change: transform;
        }

/* 急上昇動画セクション */
.sidebar-trending {
    background-image: var(--grd-erofun) !important;
    box-shadow: -10px 0px 24px -6px rgba(0,0,0,0.18);
    padding: 0.8rem;
    border-left:3px solid rgb(225, 181, 222);
    border-radius: 12px;
    margin-bottom: 2.4rem !important;
}

/* 新着動画セクション */
.sidebar-latest {
    background-image: var(--grd-erofun) !important;
    border-left:3px solid rgb(204, 239, 184);
    box-shadow: -10px 0px 18px -6px rgba(0,0,0,0.18);
    padding: 0.8rem;
    border-radius: 12px;
}

/* ランキングバッジ（赤枠） */
.rank-badge {
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    background: linear-gradient(135deg, #ff5757, #ff3838) !important;
    color: white !important;
    padding: 4px 8px !important;
    border-radius: 20px !important;
    font-size: 0.85rem !important;
    font-weight: 800 !important;
    box-shadow: 0 4px 15px rgba(255, 87, 87, 0.4) !important;
    border: 2px solid rgba(255, 255, 255, 0.9) !important;
    z-index: 100 !important;
}

.rank-badge {
    text-shadow: 0.2px 0.2px 4px rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 15px rgba(255, 87, 87, 0.16) !important;
    border: 1.6px solid rgba(255, 255, 255, 0.8) !important;
}

.rank-badge.rank-1 {
    background: linear-gradient(135deg, rgba(255, 254, 236, 0.75), rgba(216, 202, 0, 0.7)) !important;
    font-size: 0.95rem !important;
    padding: 0px 8px 0px !important;
    animation: pulse-gold 2s ease-in-out infinite;
}

.rank-badge.rank-2 {
    background: linear-gradient(135deg, rgba(250, 253, 255, 0.76), rgba(121, 121, 121, 0.98)) !important;
    font-size: 0.95rem !important;
    padding: 0px 8px 0px 5px !important;
}

.rank-badge.rank-3 {
    background: linear-gradient(135deg, rgba(249, 231, 205, 0.78), rgba(184, 96, 29, 0.86)) !important;
    font-size: 0.95rem !important;
    padding: 0px 8px 0px 5px !important;
}

.category-all .rank-badge::first-letter{
    position:absolute !important;
    font-size: 1.15rem !important;
}
.rank-badge.rank-4,
.rank-badge.rank-5 {
    background: linear-gradient(135deg, rgba(255, 110, 110, 0.44), rgba(255, 65, 65, 0.7)) !important;
}

.rank-badge.rank-1::first-letter{
    position:absolute !important;
    font-size:1.4rem !important;
}
.rank-badge.rank-2::first-letter{
    position:absolute !important;
    font-size:1.5rem !important;
}
.rank-badge.rank-3::first-letter{
    position:absolute !important;
    font-size:1.4rem !important;
}
@keyframes pulse-gold {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
    }
}

@keyframes pulse-green {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(76, 209, 55, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 6px 20px rgba(76, 209, 55, 0.6);
    }
}

/* 急上昇インジケーター */
.trending-indicator {
    color: #ff5757 !important;
    font-weight: 700 !important;
}

.trending-indicator i {
    animation: bounce-up 1s ease-in-out infinite;
}

@keyframes bounce-up {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-3px);
    }
}

/* サイドバーカードのボーダー */
.trending-card {
    border: 2px solid rgba(255, 87, 87, 0.3) !important;
    transition: all 0.3s ease;
}

.latest-card {
    border: 2px solid rgba(76, 209, 55, 0.3) !important;
    transition: all 0.3s ease;
}

.trending-card:hover {
    border-color: #ff5757 !important;
    box-shadow: 0 8px 25px rgba(255, 87, 87, 0.3) !important;
    transform: translateY(-4px) !important;
}

.latest-card:hover {
    border-color: #4cd137 !important;
    box-shadow: 0 8px 25px rgba(76, 209, 55, 0.3) !important;
    transform: translateY(-4px) !important;
}



/* ========================================
   🌙 ダークモード対応
========================================= */

.dark-mode .sidebar-trending {
    background: linear-gradient(135deg, rgba(255, 87, 87, 0.15), rgba(255, 153, 0, 0.15));
    border-left-color: #d39561;
}

.dark-mode .sidebar-latest {
    background: linear-gradient(135deg, rgba(76, 209, 55, 0.15), rgba(46, 213, 115, 0.15));
    border-left-color: #4fb84f;
}

.dark-mode .trending-card {
    border-color: rgba(230, 159, 88, 0.4) !important;
}

.dark-mode .latest-card {
    border-color: rgba(72, 195, 54, 0.4) !important;
}

.sub-title{
    position:relative;
    margin-top:40px;
}
 /* ㊗️👍🕹️🦍✌️😁🎨 スケルトンローディング共通スタイル ㊗️👍🕹️🦍✌️😁🎨👍🕹️🦍✌️😁🎨👍🕹️🦍✌️😁🎨*/
        .skeleton {
            background: linear-gradient(90deg,
                    rgba(0,0,0,0) 25%,
                    rgba(0,0,0,0.2) 50%,
                    rgba(0,0,0,0) 75%);
            background-size: 200% 100%;
            animation: loading 1.5s infinite;
            border-radius: 8px;
        }

        @keyframes loading {
            0% {
                background-position: 200% 0;
            }

            100% {
                background-position: -200% 0;
            }
        }

        .skeleton-text {
            height: 1em;
            margin-bottom: 0.5em;
        }

        .skeleton-title {
            height: 1.5em;
            width: 80%;
            margin-bottom: 1em;
        }

        .skeleton-thumbnail {
            width: 100%;
            padding-top: 56.25%;
            position: relative;
        }

        /* スケルトン表示中はコンテンツを隠す */
        .loading .actual-content {
            display: none;
        }

        .loaded .skeleton-loader {
            display: none;
        }


        .container {
            max-width: 1920px;
            margin: 0 auto;
            padding: 20px;
            display: grid;
            grid-template-columns: 3fr 1fr;
            gap: 10px;
        }

        /* 🎨 動画プレイヤースケルトン */
        .video-player {
            position: relative;
            width: 100%;

            background: #000;
        }

        .video-player iframe {
            height: auto !important;
            max-width: 100% !important;
            min-height: 70vh !important;
            aspect-ratio: 560 / 315 !important;
            border: none;
            margin-left: auto !important;
            margin-right: auto !important;
        }

        .video-player-skeleton {
            width: 100%;
            height: 70vh;
            min-height: 400px;
            background: #000;
            position: relative;
            overflow: hidden;
        }

        .video-player-skeleton::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            width: 80px;
            height: 80px;
            border: 6px solid #333;
            border-top-color: #667eea;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            to {
                transform: translate(-50%, -50%) rotate(360deg);
            }
        }

        /* video-info スケルトン */
        .video-info-skeleton {
            padding: 25px;
            background-image: var(--grd-erofun) !important;
        }

        .video-info-skeleton .skeleton-title {
            height: 2em;
            width: 90%;
            margin-bottom: 1.5em;
        }

        .video-info-skeleton .skeleton-meta {
            display: flex;
            gap: 1em;
            margin-bottom: 2em;
        }

        .video-info-skeleton .skeleton-meta-item {
            height: 2.5em;
            width: 100px;
            border-radius: 20px;
        }

        /* サイドバースケルトン */
        .sidebar-video-skeleton {
            display: flex;
            margin-bottom: 8px;
            padding: 16px 8px !important;
            background: var(--background-color);
            border-radius: 5px;
            gap: 15px;
        }

        .sidebar-thumbnail-skeleton {
            width: 150px;
            height: 84px;
            flex-shrink: 0;
        }

        .sidebar-info-skeleton {
            flex: 1;
            display: flex;
            flex-direction: column;
            gap: 0.5em;
        }

        /* AI関連動画スケルトン */
        .ai-video-card-skeleton {
            background: #f8f9fa;
            border-radius: 12px;
            overflow: hidden;
        }

        .ai-video-card-skeleton .skeleton-thumbnail {
            width: 100%;
            padding-top: 56.25%;
        }

        .ai-video-card-skeleton .skeleton-info {
            padding: 1rem;
        }

        /* 既存のスタイル（省略部分は元のまま） */
        .video-info {
            padding: 25px !important;
            background-image: var(--grd-erofun) !important;
        }

        .video-info h1{
            font-size: 1.4rem !important;
            margin-bottom: 15px;
            font-weight: 700;
            line-height: 1.3;
            background: var(--gradient);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }

        .video-meta {
            color: var(--text-light);
            margin-bottom: 25px;
            display: flex;
            align-items: center;
            gap: 20px;
            flex-wrap: wrap;
            font-size: 0.95em;
            padding:1rem;
        }

        .video-meta span {
            border:1px inset var(--bg-primary);
            display: flex;pointer-events: none;
            align-items: center;
            gap: 8px;
            padding: 8px 12px;
            background: var(--background-color);
            border-radius: 20px;
            transition: var(--transition);
            box-shadow: 0px 0px 16px -6px rgba(0,0,0,0.12) inset;
        }

        .video-meta span:hover {
            background: #e9ecef;
            transform: scale(1.05);
        }

        .action-buttons {
            margin: 25px 0;
            display: flex;
            gap: 12px;
            flex-wrap: wrap;
        }

        .action-btn {
            padding: 12px 24px;
            border: 2px solid transparent;
            background: #ffffff2b;
            border-radius: 30px;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 10px;
            transition: all 0.2s ease;
            font-weight: 600;
            text-decoration: none;
            color: var(--text-color);
            box-shadow: var(--shadow);
            font-size: 0.95em;
            box-shadow: var(--shadow-button);
        }

        .action-btn:hover {
            transform: translateY(-3px);
            box-shadow: var(--shadow-hover);
        }

        .action-btn.active {
            background: linear-gradient(45deg, #e91e63, #ad1457);
            color: white;
            border-color: #e91e63;
        }

        .stats-highlight {
            background: var(--gradient);
            color: white;
            padding: 25px;
            border-radius: var(--border-radius);
            margin: 25px 0;
            /*box-shadow: 0 8px 32px rgba(102, 126, 234, 0.3);*/
            box-shadow: var(--shadow-frame);
        }

        .stats-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(124px, 1fr));
            font-size:clamp(1rem, 0.9rem + 0.5vw, 1.5rem) !important;
            gap: 14px;
            text-align: center !important;
        }

        .stat-item {
            background: rgba(255, 255, 255, 0.1);
            padding: 16px;
            border-radius: 12px;
            backdrop-filter: blur(10px);
            transition: transform 0.2s;
            width: 100% !important;
            min-width: 100px !important;
            pointer-events: none;
            box-shadow: 0px 0px 16px -6px rgba(0,0,0,0.12) inset;
            border:1.2px inset #667eea;
        }

        .stat-item:hover {
            transform: scale(1.05);
            background: rgba(255, 255, 255, 0.25);
        }

        .stat-number {
            font-size: 1.4em;
            font-weight: bold;
            display: block;
            margin-bottom: 5px;
        }

        .stat-label {
            font-size: 0.9em;
            opacity: 0.95;
        }
        .primary-content{
            box-shadow: var(--shadow-frame);
        }
        .video-description {
            background: var(--card-background);
            padding: 20px;
            border-radius: 12px;
            line-height: 1.7;
            border-left: 4px solid var(--primary-color);
            margin-top: 28px;
            box-shadow: var(--shadow-frame);
            color: var(--text-primary);
        }
        .video-description i{
            font-size:120%;
        }

        /* AI関連動画セクション */
        .ai-related-section {
            background-image: var(--grd-erofun) !important;
            border-radius: 16px;
            padding: 2rem;
            box-shadow: var(--shadow);
            margin-top: 2rem;
            position: relative;
        }

        .ai-badge {
            position: absolute !important;
            top: 2rem;
            right: 2rem;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 0.5rem 1rem;
            border-radius: 20px;
            font-size: 0.85rem;
            font-weight: 700;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
            animation: aiPulse 2s ease-in-out infinite;
        }
        .ai-related-title {
            text-align: center !important;
            width: 90%;
            max-width:288px;
            margin: 12px auto 24px !important;
            background: var(--bg-primary);
            box-shadow: 0px 0px 22px -6px rgba(52, 51, 51, 0.1) inset !important;
            border-radius: 50px;
            padding: 0.3rem 0.5rem !important;
            border: 2px ridge var(--sidetitle);
            color: var(--text-primary);
            font-size:clamp(1.18rem, 0.9rem + 0.5vw, 1.5rem);
        }
        .ai-related-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 0.8rem;
        }
        .ai-video-card {
            background-color: var(--card-background) !important;
            height:310px;
            border-radius: 8px;
            overflow: hidden;
            transition: all 0.3s ease;
            text-decoration: none;
            color: var(--text-primary);
            position: relative;
            box-shadow: 0 2px 8px var(--shadow) !important;
        }
        .similarity-badge {
            position: absolute;
            top: 8px;
            right: 8px;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 4px 8px;
            border-radius: 12px;
            font-size: 0.7rem;
            font-weight: 600;
            z-index: 10;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
        }
        .ai-video-card:hover {
            transform: translateY(-4px);
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
        }
        .ai-video-card:has(.similarity-badge) {
            border: 2px solid #667eea;
            box-shadow: 0 4px 20px rgba(102, 126, 234, 0.2);
        }
        .ai-video-card:has(.similarity-badge):hover {
            transform: translateY(-6px);
            box-shadow: 0 8px 30px rgba(102, 126, 234, 0.5);
        }
        div.ai-video-thumbnail.video-thumbnail {
            position: relative;
            width: 100%;
            height:auto;
            max-height:140px !important;
            background: #ddd;
        }
        div.ai-video-thumbnail.video-thumbnail img {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 180px !important;
            object-fit: cover;
        }
        .video-duration {
            position: absolute;
            bottom: 10px;
            right: 3px;
            background: rgba(0, 0, 0, 0.65);
            color: white;
            padding: 3px 6px;
            border-radius: 4px;
            font-size: 0.75rem;
            font-weight: 600;
        }

        .ai-video-info {

            position: absolute;
            bottom:0;
            padding: 1rem;
        }

        .ai-video-title {
            font-size: 0.9rem;
            font-weight: 600;
            line-height: 1.4;
            margin-bottom: 0.5rem;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .ai-video-stats {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 0.6rem;
            font-size: 0.8rem;
            color: var(--text-secondary);
        }.actual-content {
            margin-bottom:0 !important;
            padding-bottom:0 !important;
            background-image: var(--topdown);
        }
        .favorite-count-badge.hidden {
            display: none !important;
        }

            span.font_size{
                padding:0 !important;
                margin:0 !important;
                border:none !important;
                box-shadow:0 0 0 rgba(0,0,0,0) !important;
                border:none !important;

            }
            .action-btn.active .favorite-count-badge {
                background: linear-gradient(135deg, #f44336, #c62828);
                box-shadow: 0 2px 4px rgba(244, 67, 54, 1);
            }

            .favorite-action{position:relative !important;}
            .action-btn.favorite-btn:hover .favorite-count-badge {
                transform: scale(1.5);
                box-shadow: 0 4px 16px rgba(233, 30, 99, 0.8);  
            }

            /* 急上昇アイコンのアニメーション */
            #trending-content .fa-fire {
                animation: fireFlicker 1.5s ease-in-out infinite;
            }
            #popular-content .fa-crown {
                animation: crownShine 2s ease-in-out infinite;
            }
            .mobile-search-box {
                display: none;
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                background: var(--card-background);
                box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
                z-index: 1001;
                transform: translateY(-100%);
                transition: transform 0.3s ease;
                padding: 1rem;
            }

            .mobile-search-box.active {
                display: block;
                transform: translateY(0);
            }

            .mobile-search-header {
                display: flex;
                align-items: center;
                gap: 0.5rem;
            }

            .mobile-search-back {
                background: none;
                border: none;
                font-size: 1.25rem;
                cursor: pointer;
                color: var(--text-primary);
                padding: 0.5rem;
                display: flex;
                align-items: center;
                min-width: 44px;
                min-height: 44px;
            }

            .mobile-search-form {
                flex: 1;
                display: flex;
                background: var(--background-color);
                border-radius: 8px;
                overflow: hidden;
            }

            .mobile-search-form input {
                flex: 1;
                border: none;
                padding: 0.75rem;
                background: transparent;
                color: var(--text-primary);
                font-size: 1rem;
            }

            .mobile-search-form input:focus {
                outline: none;
            }

            .mobile-search-form button {
                background: var(--primary-color);
                border: none;
                padding: 0 1rem;
                cursor: pointer;
                color: white;
                display: flex;
                align-items: center;
                justify-content: center;
                min-width: 44px;
            }
            /* 基本スタイル */
            .language-switcher {
                position: relative;
                z-index: 100;
            }

            .language-button {
                display: flex;
                align-items: center;
                gap: 0.5rem;
                padding: 0.5rem 0.75rem;
                background: var(--card-background);
                border: 1px solid var(--border-color);
                border-radius: 8px;
                cursor: pointer;
                transition: all 0.2s ease;
                min-width: 44px;
                min-height: 44px;
            }

            .language-button:hover {
                background: var(--background-color);
                border-color: var(--primary-color);
            }

            .language-button.active {
                background: var(--primary-color);
                color: white;
            }

            .language-button i {
                transition: transform 0.2s ease;
            }

            .language-button.active i {
                transform: rotate(180deg);
            }

            /* PC版メニュー */
            .language-menu {
                display: none;
                position: relative;
                top: calc(100% + 8px);
                right: 0;
                background: var(--card-background);
                border: 1px solid var(--border-color);
                border-radius: 12px;
                box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
                min-width: 200px;
                z-index: 1000;
                opacity: 0;
                transform: translateY(-10px);
                transition: opacity 0.3s ease, transform 0.3s ease;
                pointer-events: none;
            }

            .language-menu.show {
                position: absolute !important;
                display: block !important;
                opacity: 1 !important;
                left:45%;
                transform: translateY(0) !important;
                pointer-events: auto !important;
            }

            .language-option {
                display: flex;
                align-items: center;
                gap: 0.75rem;
                padding: 0.875rem 1rem;
                text-decoration: none;
                color: var(--text-primary);
                transition: background 0.2s ease;
                border-bottom: 1px solid var(--border-color);
            }

            .language-option:last-child {
                border-bottom: none;
            }

            .language-option:hover {
                background: rgba(66, 138, 198, 0.1);
            }

            .language-option .flag {
                font-size: 1.5rem;
            }

            .language-option .name {
                flex: 1;
                font-weight: 500;
            }

            .language-option .check {
                color: var(--primary-color);
                font-weight: bold;
            }

            /* 👍👎 評価全体 */
            .rating-wrapper {
                position: absolute;
                right:0;
                top:92px;
                width:45% !important;
            margin: 18px 2% 0 -12px !important;
            padding: 16px 14px;
            border:3px solid var(--border-color) !important;
            border-radius: 10px;
                    background: var(--bg--btn);
            box-shadow: var(--shadow);align-items: center !important;justify-content: center !important;
            }


            /* 上の 👍👎 表示 */
            .rating-icons {
            display: flex;
            justify-content: space-between;
            margin-bottom: 6px;
            color: var(--text-color);
            background:rgva(255,255,255,0.1);
            }
            #dislikePercent,#likePercent{
                position:relative;top: -4px !important;gap:3rem !important;margin:4px !important;
            -webkit-text-stroke: 2px rgba(255,255,255,0.04) !important;
            text-stroke: 2px rgba(255,255,255,0.04) !important;
            paint-order: stroke !important;
            font-size: 1.6rem;
            }
            .rating-icons i{
            font-size: 2rem;
            -webkit-text-stroke: 2px rgba(255,255,255,0.04) !important;
            text-stroke: 2px rgba(255,255,255,0.04) !important;
            paint-order: stroke !important;
            }
            .rating-icons .like {
            color: #2ecc71;
            }
            .rating-icons .dislike {
            color: #e74c3c;
            }

            /* バー全体 */
            .rating-bar {
            display: flex;
            width: 100%;
            height: 8px;
            border-radius: 6px;
            overflow: hidden;
            background: #ddd;
            }

            /* 👍 側 */
            .rating-like {
            background: linear-gradient(90deg, #2ecc71, #27ae60);
            }

            /* 👎 側 */
            .rating-dislike {
            background: linear-gradient(90deg, #e74c3c, #c0392b);
            }
            .action-btn.info-btn {
            display: none;
            }

            .rating-btn.like { color: #2ecc71; }
            .rating-btn.dislike { color: #e74c3c; }

            /* 👍👎 ボタン化 */
            .rating-btn {
            border: none;
            background: transparent;
            cursor: pointer;
            font-size: 0.92rem;
            font-weight: 700;
            padding: 6px 10px;
            border-radius: 10px;
            transition: 0.2s;
            color: var(--text-color);
                opacity:0.4 !important;
            }

            .rating-btn:hover {
                opacity:1;
            }

            /* 選択済み */
            .rating-btn.selected {
                opacity:1 !important;
            }

            /* ヒント文 */
            .rating-hint {
            margin-top: 8px;
            font-size: 0.82rem;
            color: var(--text-secondary);
            background:rgba(255,255,255,0.02);
            text-align:center;
            }

/* ボタン */
.language-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: var(--card-background, #fff);
    border: 1px solid var(--border-color, #ddd);
    border-radius: 8px;
    cursor: pointer;
    min-width: 50px;
    min-height: 50px;
    transition: all 0.2s ease;
}

.language-button:hover {
    background: var(--primary-color, #4286c6);
    color: white;
}

.language-button.active {
    background: var(--primary-color, #4286c6);
    color: white;
}

.language-button .flag {
    font-size: 1.5rem;
}

.language-button i {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

.language-button.active i {
    transform: rotate(180deg);
}

/* メニュー本体（body直下に配置） */
.language-menu {
    display: none;
    position: fixed;
    top: 70px;
    right: 10px;
    width: 200px;
    max-width: calc(100vw - 20px);
    max-height: calc(100vh - 80px);
    background: var(--card-background, #fff);
    border: 2px solid var(--primary-color, #4286c6);
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 999999;
    overflow-y: auto;
    overflow-x: hidden;
}

.language-menu.show {
    position: absolute;
    display: block !important;
    animation: slideDown 0.3s ease;
}

/* オプション */
.language-option {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    text-decoration: none;
    color: var(--text-primary, #333);
    background: var(--card-background, #fff);
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s ease;
    min-height: 60px;
}

.language-option:last-child {
    border-bottom: none;
}

.language-option:hover,
.language-option:active {
    background: #f0f8ff !important;
}

.language-option .flag {
    font-size: 1.75rem;
}

.language-option .name {
    flex: 1;
    font-weight: 500;
    font-size: 1rem;
}

.language-option .check {
    color: var(--primary-color, #4286c6);
    font-weight: bold;
    font-size: 1.25rem;
}

/* オーバーレイ */
.language-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999998;
}

.language-menu-overlay.show {
    display: block !important;
}

/* ダークモード対応 */
.dark-mode .language-menu {
    background: #1a1f3a;
    border-color: #667eea;
}

.dark-mode .language-option {
    background: #1a1f3a;
    color: #e0e6ed;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .language-option:hover {
    background: rgba(102, 126, 234, 0.2) !important;
}
    .breadcrumb{
        width:100%;
        display: flex; 
        align-items: center; 
        gap: 0.5rem; 
        margin-bottom: 1rem; 
        padding: 0.75rem 1.5rem; 
        background-image: var(--grd-erofun) !important; 
        border-radius: 8px !important; 
        box-shadow: 0 2px 12px rgba(0,0,0,0.08); 
        flex-wrap: wrap; 
        font-size: 0.9rem;
        text-align: center;
        color:var(--text-color);
    }
    .sidebar-video-title{
        font-size: 0.9rem;
        font-weight: 600;
        line-height: 1.4;
        margin-bottom: 0.5rem;
        color:var(--text-color);
    }
    .breadcrumb a{
        margin:5px !important;
        padding:4px 12px;
        color: #3f6e9d;
    }
    .breadcrumb a:hover {
        background-color: rgba(52, 142, 215, 0.1) !important;
    }
    .lang-loading {
        position: fixed;
        inset: 0;
        background: rgba(255,255,255,0.7);
        display: none;
        z-index: 9999;
        }
        .lang-loading.show {
        display: flex;
        align-items: center;
        justify-content: center;
        }
        .spinner {
        width: 32px;
        height: 32px;
        border: 3px solid #ddd;
        border-top-color: #e74c3c;
        border-radius: 50%;
        animation: spin .6s linear infinite;
        }
        @keyframes spin { to { transform: rotate(360deg); } }
        @keyframes aiPulse {

            0%,
            100% {
                transform: scale(1);
                box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
            }

            50% {
                transform: scale(1.05);
                box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
            }
        }
        @keyframes slideDown {
            from {
                opacity: 0;
                transform: translateY(-20px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }
        @keyframes fireFlicker {
            0%, 100% { opacity: 1; transform: scale(1); }
            50% { opacity: 0.8; transform: scale(1.1); }
        }
        @keyframes crownShine {
            0%, 100% { filter: brightness(1); }
            50% { filter: brightness(1.3); }
        }
        @keyframes badgePulse {

            0%,
            100% {
                transform: scale(1);
                box-shadow: 0 2px 8px rgba(233, 30, 99, 0.4);
            }

            50% {
                transform: scale(1.3);
                box-shadow: 0 2px 12px rgba(233, 30, 99, 0.6);
            }
        }
        @keyframes badgeVS {

            0%,
            100% {
                transform: scale(1);
                box-shadow: 0 2px 8px rgba(233, 30, 99, 0);
            }

            50% {
                transform: scale(1.3);
                box-shadow: 0 2px 12px rgba(233, 30, 99, 0);
            }
        }
        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(20px);
            }

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