/* 완전히 수정된 CSS 파일 */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f4f7f6;
    color: #2c3e50;
    margin: 0;
    padding: 30px 20px;
    min-height: 100vh;
    overflow-y: auto;
    scroll-behavior: smooth;
    box-sizing: border-box;
}

h1 {
    color: #34495e;
    text-align: center;
    font-weight: 300;
    font-size: 28px;
    margin: 0 0 40px 0;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.link-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* 기본 북마크 아이템 스타일 */
.link-item {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: none;
    border-left: 2px solid #A6A6A6;
    padding: 24px 28px;
    border-radius: 12px;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.08),
        0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.link-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #3498db, #2980b9);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.link-item:hover {
    transform: translateY(-4px);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.12),
        0 6px 16px rgba(0, 0, 0, 0.08);
    border-left-color: #2980b9;
}

.link-item:hover::before {
    transform: scaleX(1);
}

.link-item a {
    color: #2c3e50 !important;
    font-size: 20px !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    display: block !important;
    line-height: 1.4 !important;
    margin-bottom: 8px !important;
    transition: color 0.3s ease !important;
    pointer-events: auto !important;
    cursor: pointer !important;
}

.link-item:hover a {
    color: #2980b9 !important;
}

.link-item p {
    color: #7f8c8d;
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
    opacity: 0.9;
}

/* 유튜브 영상 전용 스타일 */
.youtube-video {
    display: flex !important;
    padding: 0 !important;
    border-left: 2px solid #ff0000 !important;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    box-shadow: 
        0 6px 25px rgba(255, 0, 0, 0.08),
        0 3px 10px rgba(0, 0, 0, 0.04);
}

.youtube-video::before {
    background: linear-gradient(90deg, #ff0000, #cc0000);
}

.youtube-video:hover {
    border-left-color: #cc0000;
    box-shadow: 
        0 15px 45px rgba(255, 0, 0, 0.12),
        0 8px 20px rgba(0, 0, 0, 0.08);
}

.video-thumbnail {
    position: relative;
    width: 240px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 12px 0 0 12px;
}

.video-thumbnail img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.youtube-video:hover .video-thumbnail img {
    transform: scale(1.05);
}

.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    pointer-events: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.youtube-video:hover .play-overlay {
    background: rgba(255, 0, 0, 0.9);
    transform: translate(-50%, -50%) scale(1.1);
}

.video-info {
    padding: 24px 28px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.video-info h3 {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.4;
}

.video-info h3 a {
    color: #2c3e50 !important;
    text-decoration: none !important;
    transition: color 0.3s ease !important;
    margin-bottom: 0 !important;
    display: inline !important;
    pointer-events: auto !important;
    cursor: pointer !important;
}

.youtube-video:hover .video-info h3 a {
    color: #cc0000 !important;
}

.video-info p {
    color: #7f8c8d;
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 16px 0;
    opacity: 0.9;
    flex-grow: 1;
}

.video-badge {
    background: linear-gradient(135deg, #ff0000, #cc0000);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    align-self: flex-start;
    box-shadow: 0 2px 8px rgba(255, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.youtube-video:hover .video-badge {
    box-shadow: 0 4px 12px rgba(255, 0, 0, 0.4);
    transform: scale(1.05);
}

/* 에러 메시지 */
.error-message {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 20px 24px;
    margin: 20px auto;
    max-width: 600px;
    font-size: 15px;
    box-shadow: 0 4px 20px rgba(255, 107, 107, 0.3);
    text-align: center;
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    body {
        padding: 20px 15px;
    }
    
    h1 {
        font-size: 24px;
        margin-bottom: 30px;
    }
    
    .link-container {
        gap: 16px;
    }
    
    .link-item {
        padding: 20px 22px;
        border-radius: 10px;
    }
    
    .link-item a {
        font-size: 18px !important;
    }
    
    .link-item p {
        font-size: 14px;
    }
    
    /* 유튜브 영상 반응형 */
    .youtube-video {
        flex-direction: column;
        padding: 0 !important;
    }
    
    .video-thumbnail {
        width: 100%;
        border-radius: 10px 10px 0 0;
    }
    
    .video-thumbnail img {
        height: 200px;
    }
    
    .video-info {
        padding: 20px 22px;
    }
    
    .video-info h3 {
        font-size: 18px;
    }
    
    .video-info p {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 15px 10px;
    }
    
    h1 {
        font-size: 22px;
        margin-bottom: 25px;
    }
    
    .link-item {
        padding: 18px 20px;
    }
    
    .link-item a {
        font-size: 17px !important;
    }
    
    .video-info {
        padding: 18px 20px;
    }
    
    .video-info h3 {
        font-size: 17px;
    }
}

/* 스크롤바 스타일링 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #2980b9, #1f4e79);
}
